Fixed seekBuffer functionality
This commit is contained in:
parent
e5c9d5d74f
commit
98006ee300
@ -26,11 +26,11 @@ void setBuffer(Buffer buffer, void *data){
|
|||||||
void seekBuffer(Buffer buffer, unsigned int position){
|
void seekBuffer(Buffer buffer, unsigned int position){
|
||||||
switch (buffer){
|
switch (buffer){
|
||||||
case BUF_IN:
|
case BUF_IN:
|
||||||
inByteOffset = position - (position % 8);
|
inByteOffset = position / 8;
|
||||||
inBitOffset = position % 8;
|
inBitOffset = position % 8;
|
||||||
break;
|
break;
|
||||||
case BUF_OUT:
|
case BUF_OUT:
|
||||||
outByteOffset = position - (position % 8);
|
outByteOffset = position / 8;
|
||||||
outBitOffset = position % 8;
|
outBitOffset = position % 8;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user