diff options
| author | callum <none@none> | 2011-01-05 15:52:43 -0800 |
|---|---|---|
| committer | callum <none@none> | 2011-01-05 15:52:43 -0800 |
| commit | b9ca6c553cf158c5b485947f8b560228a196c1d7 (patch) | |
| tree | df710eb467a1c0fbfb5d7906232f23a36f6fc7c1 /indra/llkdu/llimagej2ckdu.cpp | |
| parent | ed3ea14984e322462ed466805e47b29a6f658279 (diff) | |
| parent | d5a0c56bf5d933b7cee072cbc1851a626e672ded (diff) | |
Merge with viewer-development
Diffstat (limited to 'indra/llkdu/llimagej2ckdu.cpp')
| -rw-r--r-- | indra/llkdu/llimagej2ckdu.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/indra/llkdu/llimagej2ckdu.cpp b/indra/llkdu/llimagej2ckdu.cpp index 1a286d1406..10ea5685e8 100644 --- a/indra/llkdu/llimagej2ckdu.cpp +++ b/indra/llkdu/llimagej2ckdu.cpp @@ -229,16 +229,17 @@ void LLImageJ2CKDU::setupCodeStream(LLImageJ2C &base, BOOL keep_codestream, ECod mCodeStreamp = NULL; } - if (!mInputp) + if (!mInputp && base.getData()) { - llassert(base.getData()); // The compressed data has been loaded - // Setup the source for the codestrea + // Setup the source for the codestream mInputp = new LLKDUMemSource(base.getData(), data_size); } - llassert(mInputp); - mInputp->reset(); + if (mInputp) + { + mInputp->reset(); + } mCodeStreamp = new kdu_codestream; mCodeStreamp->create(mInputp); @@ -1017,7 +1018,7 @@ kdc_flow_control::kdc_flow_control (kdu_image_in_base *img_in, kdu_codestream co comp->ratio_counter = 0; comp->remaining_lines = comp->initial_lines = dims.size.y; } - assert(num_components > 0); + assert(num_components >= 0); tile.set_components_of_interest(num_components); max_buffer_memory = engine.create(codestream,tile,false,NULL,false,1,NULL,NULL,false); |
