Home | History | Annotate | Download | only in src

Lines Matching refs:byteCount

22 /*  Note byteCount doesn't have to be multiple of 2 or 4                        */
75 stream->byteCount = 0;
213 if (stream->byteCount + WORD_SIZE > stream->bufferSize)
217 stream->byteCount += WORD_SIZE;
222 ptr = stream->bitstreamBuffer + stream->byteCount;
226 /* NOTE: byteCount does not have to be multiple of 2 or 4 */
236 stream->byteCount += 4;
239 stream->byteCount += 2;
267 if (stream->byteCount + numbyte > stream->bufferSize)
271 stream->byteCount += numbyte;
276 ptr = stream->bitstreamBuffer + stream->byteCount;
280 stream->byteCount += numbyte;
309 /* note we don't update byteCount, bitLeft and word */
446 if (bitstream1->byteCount + bitstream2->byteCount + offset > bitstream1->bufferSize)
448 if (PV_SUCCESS != BitstreamUseOverrunBuffer(bitstream1, bitstream2->byteCount + offset))
450 bitstream1->byteCount += (bitstream2->byteCount + offset);
455 ptrBS1 = bitstream1->bitstreamBuffer + bitstream1->byteCount; /* move ptr bs1*/
461 numbyte2 = bitstream2->byteCount; /* number of byte to copy from bs2 */
462 bitstream1->byteCount += numbyte2; /* new byteCount */
498 if (bitstream1->byteCount + bitstream2->byteCount > bitstream1->bufferSize)
500 if (PV_SUCCESS != BitstreamUseOverrunBuffer(bitstream1, bitstream2->byteCount))
502 bitstream1->byteCount += bitstream2->byteCount; /* legacy, to keep track of total bytes */
507 ptrBS1 = bitstream1->bitstreamBuffer + bitstream1->byteCount; /* move ptr bs1*/
510 numbyte2 = bitstream2->byteCount;
511 bitstream1->byteCount += numbyte2; /* new byteCount */
539 numbyte2 = bitstream2->byteCount;
541 if (bitstream1->byteCount + bitstream2->byteCount > bitstream1->bufferSize)
543 numbyte2 = bitstream1->bufferSize - bitstream1->byteCount;
550 bitstream1->byteCount += numbyte2; /* should be equal to bufferSize */
559 byteleft = bitstream2->byteCount - numbyte2;
563 bitstream2->byteCount = byteleft;
574 /* Int byteCount, Int bitCount) */
581 PV_STATUS BitstreamRepos(BitstreamEncVideo *bitstream, Int byteCount, Int bitCount)
589 bitstream->byteCount = byteCount;
590 ptr = bitstream->bitstreamBuffer + byteCount; /* get fraction of the byte */
633 ptrSrc = bitstream1->bitstreamBuffer + bitstream1->byteCount;
640 bitstream1->byteCount = new_byte;
689 if (bitstream1->byteCount + bitstream2->byteCount >= bitstream1->bufferSize)
691 bitstream1->byteCount += bitstream2->byteCount;
695 movebyte = bitstream1->byteCount;
696 if (movebyte < bitstream2->byteCount)
697 movebyte = bitstream2->byteCount;
704 M4VENC_MEMCPY(pDst, pSrc, bitstream1->byteCount + 1);
707 M4VENC_MEMCPY(pSrc, bitstream2->bitstreamBuffer, bitstream2->byteCount + 1);
711 pDst = bitstream1->bitstreamBuffer + bitstream2->byteCount;
720 for (i = 0; i < bitstream1->byteCount + 1; i++)
726 bitstream1->byteCount += bitstream2->byteCount;
733 bitstream1->byteCount++;
738 bitstream2->byteCount = bitstream2->word = 0;
741 pSrc = bitstream1->bitstreamBuffer + bitstream1->byteCount;
763 return stream->byteCount*8 + (WORD_SIZE << 3) - stream->bitLeft;
770 stream->byteCount = 0;
795 if (stream->byteCount + numExtraBytes >= stream->oBSize)
797 stream->oBSize = stream->byteCount + numExtraBytes + 100;
815 memcpy(stream->overrunBuffer, stream->bitstreamBuffer, stream->byteCount);
821 if (stream->byteCount + numExtraBytes >= stream->oBSize)
823 stream->oBSize = stream->byteCount + numExtraBytes + 100;
836 memcpy(video->overrunBuffer, stream->overrunBuffer, stream->byteCount);