Commit Graph

82 Commits

Author SHA1 Message Date
Pavel Krajcevski
6f82ab8941 Don't crash when you can't open a file that doesn't exist 2014-11-03 15:57:34 -05:00
Pavel Krajcevski
a74b4e6862 Add proper include to support min and max 2014-10-24 09:10:29 -04:00
Pavel Krajcevski
840ae71cbc Add small tool that decompresses an image. 2014-03-18 19:37:42 -04:00
Pavel Krajcevski
7ee0df9a5a Add 2bpp PVRTC compression format 2014-03-12 14:01:31 -04:00
Pavel Krajcevski
0a4726bfe2 Merge branch 'master' into DecompressASTC 2014-03-12 13:29:17 -04:00
Pavel Krajcevski
f1b5bc3831 Use references to images from image loader.
In general, we should really copy the images with the built-in Clone()
function, but then we'd need to manage memory, etc. To avoid that headache,
we can simply just use references.
2014-03-12 13:18:56 -04:00
Pavel Krajcevski
479ba8e76d Fix a bunch of MSVC compiler warnings and errors.
Most notably, we need to actually fix a bug in MSVC that doesn't know how to properly instantiate
enums in partial template specialization. There are more details outlined here:

http://stackoverflow.com/questions/15466594/why-does-msvc-fail-to-compile-this-template-function

The fix in this commit closes #10

Also in this commit is a hacky way to allow GL defines. Apparently "LoadImage" is defined as a
macro even with WIN32_LEAN_AND_MEAN. This means that we have to #undef the code that includes
it, meaning that we also need to make sure not to actually mix GLDefines.h with any file that needs
to use the functions from Windows.h
2014-03-12 02:43:09 -04:00
Pavel Krajcevski
c6948e8421 Merge branch 'master' into ModularizeBPTC 2014-02-27 14:20:50 -05:00
Pavel Krajcevski
1a5b748b2c Check for C++11 types in base library 2014-01-30 13:55:55 -05:00
Pavel Krajcevski
e62400eb01 Merge from master 2014-01-29 14:51:00 -05:00
Pavel Krajcevski
754cd3532a Don't crash if we can't parse the filename 2014-01-29 14:36:37 -05:00
Pavel Krajcevski
1b5b8c3900 Add hooks to support filenames with .ktx extension 2014-01-24 14:00:14 -05:00
Pavel Krajcevski
f12ee09f7e Some formatting and rearrange the BPTC code to be more structured like the others 2014-01-21 14:46:25 -05:00
Pavel Krajcevski
f2c153feba Add a command line switch to not produce decompressed output 2013-12-09 11:45:57 -05:00
Pavel Krajcevski
6249a4a077 Merge branch 'master' of git.cs.unc.edu:pavel/FasTC 2013-11-19 15:14:14 -05:00
Pavel Krajcevski
6794a0fffb Add hooks to NVTT bc7_export library if present on the users machine. Assumes that all of the cross platform problems are fixed for incorporation into FasTC... Otherwise the options to use NVTT are ignored. 2013-11-19 12:03:03 -05:00
Pavel Krajcevski
86741f7a89 Fix some configuration issues with VS2012 2013-11-17 14:17:00 -05:00
Pavel Krajcevski
8626332d70 Combine cl tools into a single file... 2013-11-11 14:11:41 -05:00
Pavel Krajcevski
a80944901e Refactor CompressionJob struct.
In order to better facilitate the change from block stream order to non-block stream order,
a lot of changes were introduced to the way that we feed texture data to the compressors. This
data is embodied in the CompressionJob struct. We have made it so that the compression job
points to both the in and out pointers for our compressed and uncompressed data. Furthermore,
we have made sure that the struct also contains the format that its compressing for, so that if
any threading programs would like to chop up a compression job into smaller chunks based on the
format, it doesn't need to know the format explicitly, it just needs to know certain properties
about the format.

