Searched refs:capacity (Results 1 - 25 of 64) sorted by relevance

123

/frameworks/base/tests/AccessoryDisplay/common/src/com/android/accessorydisplay/common/
H A DBufferPool.java68 int capacity = buffer.capacity();
69 if (capacity < needed) {
71 capacity = chooseCapacity(capacity, needed);
72 buffer = ByteBuffer.allocate(capacity);
79 private int chooseCapacity(int capacity, int needed) { argument
80 while (capacity < needed) {
81 capacity *= 2;
83 if (capacity > mMaxBufferSiz
[all...]
H A DTransport.java120 final int capacity = mOutputBuffer.capacity();
136 final int outputAvailable = capacity - mOutputBuffer.position();
144 ioWrite(outputArray, 0, capacity);
306 count = ioRead(buffer.array(), position, buffer.capacity() - position);
/frameworks/av/media/libstagefright/foundation/
H A DABuffer.cpp26 ABuffer::ABuffer(size_t capacity) argument
28 mData(malloc(capacity)),
29 mCapacity(capacity),
31 mRangeLength(capacity),
36 ABuffer::ABuffer(void *data, size_t capacity) argument
39 mCapacity(capacity),
41 mRangeLength(capacity),
47 sp<ABuffer> ABuffer::CreateAsCopy(const void *data, size_t capacity) argument
49 sp<ABuffer> res = new ABuffer(capacity);
50 memcpy(res->data(), data, capacity);
[all...]
/frameworks/base/core/java/com/google/android/collect/
H A DLists.java59 int capacity = (elements.length * 110) / 100 + 5;
60 ArrayList<E> list = new ArrayList<E>(capacity);
H A DSets.java67 int capacity = elements.length * 4 / 3 + 1;
68 HashSet<E> set = new HashSet<E>(capacity);
106 int capacity = elements.length * 4 / 3 + 1;
107 ArraySet<E> set = new ArraySet<E>(capacity);
/frameworks/av/include/media/stagefright/foundation/
H A DABuffer.h33 ABuffer(size_t capacity);
34 ABuffer(void *data, size_t capacity);
40 size_t capacity() const { return mCapacity; } function in struct:android::ABuffer
47 static sp<ABuffer> CreateAsCopy(const void *data, size_t capacity);
/frameworks/base/media/mca/filterfw/java/android/filterfw/core/
H A DNativeFrame.java38 int capacity = format.getSize();
39 nativeAllocate(capacity);
40 setReusable(capacity != 0);
232 private native boolean nativeAllocate(int capacity); argument
/frameworks/support/v4/java/android/support/v4/util/
H A DArrayMap.java46 * you have no control over this shrinking -- if you set a capacity and then remove an
47 * item, it may reduce the capacity to better match the current size. In the future an
48 * explicit call to set the capacity should turn off this aggressive shrinking behavior.</p>
58 * Create a new ArrayMap with a given initial capacity.
60 public ArrayMap(int capacity) { argument
61 super(capacity);
H A DSimpleArrayMap.java36 * The minimum amount by which the capacity of a ArrayMap will increase.
205 * Create a new empty ArrayMap. The default capacity of an array map is 0, and
215 * Create a new ArrayMap with a given initial capacity.
217 public SimpleArrayMap(int capacity) { argument
218 if (capacity == 0) {
222 allocArrays(capacity);
/frameworks/base/core/java/android/content/
H A DContentQueryMap.java150 int capacity = mValues != null ? mValues.size() : 0;
151 mValues = new HashMap<String, ContentValues>(capacity);
/frameworks/av/include/ndk/
H A DNdkMediaExtractor.h92 ssize_t AMediaExtractor_readSampleData(AMediaExtractor*, uint8_t *buffer, size_t capacity);
/frameworks/base/tests/AccessoryDisplay/sink/src/com/android/accessorydisplay/sink/
H A DDisplaySinkService.java203 final int capacity = buffer.capacity();
205 if (content.remaining() <= capacity) {
209 content.limit(content.position() + capacity);
/frameworks/rs/
H A DrsCppUtils.h106 void setCapacity(ssize_t capacity) { argument
107 this->resize(capacity);
132 void setCapacity(ssize_t capacity) { argument
133 this->resize(capacity);
/frameworks/base/core/java/android/os/
H A DPersistableBundle.java58 * @param capacity the initial capacity of the PersistableBundle
60 public PersistableBundle(int capacity) { argument
61 super(capacity);
H A DBaseBundle.java64 * @param capacity Initial size of the ArrayMap.
66 BaseBundle(ClassLoader loader, int capacity) { argument
67 mMap = capacity > 0 ?
68 new ArrayMap<String, Object>(capacity) : new ArrayMap<String, Object>();
108 * @param capacity the initial capacity of the Bundle
110 BaseBundle(int capacity) { argument
111 this((ClassLoader) null, capacity);
/frameworks/base/media/mca/filterfw/native/core/
H A Dshader_program.cpp386 GLint capacity; local
391 glGetActiveUniform(program_, i, buffer_size, NULL, &capacity, &type, &name[0]);
715 GLint capacity; local
718 glGetActiveUniform(program_, IndexOfUniform(var), 128, NULL, &capacity, &type, name);
722 if (!CheckValueCount("Uniform (int)", name, capacity, components, count)
766 GLint capacity; local
769 glGetActiveUniform(program_, IndexOfUniform(var), 128, NULL, &capacity, &type, name);
773 if (!CheckValueCount("Uniform (float)", name, capacity, components, count)
842 GLint capacity; local
844 glGetActiveUniform(program_, IndexOfUniform(var), 0, NULL, &capacity,
[all...]
/frameworks/base/core/jni/
H A Dandroid_database_CursorWindow.cpp251 jsize capacity = env->GetArrayLength(dataObj); local
252 if (size_t(capacity) < size) {
258 jsize capacity = size; local
259 if (capacity < 64) {
260 capacity = 64;
262 dataObj = env->NewCharArray(capacity); // might throw OOM
H A Dcom_android_internal_net_NetworkStatsFactory.cpp40 jfieldID capacity; member in struct:android::__anon882
226 bool grow = size > env->GetIntField(stats, gNetworkStatsClassInfo.capacity);
271 env->SetIntField(stats, gNetworkStatsClassInfo.capacity, size);
311 gNetworkStatsClassInfo.capacity = env->GetFieldID(clazz, "capacity", "I");
/frameworks/base/core/java/android/hardware/camera2/
H A DDngCreator.java455 long capacity = pixels.capacity();
457 if (capacity < totalSize) {
458 throw new IllegalArgumentException("Image size " + capacity +
/frameworks/base/core/java/android/net/
H A DNetworkStats.java68 private int capacity; field in class:NetworkStats
161 this.capacity = initialSize;
173 this.capacity = 0;
189 capacity = parcel.readInt();
205 dest.writeInt(capacity);
247 if (size >= capacity) {
258 capacity = newLength;
314 return capacity;
578 if (recycle != null && recycle.capacity >= left.size) {
/frameworks/compile/mclinker/include/mcld/LD/
H A DNamePool.h128 // ----- capacity ----- //
131 size_type capacity() const;
/frameworks/av/media/libstagefright/rtsp/
H A DARTPSource.cpp179 if (buffer->size() + 20 > buffer->capacity()) {
217 if (buffer->size() + 32 > buffer->capacity()) {
/frameworks/native/opengl/tests/testViewport/src/com/android/test/
H A DTestView.java197 gl11.glBufferData(GL11.GL_ARRAY_BUFFER, mVertexByteBuffer.capacity(), mVertexByteBuffer, GL11.GL_STATIC_DRAW);
201 gl11.glBufferData(GL11.GL_ELEMENT_ARRAY_BUFFER, mIndexBuffer.capacity() * CHAR_SIZE, mIndexBuffer, GL11.GL_STATIC_DRAW);
/frameworks/base/core/java/android/util/
H A DArraySet.java42 * you have no control over this shrinking -- if you set a capacity and then remove an
43 * item, it may reduce the capacity to better match the current size. In the future an
44 * explicit call to set the capacity should turn off this aggressive shrinking behavior.</p>
53 * The minimum amount by which the capacity of a ArraySet will increase.
223 * Create a new empty ArraySet. The default capacity of an array map is 0, and
233 * Create a new ArraySet with a given initial capacity.
235 public ArraySet(int capacity) { argument
236 if (capacity == 0) {
240 allocArrays(capacity);
/frameworks/av/media/libstagefright/
H A DSkipCutBuffer.cpp91 size_t copied = read(dst, buffer->capacity());

Completed in 573 milliseconds

123