Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DWAx_COMPRESION v2 #119

Merged
merged 5 commits into from
Aug 5, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
957 changes: 617 additions & 340 deletions OpenEXR/IlmImf/ImfDwaCompressor.cpp

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions OpenEXR/IlmImf/ImfDwaCompressor.h
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ class DwaCompressor: public Compressor
ChannelList _channels;
std::vector<ChannelData> _channelData;
std::vector<CscChannelSet> _cscSets;
std::vector<Classifier> _channelRules;

char *_packedAcBuffer;
size_t _packedAcBufferSize;
Expand All @@ -178,6 +179,12 @@ class DwaCompressor: public Compressor
Imath::Box2i range,
const char *&outPtr);

void initializeBuffers (size_t&);
void initializeDefaultChannelRules ();
void initializeLegacyChannelRules ();

void relevantChannelRules( std::vector<Classifier> &) const;

//
// Populate our cached version of the channel data with
// data from the real channel list. We want to
Expand Down
Binary file added OpenEXR/IlmImfTest/comp_dwaa_piz.exr
Binary file not shown.
Binary file added OpenEXR/IlmImfTest/comp_dwaa_v1.exr
Binary file not shown.
Binary file added OpenEXR/IlmImfTest/comp_dwaa_v2.exr
Binary file not shown.
Binary file added OpenEXR/IlmImfTest/comp_dwab_piz.exr
Binary file not shown.
Binary file added OpenEXR/IlmImfTest/comp_dwab_v1.exr
Binary file not shown.
Binary file added OpenEXR/IlmImfTest/comp_dwab_v2.exr
Binary file not shown.
11 changes: 11 additions & 0 deletions OpenEXR/IlmImfTest/testSampleImages.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,17 @@ testSampleImages (const std::string&)
compareImages (ILM_IMF_TEST_IMAGEDIR "comp_b44.exr",
ILM_IMF_TEST_IMAGEDIR "comp_b44_piz.exr");

compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwaa_v1.exr",
ILM_IMF_TEST_IMAGEDIR "comp_dwaa_piz.exr");
compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwaa_v2.exr",
ILM_IMF_TEST_IMAGEDIR "comp_dwaa_piz.exr");

compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwab_v1.exr",
ILM_IMF_TEST_IMAGEDIR "comp_dwab_piz.exr");
compareImages (ILM_IMF_TEST_IMAGEDIR "comp_dwab_v2.exr",
ILM_IMF_TEST_IMAGEDIR "comp_dwab_piz.exr");


cout << "ok\n" << endl;
}
catch (const std::exception &e)
Expand Down