Loading media/libstagefright/ACodec.cpp +0 −1 Original line number Diff line number Diff line Loading @@ -1215,7 +1215,6 @@ status_t ACodec::allocateOutputMetadataBuffers() { info.mCodecData = info.mData; info.mCodecRef = mem; // we use useBuffer for metadata regardless of quirks err = mOMXNode->useBuffer( kPortIndexOutput, mem, &info.mBufferID, mem->size()); mBuffers[kPortIndexOutput].push(info); Loading media/libstagefright/omx/OMXNodeInstance.cpp +5 −1 Original line number Diff line number Diff line Loading @@ -912,13 +912,17 @@ status_t OMXNodeInstance::useBuffer( OMX_BUFFERHEADERTYPE *header; OMX_ERRORTYPE err = OMX_ErrorNone; bool isMetadata = mMetadataType[portIndex] != kMetadataBufferTypeInvalid; bool isOutputGraphicMetadata = (portIndex == kPortIndexOutput) && (mMetadataType[portIndex] == kMetadataBufferTypeGrallocSource || mMetadataType[portIndex] == kMetadataBufferTypeANWBuffer); uint32_t requiresAllocateBufferBit = (portIndex == kPortIndexInput) ? kRequiresAllocateBufferOnInputPorts : kRequiresAllocateBufferOnOutputPorts; if (mQuirks & requiresAllocateBufferBit) { // we use useBuffer for output metadata regardless of quirks if (!isOutputGraphicMetadata && (mQuirks & requiresAllocateBufferBit)) { // metadata buffers are not connected cross process; only copy if not meta. buffer_meta = new BufferMeta( params, portIndex, !isMetadata /* copy */, NULL /* data */); Loading Loading
media/libstagefright/ACodec.cpp +0 −1 Original line number Diff line number Diff line Loading @@ -1215,7 +1215,6 @@ status_t ACodec::allocateOutputMetadataBuffers() { info.mCodecData = info.mData; info.mCodecRef = mem; // we use useBuffer for metadata regardless of quirks err = mOMXNode->useBuffer( kPortIndexOutput, mem, &info.mBufferID, mem->size()); mBuffers[kPortIndexOutput].push(info); Loading
media/libstagefright/omx/OMXNodeInstance.cpp +5 −1 Original line number Diff line number Diff line Loading @@ -912,13 +912,17 @@ status_t OMXNodeInstance::useBuffer( OMX_BUFFERHEADERTYPE *header; OMX_ERRORTYPE err = OMX_ErrorNone; bool isMetadata = mMetadataType[portIndex] != kMetadataBufferTypeInvalid; bool isOutputGraphicMetadata = (portIndex == kPortIndexOutput) && (mMetadataType[portIndex] == kMetadataBufferTypeGrallocSource || mMetadataType[portIndex] == kMetadataBufferTypeANWBuffer); uint32_t requiresAllocateBufferBit = (portIndex == kPortIndexInput) ? kRequiresAllocateBufferOnInputPorts : kRequiresAllocateBufferOnOutputPorts; if (mQuirks & requiresAllocateBufferBit) { // we use useBuffer for output metadata regardless of quirks if (!isOutputGraphicMetadata && (mQuirks & requiresAllocateBufferBit)) { // metadata buffers are not connected cross process; only copy if not meta. buffer_meta = new BufferMeta( params, portIndex, !isMetadata /* copy */, NULL /* data */); Loading