/frameworks/base/core/java/com/android/internal/util/ |
D | LineBreakBufferedWriter.java | 48 private final int bufferSize; field in LineBreakBufferedWriter 68 public LineBreakBufferedWriter(Writer out, int bufferSize) { in LineBreakBufferedWriter() argument 69 this(out, bufferSize, 16); // 16 is the default size of a StringBuilder buffer. in LineBreakBufferedWriter() 79 public LineBreakBufferedWriter(Writer out, int bufferSize, int initialCapacity) { in LineBreakBufferedWriter() argument 81 this.buffer = new char[Math.min(initialCapacity, bufferSize)]; in LineBreakBufferedWriter() 83 this.bufferSize = bufferSize; in LineBreakBufferedWriter() 119 while (bufferIndex + len > bufferSize) { in write() 123 int maxLength = bufferSize - bufferIndex; in write() 126 if (bufferIndex + i < bufferSize) { in write() 149 int rest = bufferSize - bufferIndex; in write() [all …]
|
/frameworks/base/core/java/android/ddm/ |
D | DdmHandleThread.java | 146 int bufferSize = 0; in createStackChunk() local 148 bufferSize += 4; // version, flags, whatever in createStackChunk() 149 bufferSize += 4; // thread ID in createStackChunk() 150 bufferSize += 4; // frame count in createStackChunk() 152 bufferSize += 4 + elem.getClassName().length() * 2; in createStackChunk() 153 bufferSize += 4 + elem.getMethodName().length() * 2; in createStackChunk() 154 bufferSize += 4; in createStackChunk() 156 bufferSize += elem.getFileName().length() * 2; in createStackChunk() 157 bufferSize += 4; // line number in createStackChunk() 160 ByteBuffer out = ByteBuffer.allocate(bufferSize); in createStackChunk()
|
D | DdmHandleProfiling.java | 105 int bufferSize = in.getInt(); in handleMPRS() local 111 + "', size=" + bufferSize + ", flags=" + flags); in handleMPRS() 114 Debug.startMethodTracing(fileName, bufferSize, flags); in handleMPRS() 147 int bufferSize = in.getInt(); in handleMPSS() local 150 Log.v("ddm-heap", "Method prof stream start: size=" + bufferSize in handleMPSS() 155 Debug.startMethodTracingDdms(bufferSize, flags, false, 0); in handleMPSS() 200 int bufferSize = in.getInt(); in handleSPSS() local 204 Log.v("ddm-heap", "Sample prof stream start: size=" + bufferSize in handleSPSS() 209 Debug.startMethodTracingDdms(bufferSize, flags, true, interval); in handleSPSS()
|
/frameworks/av/drm/common/ |
D | IDrmManagerService.cpp | 177 const int bufferSize = reply.readInt32(); in getConstraints() local 179 if (0 < bufferSize) { in getConstraints() 180 data = new char[bufferSize]; in getConstraints() 181 reply.read(data, bufferSize); in getConstraints() 207 const int bufferSize = reply.readInt32(); in getMetadata() local 209 if (0 < bufferSize) { in getMetadata() 210 data = new char[bufferSize]; in getMetadata() 211 reply.read(data, bufferSize); in getMetadata() 273 const int bufferSize = reply.readInt32(); in processDrmInfo() local 275 if (0 < bufferSize) { in processDrmInfo() [all …]
|
/frameworks/av/include/media/ |
D | DataSource.h | 59 virtual bool getUri(char *uriString, size_t bufferSize) final { in getUri() argument 60 int ret = snprintf(uriString, bufferSize, "%s", getUri().c_str()); in getUri() 61 return ret >= 0 && static_cast<size_t>(ret) < bufferSize; in getUri() 84 mWrapper->getUri = [](void *handle, char *uriString, size_t bufferSize) -> bool { in wrap() 85 return ((DataSource*)handle)->getUri(uriString, bufferSize); in wrap()
|
/frameworks/base/packages/BackupEncryption/src/com/android/server/backup/encryption/ |
D | StreamUtils.java | 50 int bufferSize = Math.min(MAX_COPY_BUFFER_SIZE, limit); in copyStream() local 51 byte[] buffer = new byte[bufferSize]; in copyStream() 55 int maxReadSize = Math.min(bufferSize, limit - copied); in copyStream()
|
/frameworks/av/media/libstagefright/ |
D | AudioSource.cpp | 361 const size_t bufferSize = audioBuffer.size; in dataCallback() local 366 int64_t receievedFrames = bufferSize / mRecord->frameSize(); in dataCallback() 407 uint64_t bufferSize = numLostBytes; in dataCallback() local 410 bufferSize = kMaxBufferSize; in dataCallback() 414 MediaBuffer *lostAudioBuffer = new MediaBuffer(bufferSize); in dataCallback() 415 memset(lostAudioBuffer->data(), 0, bufferSize); in dataCallback() 416 lostAudioBuffer->set_range(0, bufferSize); in dataCallback() 417 mNumFramesLost += bufferSize / mRecord->frameSize(); in dataCallback() 426 MediaBuffer *buffer = new MediaBuffer(bufferSize); in dataCallback() 429 buffer->set_range(0, bufferSize); in dataCallback() [all …]
|
D | CallbackDataSource.cpp | 66 const size_t bufferSize = mMemory->size(); in readAt() local 69 size_t numToRead = std::min(numLeft, bufferSize); in readAt() 83 CHECK(numRead >= 0 && (size_t)numRead <= bufferSize); in readAt()
|
/frameworks/opt/photoviewer/src/com/android/ex/photo/util/ |
D | InputStreamBuffer.java | 97 public InputStreamBuffer(final InputStream inputStream, int bufferSize, in InputStreamBuffer() argument 100 if (bufferSize <= 0) { in InputStreamBuffer() 102 String.format("Buffer size %d must be positive.", bufferSize)); in InputStreamBuffer() 104 bufferSize = leastPowerOf2(bufferSize); in InputStreamBuffer() 105 mBuffer = new byte[bufferSize]; in InputStreamBuffer()
|
/frameworks/opt/bitmap/src/com/android/bitmap/util/ |
D | InputStreamBuffer.java | 97 public InputStreamBuffer(final InputStream inputStream, int bufferSize, in InputStreamBuffer() argument 100 if (bufferSize <= 0) { in InputStreamBuffer() 102 String.format("Buffer size %d must be positive.", bufferSize)); in InputStreamBuffer() 104 bufferSize = leastPowerOf2(bufferSize); in InputStreamBuffer() 105 mBuffer = new byte[bufferSize]; in InputStreamBuffer()
|
/frameworks/av/media/libstagefright/codecs/m4v_h263/enc/src/ |
D | bitstream_io.cpp | 52 BitstreamEncVideo *BitStreamCreateEnc(Int bufferSize) in BitStreamCreateEnc() argument 60 stream->bufferSize = bufferSize; in BitStreamCreateEnc() 61 stream->bitstreamBuffer = (UChar *) M4VENC_MALLOC(stream->bufferSize * sizeof(UChar)); in BitStreamCreateEnc() 68 M4VENC_MEMSET(stream->bitstreamBuffer, 0, stream->bufferSize*sizeof(UChar)); in BitStreamCreateEnc() 213 if (stream->byteCount + WORD_SIZE > stream->bufferSize) in BitstreamSaveWord() 267 if (stream->byteCount + numbyte > stream->bufferSize) in BitstreamSavePartial() 446 if (bitstream1->byteCount + bitstream2->byteCount + offset > bitstream1->bufferSize) in BitstreamAppendEnc() 498 if (bitstream1->byteCount + bitstream2->byteCount > bitstream1->bufferSize) in BitstreamAppendPacket() 541 if (bitstream1->byteCount + bitstream2->byteCount > bitstream1->bufferSize) in BitstreamAppendPacketNoOffset() 543 numbyte2 = bitstream1->bufferSize - bitstream1->byteCount; in BitstreamAppendPacketNoOffset() [all …]
|
/frameworks/base/cmds/statsd/tests/shell/ |
D | ShellSubscriber_test.cpp | 51 size_t bufferSize = config.ByteSize(); in runShellTest() local 53 write(fds_config[1], &bufferSize, sizeof(bufferSize)); in runShellTest() 55 vector<uint8_t> buffer(bufferSize); in runShellTest() 56 config.SerializeToArray(&buffer[0], bufferSize); in runShellTest() 57 write(fds_config[1], buffer.data(), bufferSize); in runShellTest()
|
/frameworks/base/packages/BackupEncryption/src/com/android/server/backup/encryption/tasks/ |
D | FullRestoreToFileTask.java | 56 FullRestoreToFileTask(FullRestoreDownloader fullRestoreDownloader, int bufferSize) { in FullRestoreToFileTask() argument 57 checkArgument(bufferSize > 0, "Buffer must have positive size"); in FullRestoreToFileTask() 60 this.mBufferSize = bufferSize; in FullRestoreToFileTask()
|
/frameworks/native/libs/binder/ |
D | BufferedTextOutput.cpp | 42 , bufferSize(0) in BufferState() 53 if ((len+bufferPos) > bufferSize) { in append() 59 bufferSize = newSize; in append() 69 if (bufferSize > 256) { in restart() 73 bufferSize = 256; in restart() 81 size_t bufferSize; member
|
/frameworks/base/cmds/statsd/src/shell/ |
D | ShellSubscriber.cpp | 85 size_t bufferSize; in readConfig() local 86 if (!android::base::ReadFully(subscriptionInfo->mInputFd, &bufferSize, sizeof(bufferSize))) { in readConfig() 91 vector<uint8_t> buffer(bufferSize); in readConfig() 92 if (!android::base::ReadFully(subscriptionInfo->mInputFd, buffer.data(), bufferSize)) { in readConfig() 98 if (!config.ParseFromArray(buffer.data(), bufferSize)) { in readConfig()
|
/frameworks/base/core/tests/coretests/src/android/graphics/ |
D | BitmapTest.java | 284 final int bufferSize = pad + width * height * bytesPerPixel / bytesPerElement + pad; in testCopyWithDirectByteBuffer() local 285 ByteBuffer directBuffer = ByteBuffer.allocateDirect(bufferSize); in testCopyWithDirectByteBuffer() 322 final int bufferSize = pad + width * height * bytesPerPixel / bytesPerElement + pad; in testCopyWithDirectShortBuffer() local 324 ByteBuffer.allocateDirect(bufferSize * bytesPerElement).asShortBuffer(); in testCopyWithDirectShortBuffer() 361 final int bufferSize = pad + width * height * bytesPerPixel / bytesPerElement + pad; in testCopyWithDirectIntBuffer() local 363 ByteBuffer.allocateDirect(bufferSize * bytesPerElement).asIntBuffer(); in testCopyWithDirectIntBuffer() 400 final int bufferSize = pad + width * height * bytesPerPixel / bytesPerElement + pad; in testCopyWithHeapByteBuffer() local 401 ByteBuffer heapBuffer = ByteBuffer.allocate(bufferSize); in testCopyWithHeapByteBuffer() 437 final int bufferSize = pad + width * height * bytesPerPixel / bytesPerElement + pad; in testCopyWithHeapShortBuffer() local 438 ShortBuffer heapBuffer = ShortBuffer.allocate(bufferSize); in testCopyWithHeapShortBuffer() [all …]
|
/frameworks/av/media/mtp/ |
D | MtpPacket.cpp | 31 MtpPacket::MtpPacket(int bufferSize) in MtpPacket() argument 33 mBufferSize(bufferSize), in MtpPacket() 34 mAllocationIncrement(bufferSize), in MtpPacket() 37 mBuffer = (uint8_t *)malloc(bufferSize); in MtpPacket()
|
/frameworks/base/libs/hwui/jni/ |
D | CreateJavaOutputStreamAdaptor.cpp | 182 size_t bufferSize = 4096; in adaptor_to_mem_stream() local 185 char* data = (char*)sk_malloc_throw(bufferSize); in adaptor_to_mem_stream() 188 bufferSize - streamLen)) != 0) { in adaptor_to_mem_stream() 190 if (streamLen == bufferSize) { in adaptor_to_mem_stream() 191 bufferSize *= 2; in adaptor_to_mem_stream() 192 data = (char*)sk_realloc_throw(data, bufferSize); in adaptor_to_mem_stream()
|
/frameworks/native/services/surfaceflinger/CompositionEngine/src/ |
D | OutputLayer.cpp | 116 const Rect& bufferSize = layerState.geomBufferSize; in calculateOutputSourceCrop() local 118 int winWidth = bufferSize.getWidth(); in calculateOutputSourceCrop() 119 int winHeight = bufferSize.getHeight(); in calculateOutputSourceCrop() 160 activeCrop.transform(invTransform, bufferSize.getWidth(), bufferSize.getHeight()); in calculateOutputSourceCrop() 188 const Rect& bufferSize = layerState.geomBufferSize; in calculateOutputDisplayFrame() local 190 if (!activeCrop.isEmpty() && bufferSize.isValid()) { in calculateOutputDisplayFrame() 202 if (!activeCrop.intersect(bufferSize, &activeCrop)) { in calculateOutputDisplayFrame() 206 activeTransparentRegion.orSelf(Rect(0, 0, bufferSize.getWidth(), activeCrop.top)); in calculateOutputDisplayFrame() 208 Rect(0, activeCrop.bottom, bufferSize.getWidth(), bufferSize.getHeight())); in calculateOutputDisplayFrame() 211 Rect(activeCrop.right, activeCrop.top, bufferSize.getWidth(), activeCrop.bottom)); in calculateOutputDisplayFrame()
|
/frameworks/av/media/libaaudio/src/fifo/ |
D | FifoController.h | 33 FifoController(fifo_frames_t bufferSize, fifo_frames_t threshold) in FifoController() argument 34 : FifoControllerBase(bufferSize, threshold) in FifoController()
|
/frameworks/base/cmds/statsd/src/metrics/ |
D | EventMetricProducer.cpp | 94 size_t bufferSize = protoOutput.size(); in serializeProtoLocked() local 96 std::unique_ptr<std::vector<uint8_t>> buffer(new std::vector<uint8_t>(bufferSize)); in serializeProtoLocked() 126 size_t bufferSize = mProto->size(); in onDumpReportLocked() local 128 (long long)mMetricId, bufferSize); in onDumpReportLocked()
|
/frameworks/base/services/robotests/backup/src/com/android/server/backup/testing/ |
D | Utils.java | 33 public static void transferStreamedData(InputStream in, OutputStream out, int bufferSize) in transferStreamedData() argument 35 byte[] buffer = new byte[bufferSize]; in transferStreamedData()
|
/frameworks/av/media/libstagefright/flac/dec/ |
D | FLACDecoder.cpp | 390 size_t bufferSize = blocksize * frameSize; in decodeOneFrame() local 391 if (bufferSize > *outBufferLen) { in decodeOneFrame() 393 *outBufferLen, bufferSize); in decodeOneFrame() 395 bufferSize = blocksize * frameSize; in decodeOneFrame() 414 *outBufferLen = bufferSize; in decodeOneFrame()
|
/frameworks/av/media/libmediaplayerservice/nuplayer/ |
D | NuPlayerDecoderPassThrough.cpp | 318 int32_t bufferSize = buffer->size(); in onInputBufferFetched() local 319 mCachedBytes += bufferSize; in onInputBufferFetched() 328 onBufferConsumed(bufferSize); in onInputBufferFetched() 336 onBufferConsumed(bufferSize); in onInputBufferFetched() 342 reply->setInt32("size", bufferSize); in onInputBufferFetched()
|
/frameworks/base/libs/androidfw/include/androidfw/ |
D | CursorWindow.h | 171 inline void* offsetToPtr(uint32_t offset, uint32_t bufferSize = 0) { 176 if (offset + bufferSize > mSize) { 178 offset + bufferSize, mSize);
|