Set useCuda if CUDA enabled in Compression class.

This commit is contained in:
castano 2008-02-01 19:51:54 +00:00
parent 90a0dc505b
commit 6f28642282
2 changed files with 4 additions and 1 deletions

View File

@ -46,7 +46,7 @@ namespace nvtt
uint bmask;
uint amask;
bool useCuda;
mutable bool useCuda;
nv::String externalCompressor;

View File

@ -673,6 +673,9 @@ static bool compress(const InputOptions::Private & inputOptions, const OutputOpt
/// Compress the input texture with the given compression options.
bool Compressor::process(const InputOptions & inputOptions, const CompressionOptions & compressionOptions, const OutputOptions & outputOptions) const
{
// @@ Hack!
compressionOptions.m.useCuda = this->m.cudaEnabled;
return ::compress(inputOptions.m, outputOptions.m, compressionOptions.m);
}