From 55dc066a3f5905d3d64d500b3887383c87fa10ac Mon Sep 17 00:00:00 2001 From: David Williams Date: Mon, 19 Aug 2013 16:27:52 +0200 Subject: [PATCH] Fixed bug with MinizBlockCompressor always saving out 10,000 bytes of data. --- .../PolyVoxCore/include/PolyVoxCore/MinizBlockCompressor.inl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/PolyVoxCore/include/PolyVoxCore/MinizBlockCompressor.inl b/library/PolyVoxCore/include/PolyVoxCore/MinizBlockCompressor.inl index 67501ea9..39afa12f 100644 --- a/library/PolyVoxCore/include/PolyVoxCore/MinizBlockCompressor.inl +++ b/library/PolyVoxCore/include/PolyVoxCore/MinizBlockCompressor.inl @@ -53,7 +53,7 @@ namespace PolyVox uCompressedLength = m_pCompressor->compress(pSrcData, uSrcLength, pDstData, uDstLength); // Copy the resulting compressed data into the compressed block - pDstBlock->setData(pDstData, uDstLength); + pDstBlock->setData(pDstData, uCompressedLength); } catch(std::exception&) { @@ -74,7 +74,7 @@ namespace PolyVox uCompressedLength = m_pCompressor->compress(pSrcData, uSrcLength, pDstData, uDstLength); // Copy the resulting compressed data into the compressed block - pDstBlock->setData(pDstData, uDstLength); + pDstBlock->setData(pDstData, uCompressedLength); } catch(std::exception&) {