diff --git a/OpenEXR/IlmImf/ImfFastHuf.cpp b/OpenEXR/IlmImf/ImfFastHuf.cpp index 86c84dce21..82708df0a3 100644 --- a/OpenEXR/IlmImf/ImfFastHuf.cpp +++ b/OpenEXR/IlmImf/ImfFastHuf.cpp @@ -129,7 +129,7 @@ FastHufDecoder::FastHufDecoder { if (currByte - table > numBytes) { - throw Iex::InputExc ("Error decoding Huffman table " + throw IEX_NAMESPACE::InputExc ("Error decoding Huffman table " "(Truncated table data)."); } @@ -146,7 +146,7 @@ FastHufDecoder::FastHufDecoder { if (currByte - table > numBytes) { - throw Iex::InputExc ("Error decoding Huffman table " + throw IEX_NAMESPACE::InputExc ("Error decoding Huffman table " "(Truncated table data)."); } @@ -155,7 +155,7 @@ FastHufDecoder::FastHufDecoder if (symbol + runLen > maxSymbol + 1) { - throw Iex::InputExc ("Error decoding Huffman table " + throw IEX_NAMESPACE::InputExc ("Error decoding Huffman table " "(Run beyond end of table)."); } @@ -168,7 +168,7 @@ FastHufDecoder::FastHufDecoder if (symbol + runLen > maxSymbol + 1) { - throw Iex::InputExc ("Error decoding Huffman table " + throw IEX_NAMESPACE::InputExc ("Error decoding Huffman table " "(Run beyond end of table)."); } @@ -256,7 +256,7 @@ FastHufDecoder::FastHufDecoder int symbol = *i >> 6; if (mapping[codeLen] >= _numSymbols) - throw Iex::InputExc ("Huffman decode error " + throw IEX_NAMESPACE::InputExc ("Huffman decode error " "(Invalid symbol in header)."); _idToSymbol[mapping[codeLen]] = symbol; @@ -401,7 +401,7 @@ FastHufDecoder::buildTables (Int64 *base, Int64 *offset) } else { - throw Iex::InputExc ("Huffman decode error " + throw IEX_NAMESPACE::InputExc ("Huffman decode error " "(Overrun)."); } break; @@ -578,7 +578,7 @@ FastHufDecoder::decode int numDstElems) { if (numSrcBits < 128) - throw Iex::InputExc ("Error choosing Huffman decoder implementation " + throw IEX_NAMESPACE::InputExc ("Error choosing Huffman decoder implementation " "(insufficient number of bits)."); // @@ -662,7 +662,7 @@ FastHufDecoder::decode if (codeLen > _maxCodeLength) { - throw Iex::InputExc ("Huffman decode error " + throw IEX_NAMESPACE::InputExc ("Huffman decode error " "(Decoded an invalid symbol)."); } @@ -673,7 +673,7 @@ FastHufDecoder::decode } else { - throw Iex::InputExc ("Huffman decode error " + throw IEX_NAMESPACE::InputExc ("Huffman decode error " "(Decoded an invalid symbol)."); } } @@ -710,19 +710,19 @@ FastHufDecoder::decode if (dstIdx < 1) { - throw Iex::InputExc ("Huffman decode error (RLE code " + throw IEX_NAMESPACE::InputExc ("Huffman decode error (RLE code " "with no previous symbol)."); } if (dstIdx + rleCount > numDstElems) { - throw Iex::InputExc ("Huffman decode error (Symbol run " + throw IEX_NAMESPACE::InputExc ("Huffman decode error (Symbol run " "beyond expected output buffer length)."); } if (rleCount <= 0) { - throw Iex::InputExc("Huffman decode error" + throw IEX_NAMESPACE::InputExc("Huffman decode error" " (Invalid RLE length)"); } @@ -760,7 +760,7 @@ FastHufDecoder::decode if (numSrcBits != 0) { - throw Iex::InputExc ("Huffman decode error (Compressed data remains " + throw IEX_NAMESPACE::InputExc ("Huffman decode error (Compressed data remains " "after filling expected output buffer)."); } } diff --git a/OpenEXR/IlmImf/ImfZip.cpp b/OpenEXR/IlmImf/ImfZip.cpp index 93d625e146..3a4f871ab4 100644 --- a/OpenEXR/IlmImf/ImfZip.cpp +++ b/OpenEXR/IlmImf/ImfZip.cpp @@ -42,14 +42,14 @@ OPENEXR_IMF_INTERNAL_NAMESPACE_SOURCE_ENTER -Imf::Zip::Zip(size_t maxRawSize): +Zip::Zip(size_t maxRawSize): _maxRawSize(maxRawSize), _tmpBuffer(0) { _tmpBuffer = new char[_maxRawSize]; } -Imf::Zip::Zip(size_t maxScanLineSize, size_t numScanLines): +Zip::Zip(size_t maxScanLineSize, size_t numScanLines): _maxRawSize(0), _tmpBuffer(0) { @@ -57,19 +57,19 @@ Imf::Zip::Zip(size_t maxScanLineSize, size_t numScanLines): _tmpBuffer = new char[_maxRawSize]; } -Imf::Zip::~Zip() +Zip::~Zip() { if (_tmpBuffer) delete[] _tmpBuffer; } size_t -Imf::Zip::maxRawSize() +Zip::maxRawSize() { return _maxRawSize; } size_t -Imf::Zip::maxCompressedSize() +Zip::maxCompressedSize() { return uiAdd (uiAdd (_maxRawSize, size_t (ceil (_maxRawSize * 0.01))), @@ -77,7 +77,7 @@ Imf::Zip::maxCompressedSize() } int -Imf::Zip::compress(const char *raw, int rawSize, char *compressed) +Zip::compress(const char *raw, int rawSize, char *compressed) { // // Reorder the pixel data. @@ -129,14 +129,14 @@ Imf::Zip::compress(const char *raw, int rawSize, char *compressed) if (Z_OK != ::compress ((Bytef *)compressed, &outSize, (const Bytef *) _tmpBuffer, rawSize)) { - throw Iex::BaseExc ("Data compression (zlib) failed."); + throw IEX_NAMESPACE::BaseExc ("Data compression (zlib) failed."); } return outSize; } int -Imf::Zip::uncompress(const char *compressed, int compressedSize, +Zip::uncompress(const char *compressed, int compressedSize, char *raw) { // @@ -148,7 +148,7 @@ Imf::Zip::uncompress(const char *compressed, int compressedSize, if (Z_OK != ::uncompress ((Bytef *)_tmpBuffer, &outSize, (const Bytef *) compressed, compressedSize)) { - throw Iex::InputExc ("Data decompression (zlib) failed."); + throw IEX_NAMESPACE::InputExc ("Data decompression (zlib) failed."); } // diff --git a/OpenEXR/IlmImf/dwaLookups.cpp b/OpenEXR/IlmImf/dwaLookups.cpp index 19ec8311c0..8048878c2e 100644 --- a/OpenEXR/IlmImf/dwaLookups.cpp +++ b/OpenEXR/IlmImf/dwaLookups.cpp @@ -62,11 +62,11 @@ namespace { class LutHeaderWorker { public: - class Runner : public IlmThread::Thread + class Runner : public ILMTHREAD_NAMESPACE::Thread { public: Runner(LutHeaderWorker &worker, bool output): - IlmThread::Thread(), + ILMTHREAD_NAMESPACE::Thread(), _worker(worker), _output(output) { @@ -87,7 +87,7 @@ namespace { private: LutHeaderWorker &_worker; bool _output; - IlmThread::Semaphore _semaphore; + ILMTHREAD_NAMESPACE::Semaphore _semaphore; }; // class LutHeaderWorker::Runner @@ -436,7 +436,7 @@ generateToNonlinear() int cpuCount() { - if (!IlmThread::supportsThreads()) return 1; + if (!ILMTHREAD_NAMESPACE::supportsThreads()) return 1; int cpuCount = 1; @@ -492,7 +492,7 @@ generateLutHeader() } } - if (IlmThread::supportsThreads()) { + if (ILMTHREAD_NAMESPACE::supportsThreads()) { std::vector runners; for (size_t i=0; i &src, - const OPENEXR_IMF_NAMESPACE::Array2D &test, + const OPENEXR_IMF_NAMESPACE::Array2D &src, + const OPENEXR_IMF_NAMESPACE::Array2D &test, OPENEXR_IMF_NAMESPACE::RgbaChannels channels); #endif diff --git a/OpenEXR/IlmImfUtil/ImfDeepImageLevel.cpp b/OpenEXR/IlmImfUtil/ImfDeepImageLevel.cpp index 79e5b5615c..44a6e45fec 100644 --- a/OpenEXR/IlmImfUtil/ImfDeepImageLevel.cpp +++ b/OpenEXR/IlmImfUtil/ImfDeepImageLevel.cpp @@ -137,7 +137,7 @@ DeepImageLevel::initializeSampleLists () void -DeepImageLevel::resize (const Imath::Box2i& dataWindow) +DeepImageLevel::resize (const IMATH_NAMESPACE::Box2i& dataWindow) { // // Note: if the following code throws an exception, then the image level diff --git a/OpenEXR/IlmImfUtil/ImfFlatImageLevel.cpp b/OpenEXR/IlmImfUtil/ImfFlatImageLevel.cpp index dea943dc4c..574c3fd2a0 100644 --- a/OpenEXR/IlmImfUtil/ImfFlatImageLevel.cpp +++ b/OpenEXR/IlmImfUtil/ImfFlatImageLevel.cpp @@ -83,7 +83,7 @@ FlatImageLevel::~FlatImageLevel () void -FlatImageLevel::resize (const Imath::Box2i& dataWindow) +FlatImageLevel::resize (const IMATH_NAMESPACE::Box2i& dataWindow) { // // Note: if the following code throws an exception, then the image level diff --git a/OpenEXR/IlmImfUtil/ImfImage.cpp b/OpenEXR/IlmImfUtil/ImfImage.cpp index bf0d64bc32..a057f29047 100644 --- a/OpenEXR/IlmImfUtil/ImfImage.cpp +++ b/OpenEXR/IlmImfUtil/ImfImage.cpp @@ -337,7 +337,7 @@ Image::levelHeight (int ly) const void -Image::resize (const Imath::Box2i &dataWindow) +Image::resize (const IMATH_NAMESPACE::Box2i &dataWindow) { resize (dataWindow, _levelMode, _levelRoundingMode); } @@ -345,7 +345,7 @@ Image::resize (const Imath::Box2i &dataWindow) void Image::resize - (const Imath::Box2i &dataWindow, + (const IMATH_NAMESPACE::Box2i &dataWindow, LevelMode levelMode, LevelRoundingMode levelRoundingMode) { diff --git a/OpenEXR/IlmImfUtil/ImfImageLevel.cpp b/OpenEXR/IlmImfUtil/ImfImageLevel.cpp index 0c65818d90..f93fc70ec8 100644 --- a/OpenEXR/IlmImfUtil/ImfImageLevel.cpp +++ b/OpenEXR/IlmImfUtil/ImfImageLevel.cpp @@ -70,7 +70,7 @@ ImageLevel::~ImageLevel () void -ImageLevel::resize (const Imath::Box2i& dataWindow) +ImageLevel::resize (const IMATH_NAMESPACE::Box2i& dataWindow) { if (dataWindow.max.x < dataWindow.min.x - 1|| dataWindow.max.y < dataWindow.min.y - 1)