- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I have some code which encode multiple images (of the same size) in PNG format with only one header. Basically, it does as follow :
Create PNG Struct
Write PNG header
Write 1st image (n*png_write_row, deflateReset at the end)
Reinitialize some fields in png struct
Write 2nd image (n*png_write_row, deflateReset at the end)
Reinitialize some fields in png struct and so on...
Destroy PNG struct
When using standard zlib, all is working fine.
When using ipp_zlib, I get an access violation in ippsCopy_8u (deflate function, line 107 of the function).
It seems that deflateReset has missed something.
I get it to work fine with the following workaround :
[cpp]s = (deflate_state *)strm->state;
s->in_tmpbuff_avail = TMP_BUF_SIZE;
s->in_tmpbuff_next = s->in_tmpbuff_ptr;
s->in_tmpbuff_valid = 1;
s->pending = 0;
s->pending_out = s->pending_buf;
[/cpp]
I've never really looked at the code in zlib nor in ipp_zlib so I don't know if that workaround is really valid or if another correction should be made elsewhere. If someone more enlightened than me could have a look to see if using deflateReset really works or if I missed something, it would be great.
Thanks.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Regards,
Ying
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Regards,
Ying
Thanks for your answer,
I'll wait for the next update.
Regards,
Matthieu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I've just downloaded IPP 6.0 update 1 along with the new sample and deflate now seems to work properly.
Thanks.
Matthieu
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page