Commit Graph

41 Commits

Author SHA1 Message Date
Fabian Giesen
dc2aa370c0 stb_dxt: Remove dithering support.
Keep STB_DXT_DITHER so as not to break existing code that tries
to enable it, but just leave it permanently off. I originally
introduced it somewhat superstitiously because of the RGB565
endpoint resolution but it never improved either perceptual quality
or objective quality metrics, and the code is appreciably simpler
without it.
2021-07-04 01:38:24 -07:00
Fabian Giesen
ae3ed90b0c stb_dxt: Better error calc for single-color table
Don't truncate error as aggressively; easily done, but wanted
to keep it separate from the previous change.
2021-07-04 01:38:24 -07:00
Alan Hickman
98623b9577 stb_dxt: Initialize tables at compile time
Also fix a "potentially uninitialized variable" warning.

This is a modified version of Alan's original PR that keeps the
table generator in the file (in case there's interest) and also
replaces the expand[] tables with math, since it's trivial.

Fixes issue #1117.
2021-07-04 01:38:24 -07:00
Sean Barrett
314d0a6f9a update version numbers 2020-07-13 04:36:03 -07:00
Sean Barrett
0ccb4f0071 Merge branch 'rg-matchcolors' of https://github.com/castano/stb into working 2020-07-13 03:27:22 -07:00
Sean Barrett
6f7420a825 add credits for last few PR merges 2020-07-13 02:59:10 -07:00
Sean Barrett
1c816743b6 make PR compile in MSVC6 2020-07-13 02:49:46 -07:00
Ignacio Castano
c7cf85ffce Integrate more accurate index selection by Rich Geldreich. 2020-04-05 20:37:29 -07:00
Ignacio Castano
254e1c9975 Perfect quantization of DXT endpoints
A small change to quantize floating point endpoints to RGB565 as expanded in the DXT spec. For more info see: https://gist.github.com/castano/c92c7626f288f9e99e158520b14a61cf
2020-03-19 23:23:36 -07:00
Sean Barrett
2bb4a0accd Fix trailing whitespace 2020-02-02 11:30:27 -08:00
Sean Barrett
5e4a0617b7 udpate version numbers 2020-02-02 11:12:13 -08:00
Sean Barrett
fd4f1f702e Merge branch 'master' of https://github.com/haferburg/stb into work2 2020-02-02 09:42:24 -08:00
Sean Barrett
5a2c8901b2 stb_dxt: documentation change for constant alpha 2020-02-02 07:37:10 -08:00
Andreas Haferburg
905d05a1d0 Fixed whitespace 2019-10-14 14:24:47 +02:00
Andreas Haferburg
c70479c47b Revert "Fixed whitespace"
This reverts commit 72646ac4ae.
2019-10-14 14:23:36 +02:00
Andreas Haferburg
72646ac4ae Fixed whitespace 2019-10-14 14:16:11 +02:00
Andreas Haferburg
df0c8e92d4 Fixed compiler warnings C4244 conversion from 'int' to 'unsigned char'/'unsigned short'. 2019-10-14 14:05:36 +02:00
luz.paz
622b3adad3 Misc. comment typos
Found via `codespell -q 3`
2018-02-12 14:54:22 -05:00
Sean Barrett
06fedddb4d fix stb_dxt.h; fix misspelled STB_DXT_IMPLEMENTATION in test jig 2018-01-30 02:56:16 -08:00
Sean Barrett
d808adb77f stb_dxt: fix bug with constant color & varying alpha 2018-01-29 05:17:07 -08:00
Jonathan Adamczewski
c8245bbf22 Remove arg from memset macro
My clang doesn't like the macro defined this way, choking at the callsite on line 195 with "too many arguments provided to function-like macro invocation"

This change matches what is done for STBTT_memset in stb_truetype.h
2017-08-28 23:13:39 -07:00
Sean Barrett
555efbedfc Update version numbers 2017-07-23 14:09:39 -07:00
Fabian Giesen
4868b5283b stb_dxt: Update contributors list. 2017-07-22 15:40:27 -07:00
Fabian Giesen
31f8c2109b Merge branch 'ppiastucki-bc4' into dev 2017-07-22 15:29:50 -07:00
Fabian Giesen
7a6251689f Merge branch 'h-s-c-stb_dxt_static' into dev 2017-07-22 15:13:13 -07:00
ppiastucki
8a55e1e5a5 Add support for BC4 2017-04-26 22:32:37 +02:00
Kevin Schmidt
50e6be0de6 Edit contributor list. 2017-04-18 18:31:15 +02:00
Kevin Schmidt
9b3358fec1 Add feature to replace abs/fabs and memset with your own. 2017-04-18 18:28:02 +02:00
Kevin Schmidt
96e1f0474c Edit contributor list. 2017-04-18 17:42:41 +02:00
Kevin Schmidt
dda7d72841 Add STB_DXT_STATIC option. 2017-04-18 16:17:18 +02:00
Sean Barrett
ee19531f68 fix to new bc5 path 2017-03-03 11:12:41 -08:00
Sean Barrett
6ba52a370c stb_dxt: extern "C" 2017-03-03 08:57:34 -08:00
Sean Barrett
4ce23da44a rename 3dc to bc5, tweaks to clean stuff up 2017-03-03 08:54:44 -08:00
Sean Barrett
a217948c16 change 3dc name to bc5 2017-03-03 08:49:08 -08:00
Sean Barrett
c39063727d Merge branch 'master' of https://github.com/snake5/stb into working 2017-03-03 08:44:52 -08:00
Sean Barrett
47685c5f84 remove deprecated old-precision jpg path from stb_image.h
tweak license reference wording
2017-03-03 08:19:09 -08:00
Sean Barrett
e248e30954 change license to public-domain AND mit (based on twitter vote) 2017-03-03 07:53:07 -08:00
snake5
cd93a5de11 added basic 3Dc support 2016-11-26 16:45:40 +02:00
Craig Donner
ee6978cb68 Slightly modify the public domain license to keep it in the public domain, but make it clear that even when dedications might not be recognized that the code is still usable. Given that this isn't dual-licensing under a different license, I'm hoping this will be acceptable. 2016-02-25 12:55:44 -08:00
Ryan Whitworth
55ff60818e Added public domain license text 2015-08-01 14:48:37 -04:00
Sean Barrett
bfef4c10e8 added stb_dxt.h 2014-05-25 11:54:10 -07:00