mirror of
https://github.com/yuzu-emu/FasTC
synced 2024-11-26 00:08:00 +00:00
Fix some small bugs to hook into NVTT
This commit is contained in:
parent
fabf6830ee
commit
ed2bcc3838
3 changed files with 8 additions and 7 deletions
|
@ -62,4 +62,4 @@
|
|||
#cmakedefine HAS_GCC_ATOMICS
|
||||
#cmakedefine HAS_MSVC_ATOMICS
|
||||
|
||||
#cmakedefine FOUND_NVTT_BC7_EXPORT
|
||||
#cmakedefine FOUND_NVTT_BPTC_EXPORT
|
||||
|
|
|
@ -50,8 +50,8 @@
|
|||
* <http://gamma.cs.unc.edu/FasTC/>
|
||||
*/
|
||||
|
||||
#include "BC7Compressor.h"
|
||||
#include "BC7CompressionMode.h"
|
||||
#include "BPTCCompressor.h"
|
||||
#include "CompressionMode.h"
|
||||
#undef DBL_MAX
|
||||
#include "BitStream.h"
|
||||
#include "TexCompTypes.h"
|
||||
|
@ -62,7 +62,7 @@
|
|||
|
||||
#include "avpcl.h"
|
||||
|
||||
namespace BC7C {
|
||||
namespace BPTCC {
|
||||
|
||||
void GetBlock(uint32 x, uint32 y, uint32 width, const uint32 *pixels, Tile &t) {
|
||||
for(uint32 j = 0; j < 4; j++)
|
||||
|
@ -146,11 +146,11 @@ namespace BC7C {
|
|||
double mse = kModeFuncs[mode](t, out);
|
||||
PrintStat(log, ss.str().c_str(), mse);
|
||||
|
||||
BitStreamReadOnly strm(reinterpret_cast<uint8 *>(out));
|
||||
FasTC::BitStreamReadOnly strm(reinterpret_cast<uint8 *>(out));
|
||||
while(!strm.ReadBit());
|
||||
|
||||
const BC7CompressionMode::Attributes *attrs =
|
||||
BC7CompressionMode::GetAttributesForMode(mode);
|
||||
const CompressionMode::Attributes *attrs =
|
||||
CompressionMode::GetAttributesForMode(mode);
|
||||
const uint32 nSubsets = attrs->numSubsets;
|
||||
|
||||
ss.str("");
|
||||
|
|
|
@ -66,6 +66,7 @@ IF(NOT AVPCLLIB_ROOT STREQUAL "")
|
|||
ENDIF()
|
||||
ADD_SUBDIRECTORY(${AVPCLLIB_ROOT}/src ${CMAKE_CURRENT_BINARY_DIR}/bc7_export)
|
||||
set(AVPCLLIB_INCLUDE_DIR ${AVPCLLIB_ROOT}/src )
|
||||
SET(FOUND_NVTT_BPTC_EXPORT TRUE)
|
||||
ENDIF()
|
||||
|
||||
mark_as_advanced( FORCE AVPCLLIB_ROOT AVPCLLIB_INCLUDE_DIR )
|
||||
|
|
Loading…
Reference in a new issue