Commit Graph
11 Commits
Author SHA1 Message Date
Ben Doherty da81e857a0 Correct spherical harmonics comments (#1375) 2019-07-09 16:16:30 -07:00
Ben Doherty cc4e9db81b Fix spherical harmonics parsing (#1370) 2019-07-02 12:54:52 -07:00
Philip Rideout 56c2d6338e Add spherical harmonics parser, reduce code duplication.
This uses strtof rather than stringstream and provides a common location
that can be leveraged by the upcoming JNI bindings.

Note that this new method lives in KtxBundle rather than KtxUtility. The
latter creates Filament textures and therefore does not get built into
libimage.
2019-06-28 11:10:04 -07:00
Romain Guy 826d52bca2 Fix Windows build and warnings 2019-06-27 09:18:31 -07:00
Philip Rideout 462f55e2b4 Add KTX support to roughness-prefilter. 2018-09-25 15:56:12 -07:00
prideout be04ea843c Fix test by add missing code to recent commit. 2018-09-25 12:54:00 -07:00
Philip Rideout fc7b5872a0 Add metadata support to KtxBundle.
The KTX spec allows for arbitrary key-value pairs, we are interested in
using this to stash spherical harmonics coefficients.
2018-09-25 11:53:48 -07:00
prideout 3c59ed2c4b Fix bad size in KTX reader. 2018-09-21 10:45:51 -07:00
Philip Rideout 46b99b7565 KtxBundle now uses contiguous memory for blobs.
This will make uploading KTX cubemaps to the GPU easier and more
efficient.
2018-09-20 17:39:43 -07:00
Philip Rideout 21906a1096 Simplify KtxBundle by using unique_ptr. 2018-09-14 16:55:05 -07:00
Philip Rideout e4b60e47cb Introduce KtxBundle to libimage and add unit test.
KtxBundle is basically an in-memory representation of a KTX file.
Our primary motivation for introducing this class is to have a
structured container for block-compressed textures.

Note that this class is defined in libimage rather than libimageio.
There are several reasons for this:

1. The texel data in a KtxBundle is not meant to be decoded by the CPU.
2. It has no dependendencies on any libraries (stb_image tinyexr etc).
3. We wish to use it with WebGL, which needs to avoid using imageio.
2018-09-14 16:55:05 -07:00