image compression using golomb-rice algorithm

Joined
Mar 29, 2013
Messages
1
Reaction score
0
plz help me
my project is image compression using gr algorithm any one have plz help me equalent vhdl code give me....and also attach the c code for my project one part for gr c code.
plz help me ............i am so help less sir,,,,,,,,,,, this is my carrier ....................
my c code is
c code for unarry
Encoding:
UnaryEncode(n) {
while (n > 0) {
WriteBit(1);
n--;
}
WriteBit(0);
}


Decoding: UnaryDecode() {
n = 0;
while (ReadBit(1) == 1) {
n++;
}
return n;
}
c code for golomb-rice

Encoding:
GolombEncode(n, RBits) {
q = n >> RBits;
UnaryCode(q);
WriteBits(n, RBits);
}
decoding:
GolombDecode(RBits) {
q = UnaryDecode();
n = (q << RBits) + ReadBits(RBits);
return n;
}
 
Last edited:

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top