Moreover, the user can now define the start and end pixels from which we would like to compress
to. We can compress subsets of data by changing the in and out pointers and the width and height
values. The compressors will read data linearly until they reach the out pixels based on the width
of the given pixel.
2013-11-08 16:31:19 -05:00
Pavel Krajcevski
8e76d149ba Remove a bunch of code that assumes that we get our pixel data in block stream order... 2013-11-06 18:23:19 -05:00
Pavel Krajcevski
f67bcc400b Add ETC1 to unix cl tool 2013-10-24 10:27:37 -04:00
Pavel Krajcevski
bae71bbe4f Add Rich Geldreich's ETC1 compressor. 2013-10-21 17:23:33 -04:00
Pavel Krajcevski
22246810d6 Report entropy when compressing a texture. 2013-10-18 04:12:49 -04:00
Pavel Krajcevski
674c18b9d9 Add DXT encoder from J.M.P. Van Waveren 2013-10-16 16:40:38 -04:00
Pavel Krajcevski
a9d8f4ca6e Fix some win32 bugs. 2013-10-14 23:25:02 -04:00
Pavel Krajcevski
f1b564fdb2 Only report MSSIM 2013-10-12 16:37:48 -04:00
Pavel Krajcevski
e21ffecfa3 Small tool to compare two images with all of the metrics that we have encoded. 2013-10-11 20:53:44 -04:00
Pavel Krajcevski
86bb0f6d0e Add SSIM report to command line tools... 2013-10-11 13:09:33 -04:00
Pavel Krajcevski
3e35fb2c0d Merge SplitCoreLibrary 2013-10-10 11:04:40 -04:00
Pavel Krajcevski
4baf2ce311 Combine image functionality from PVRTCEncoder into Base library. 2013-10-04 18:35:18 -04:00
Pavel Krajcevski
5b0ede3239 Fix win32 cltool. 2013-10-02 11:56:36 -04:00
Pavel Krajcevski
ce7bb8e891 Add command line flags to choose between whether or not to use PVRTexLib or FasTC 2013-09-30 12:46:23 -04:00
Pavel Krajcevski
795e8dd32d Change basename in cl tools to avoid directory information. 2013-09-30 11:17:17 -04:00
Pavel Krajcevski
f3c37defcc Make sure that we specify the -l flag before trying to write to a log file. 2013-09-30 11:08:33 -04:00
Pavel Krajcevski
a2390189f8 Make sure to not set an output stream if the user hasn't requested it. 2013-09-29 14:32:21 -04:00
Pavel Krajcevski
e11e2d1c12 Actually use a log file instead of std::cout and remove a warning that's no longer applicable 2013-09-28 22:40:14 -04:00
Pavel Krajcevski
baab69dc99 Fix some MSVC compiler snafus 2013-09-28 22:21:31 -04:00
Pavel Krajcevski
c3cb8403b5 Fix our threadsafe streambuf to accept a sink that receives all of the proper output... 2013-09-28 21:44:50 -04:00
Pavel Krajcevski
dcf389d346 Merge PVRTC compressor into split library. 2013-09-27 17:30:16 -04:00
Pavel Krajcevski
264e447e80 Deal with this bug once and for all. If we have an image in block stream order, then explicitly reorder it before doing any work. Then keep it that way. I probably could have fixed this in the amount of time I've wasted on it. -____- 2013-09-26 20:17:07 -04:00
Pavel Krajcevski
ba36ca34fd Make sure to set the block stream order flag for sane debugging. This bug really needs to get fixed. 2013-09-25 20:07:10 -04:00
Pavel Krajcevski
986616daf6 Touch up windows command line tool to support PVRTC compression 2013-09-25 16:36:34 -04:00
Pavel Krajcevski
1093447055 Plug in the infrastructure to start passing images to be compressed. 2013-09-20 12:43:59 -04:00
Pavel Krajcevski
28cf254fe5 Initial decoupling of base library from core library. Includes a few formatting changes as well. 2013-09-13 19:36:37 -04:00
Pavel Krajcevski
03a7934644 Get rid of evil tabs once and forever (from cpp/h files) 2013-08-26 16:54:08 -04:00
Pavel Krajcevski
25eba39870 Change the name of everything to FasTC 2013-08-22 18:35:01 -04:00
Pavel Krajcevski
e150d4ee18 Add -a flag to unix command line tool as well 2013-03-07 02:31:21 -05:00
Pavel Krajcevski
da0d2be695 Small cosmetic and newline change 2013-03-06 21:02:33 -05:00
Pavel Krajcevski
dbabd5e399 Add command line option to choose atomics path for compression. 2013-03-06 20:58:01 -05:00
Pavel Krajcevski
da010a465f Formatting fixes 2013-03-06 20:52:15 -05:00