<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to bugs</title><link href="https://sourceforge.net/p/bcl/bugs/" rel="alternate"/><link href="https://sourceforge.net/p/bcl/bugs/feed.atom" rel="self"/><id>https://sourceforge.net/p/bcl/bugs/</id><updated>2014-01-15T17:51:15.341000Z</updated><subtitle>Recent changes to bugs</subtitle><entry><title>rice bug</title><link href="https://sourceforge.net/p/bcl/bugs/2/" rel="alternate"/><published>2014-01-15T17:51:15.341000Z</published><updated>2014-01-15T17:51:15.341000Z</updated><author><name>chloe</name><uri>https://sourceforge.net/u/xalverti/</uri></author><id>https://sourceforge.netb0d5435661aecad43314aa132ae4f29b21415fc6</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;If I use rice compression algorithm of version 1.2 (the latest stable) over a matrix of 16 unsigned integers with these values : {1411412594,543517801,623395913,10601,1917279067,1768452193,1566401908,1043148064,1142971168,1650553705, ,1735289196,1919242272,1836216166,1701015137,1684955424,2003783712} the decompression is not done properly and the last number is not decoded in the right way. Although I do not know where the problem relies and I was hoping that you could help me.&lt;/p&gt;
&lt;p&gt;Chloe&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>problems in rice.c</title><link href="https://sourceforge.net/p/bcl/bugs/1/" rel="alternate"/><published>2004-10-05T15:24:28Z</published><updated>2004-10-05T15:24:28Z</updated><author><name>aaditya sood</name><uri>https://sourceforge.net/u/aaditya/</uri></author><id>https://sourceforge.net67fb3b312473b4fb077dc313201aff6d705898f3</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I'm getting data corruption in Rice impletation.&lt;/p&gt;
&lt;p&gt;Using latest release 1.0.6&lt;/p&gt;
&lt;p&gt;* $Id: rice.h,v 1.2 2004/02/17 20:54:37 marcus256 Exp $ &lt;br /&gt;
* $Id: rice.c,v 1.2 2004/02/17 20:54:37 marcus256 Exp $&lt;/p&gt;
&lt;p&gt;You can reach me: aadis at aadis dot de&lt;/p&gt;
&lt;p&gt;I'm trying to debug it too.&lt;/p&gt;
&lt;p&gt;Small test program is included:&lt;/p&gt;
&lt;p&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;
#include&amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
#include&amp;lt;assert.h&amp;gt;&lt;/p&gt;
&lt;p&gt;#include"bcl/rice.h"&lt;/p&gt;
&lt;p&gt;#define mysize (1024*1024)&lt;/p&gt;
&lt;p&gt;int main(int argc, char*argv[])&lt;br /&gt;
{&lt;/p&gt;
&lt;p&gt;signed char *in_data = malloc(sizeof(signed&lt;br /&gt;
char)*mysize);&lt;br /&gt;
signed char *in_data_compressed =&lt;br /&gt;
malloc(sizeof(signed char)*(mysize+400));&lt;br /&gt;
signed char *in_data_uncompressed =&lt;br /&gt;
malloc(sizeof(signed char)*mysize);&lt;br /&gt;
int test_passed=1;&lt;/p&gt;
&lt;p&gt;srand(0);&lt;br /&gt;
unsigned int i;&lt;/p&gt;
&lt;p&gt;for(i=0;i&amp;lt;mysize;i++){&lt;br /&gt;
in_data[i]=(rand()%256)-128;               &lt;br /&gt;
//set all values between -128 and 127&lt;br /&gt;
assert((in_data[i]&amp;gt;=-128)&amp;amp;&amp;amp;(in_data[i]&amp;lt;=127));&lt;br /&gt;
//ensure data is valid&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;unsigned int compressed_size = Rice_Compress (&lt;br /&gt;
(void*) in_data, (void*) in_data_compressed, mysize,&lt;br /&gt;
RICE_FMT_INT8);&lt;br /&gt;
printf("data compressed from %d to %d&lt;br /&gt;
bytes\n",mysize,compressed_size);&lt;/p&gt;
&lt;p&gt;Rice_Uncompress ((void*) in_data_compressed,&lt;br /&gt;
(void*) in_data_uncompressed, compressed_size, mysize,&lt;br /&gt;
RICE_FMT_INT8);&lt;br /&gt;
printf("data uncompressed from %d to %d&lt;br /&gt;
bytes\n",compressed_size,mysize);&lt;/p&gt;
&lt;p&gt;for(i=0;i&amp;lt;mysize;i++)&lt;br /&gt;
if(in_data[i]!=in_data_uncompressed[i]) { &lt;br /&gt;
printf("FAILED for [i:%d] actual:%d vs&lt;br /&gt;
uncompressed:%d\n",i,in_data[i],in_data_uncompressed[i]); &lt;br /&gt;
printf("breaking out of loop...\n");&lt;br /&gt;
test_passed=0;&lt;br /&gt;
break;&lt;/p&gt;
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt;if(test_passed==1)&lt;br /&gt;
printf("Test passed\n");&lt;br /&gt;
else&lt;br /&gt;
printf("Test failed\n");&lt;/p&gt;
&lt;p&gt;return 0;&lt;br /&gt;
}&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>