for (i = 0; i < ALL_PORT_NUM; i++) {
Exynos_OSAL_SignalTerminate(pExynosComponent->pExynosPort[i].pauseEvent);
pExynosComponent->pExynosPort[i].pauseEvent = NULL;
- if (pExynosComponent->pExynosPort[i].bufferProcessType == BUFFER_SHARE) {
+ if (pExynosComponent->pExynosPort[i].bufferProcessType & BUFFER_SHARE) {
Exynos_OSAL_SignalTerminate(&pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent);
pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent = NULL;
}
for (i = 0; i < ALL_PORT_NUM; i++) {
Exynos_OSAL_SignalTerminate(pExynosComponent->pExynosPort[i].pauseEvent);
pExynosComponent->pExynosPort[i].pauseEvent = NULL;
- if (pExynosComponent->pExynosPort[i].bufferProcessType == BUFFER_SHARE) {
+ if (pExynosComponent->pExynosPort[i].bufferProcessType & BUFFER_SHARE) {
Exynos_OSAL_SignalTerminate(&pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent);
pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent = NULL;
}
} else {
for (i = 0; i < ALL_PORT_NUM; i++) {
Exynos_OSAL_SignalCreate(&pExynosComponent->pExynosPort[i].pauseEvent);
- if (pExynosComponent->pExynosPort[i].bufferProcessType == BUFFER_SHARE)
+ if (pExynosComponent->pExynosPort[i].bufferProcessType & BUFFER_SHARE)
Exynos_OSAL_SignalCreate(&pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent);
}
}
for (i = 0; i < ALL_PORT_NUM; i++) {
Exynos_OSAL_SignalTerminate(pExynosComponent->pExynosPort[i].pauseEvent);
pExynosComponent->pExynosPort[i].pauseEvent = NULL;
- if (pExynosComponent->pExynosPort[i].bufferProcessType == BUFFER_SHARE) {
+ if (pExynosComponent->pExynosPort[i].bufferProcessType & BUFFER_SHARE) {
Exynos_OSAL_SignalTerminate(&pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent);
pExynosComponent->pExynosPort[i].hAllCodecBufferReturnEvent = NULL;
}
FunctionIn();
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
if ((srcInputData->buffer.singlePlaneBuffer.dataBuffer == NULL) ||
(srcInputData->pPrivate == NULL)) {
ret = OMX_FALSE;
}
if (inputUseBuffer->dataValid == OMX_TRUE) {
- if (exynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosInputPort->bufferProcessType & BUFFER_SHARE) {
Exynos_Shared_BufferToData(inputUseBuffer, srcInputData, ONE_PLANE);
if (pVideoDec->bDRMPlayerMode == OMX_TRUE) {
/* reset dataBuffer */
Exynos_ResetDataBuffer(inputUseBuffer);
- } else if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
checkInputStream = inputUseBuffer->bufferHeader->pBuffer + inputUseBuffer->usedDataLen;
checkInputStreamLen = inputUseBuffer->remainDataLen;
FunctionIn();
- if (exynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if (exynosOutputPort->bIsANBEnabled == OMX_FALSE) {
if (Exynos_Shared_DataToBuffer(dstOutputData, outputUseBuffer) == OMX_ErrorNone)
outputUseBuffer->dataValid = OMX_TRUE;
pExynosComponent->checkTimeStamp.needCheckStartTimeStamp = OMX_FALSE;
} else {
Exynos_OSAL_Log(EXYNOS_LOG_TRACE, "drop frame after seeking", pExynosComponent);
- if (exynosOutputPort->bufferProcessType == BUFFER_SHARE)
+ if (exynosOutputPort->bufferProcessType & BUFFER_SHARE)
Exynos_OMX_FillThisBuffer(pOMXComponent, outputUseBuffer->bufferHeader);
ret = OMX_TRUE;
goto EXIT;
goto EXIT;
}
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
OMX_U32 width = 0, height = 0;
int imageSize = 0;
void *pOutputBuf = (void *)outputUseBuffer->bufferHeader->pBuffer;
OMX_EventError, OMX_ErrorUndefined, 0, NULL);
ret = OMX_FALSE;
}
- } else if (exynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (exynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((outputUseBuffer->remainDataLen > 0) ||
((outputUseBuffer->nFlags & OMX_BUFFERFLAG_EOS) == OMX_BUFFERFLAG_EOS) ||
(CHECK_PORT_BEING_FLUSHED(exynosOutputPort)))
Exynos_OSAL_MutexLock(srcInputUseBuffer->bufferMutex);
if (ret != OMX_ErrorInputDataDecodeYet) {
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
if ((pSrcInputData->buffer.singlePlaneBuffer.dataBuffer == NULL) || (pSrcInputData->pPrivate == NULL)) {
Exynos_CodecBufferDeQueue(pExynosComponent, INPUT_PORT_INDEX, &codecBuffer);
Exynos_OSAL_SleepMillisec(0);
while (!pVideoDec->bExitBufferProcessThread) {
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
if (Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX) == OMX_FALSE)
break;
}
ret = pVideoDec->exynos_codec_srcOutputProcess(pOMXComponent, &srcOutputData);
if (ret == OMX_ErrorNone) {
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
codecBuffer = srcOutputData.pPrivate;
if (codecBuffer != NULL)
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, codecBuffer);
}
- if (exynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosInputPort->bufferProcessType & BUFFER_SHARE) {
Exynos_Shared_DataToBuffer(&srcOutputData, srcOutputUseBuffer);
Exynos_InputBufferReturn(pOMXComponent);
}
Exynos_OSAL_MutexLock(dstInputUseBuffer->bufferMutex);
if (ret != OMX_ErrorOutputBufferUseYet) {
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
ret = Exynos_CodecBufferDeQueue(pExynosComponent, OUTPUT_PORT_INDEX, &codecBuffer);
if (ret != OMX_ErrorNone) {
Exynos_Output_CodecBufferToData(pExynosComponent, codecBuffer, &dstInputData);
}
- if (exynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((dstInputUseBuffer->dataValid != OMX_TRUE) &&
(!CHECK_PORT_BEING_FLUSHED(exynosOutputPort))) {
ret = Exynos_OutputBufferGetQueue(pExynosComponent);
break;
Exynos_OSAL_MutexLock(dstOutputUseBuffer->bufferMutex);
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((dstOutputUseBuffer->dataValid != OMX_TRUE) &&
(!CHECK_PORT_BEING_FLUSHED(exynosOutputPort))) {
ret = Exynos_OutputBufferGetQueue(pExynosComponent);
}
if ((dstOutputUseBuffer->dataValid == OMX_TRUE) ||
- (exynosOutputPort->bufferProcessType == BUFFER_SHARE))
+ (exynosOutputPort->bufferProcessType & BUFFER_SHARE))
ret = pVideoDec->exynos_codec_dstOutputProcess(pOMXComponent, pDstOutputData);
if (((ret == OMX_ErrorNone) && (dstOutputUseBuffer->dataValid == OMX_TRUE)) ||
- (exynosOutputPort->bufferProcessType == BUFFER_SHARE)) {
+ (exynosOutputPort->bufferProcessType & BUFFER_SHARE)) {
Exynos_Postprocess_OutputData(pOMXComponent, pDstOutputData);
}
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
codecBuffer = pDstOutputData->pPrivate;
if (codecBuffer != NULL) {
if ((pVideoDec->bDRMPlayerMode == OMX_TRUE) && (nPortIndex == INPUT_PORT_INDEX)) {
mem_type = SECURE_MEMORY;
- } else if (pExynosPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
mem_type = NORMAL_MEMORY;
} else {
mem_type = SYSTEM_MEMORY;
}
if (pExynosComponent->bMultiThreadProcess == OMX_TRUE) {
- if (pExynosPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
if (pExynosPort->processData.bufferHeader != NULL) {
if (portIndex == INPUT_PORT_INDEX) {
Exynos_OMX_InputBufferReturn(pOMXComponent, pExynosPort->processData.bufferHeader);
pExynosPort = &pExynosComponent->pExynosPort[nPortIndex];
Exynos_OMX_GetFlushBuffer(pExynosPort, flushPortBuffer);
- if ((pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY) == BUFFER_COPY)
+ if (pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY)
Exynos_OSAL_SemaphorePost(pExynosPort->codecSemID);
Exynos_OSAL_SemaphorePost(pExynosPort->bufferSemID);
pVideoDec->exynos_codec_stop(pOMXComponent, nPortIndex);
Exynos_OSAL_MutexLock(flushPortBuffer[1]->bufferMutex);
ret = Exynos_OMX_FlushPort(pOMXComponent, nPortIndex);
- if ((pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY) == BUFFER_COPY)
+ if (pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY)
pVideoDec->exynos_codec_enqueueAllBuffer(pOMXComponent, nPortIndex);
Exynos_ResetCodecData(&pExynosPort->processData);
FunctionIn();
- if ((exynosOMXInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOMXInputPort->bufferProcessType & BUFFER_COPY) {
dataBuffer = &(exynosOMXInputPort->way.port2WayDataBuffer.inputDataBuffer);
- } else if (exynosOMXInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (exynosOMXInputPort->bufferProcessType & BUFFER_SHARE) {
dataBuffer = &(exynosOMXInputPort->way.port2WayDataBuffer.outputDataBuffer);
}
FunctionIn();
- if ((pExynosPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosPort->bufferProcessType & BUFFER_COPY) {
outputUseBuffer = &(pExynosPort->way.port2WayDataBuffer.outputDataBuffer);
- } else if (pExynosPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
outputUseBuffer = &(pExynosPort->way.port2WayDataBuffer.inputDataBuffer);
}
/* dataBuffer->nFlags = dataBuffer->bufferHeader->nFlags; */
/* dataBuffer->nTimeStamp = dataBuffer->bufferHeader->nTimeStamp; */
/*
- if (pExynosPort->bufferProcessType == BUFFER_SHARE)
+ if (pExynosPort->bufferProcessType & BUFFER_SHARE)
outputUseBuffer->pPrivate = outputUseBuffer->bufferHeader->pOutputPortPrivate;
- else if ((pExynosPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ else if (pExynosPort->bufferProcessType & BUFFER_COPY) {
pExynosPort->processData.dataBuffer = outputUseBuffer->bufferHeader->pBuffer;
pExynosPort->processData.allocSize = outputUseBuffer->bufferHeader->nAllocLen;
}
break;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
pExynosOutputPort->portDefinition.nBufferSize =
calc_plane(pExynosPort->portDefinition.format.video.nFrameWidth, pExynosOutputPort->portDefinition.format.video.nFrameHeight) +
calc_plane(pExynosPort->portDefinition.format.video.nFrameWidth, pExynosOutputPort->portDefinition.format.video.nFrameHeight >> 1);
Exynos_OSAL_Memset(&bufferConf, 0, sizeof(bufferConf));
bufferConf.eCompressionFormat = VIDEO_CODING_AVC;
pInbufOps->Set_Shareable(hMFCHandle);
- if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
bufferConf.nSizeImage = pExynosInputPort->portDefinition.format.video.nFrameWidth
* pExynosInputPort->portDefinition.format.video.nFrameHeight * 3 / 2;
inputBufferNumber = MAX_VIDEO_INPUTBUFFER_NUM;
- } else if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
bufferConf.nSizeImage = DEFAULT_MFC_INPUT_BUFFER_SIZE;
inputBufferNumber = MFC_INPUT_BUFFER_NUM_MAX;
}
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
ExynosVideoPlane plane;
goto EXIT;
}
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/* Register input buffer */
for (i = 0; i < pExynosInputPort->portDefinition.nBufferCountActual; i++) {
ExynosVideoPlane plane;
pExynosOutputPort->cropRectangle.nWidth = pH264Dec->hMFCH264Handle.codecOutbufConf.cropRect.nWidth;
pExynosOutputPort->cropRectangle.nHeight = pH264Dec->hMFCH264Handle.codecOutbufConf.cropRect.nHeight;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameHeight)) {
pExynosInputPort->portDefinition.format.video.nFrameWidth = pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameWidth;
0,
NULL);
}
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameHeight) ||
(pExynosOutputPort->portDefinition.nBufferCountActual != pH264Dec->hMFCH264Handle.maxDPBNum)) {
/* get dpb count */
nOutbufs = pH264Dec->hMFCH264Handle.maxDPBNum;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* should be done before prepare output buffer */
if (pOutbufOps->Enable_Cacheable(hMFCHandle) != VIDEO_ERROR_NONE) {
ret = OMX_ErrorInsufficientResources;
nAllocLen[1] = calc_plane(pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameWidth,
pH264Dec->hMFCH264Handle.codecOutbufConf.nFrameHeight >> 1);
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
MEMORY_TYPE memoryType;
if (pVideoDec->bDRMPlayerMode == OMX_TRUE)
memoryType = SECURE_MEMORY;
pOutbufOps->Enqueue(hMFCHandle, (unsigned char **)pVideoDec->pMFCDecOutputBuffer[i]->pVirAddr,
(unsigned int *)dataLen, MFC_OUTPUT_BUFFER_PLANE, NULL);
}
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/* Register output buffer */
/*************/
/* TBD */
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
H264CodecStop(pOMXComponent, OUTPUT_PORT_INDEX);
}
pH264Dec->hMFCH264Handle.bConfiguredMFCDst = OMX_TRUE;
pInbufOps = pH264Dec->hMFCH264Handle.pInbufOps;
pOutbufOps = pH264Dec->hMFCH264Handle.pOutbufOps;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosInputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosInputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, pVideoDec->pMFCDecInputBuffer[i]);
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosOutputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosOutputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pH264Dec->hSourceStartEvent = NULL;
pH264Dec->bSourceStart = OMX_FALSE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecOutputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_OUTPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosOutputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosOutputPort->codecSemID);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecInputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosInputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosInputPort->codecSemID);
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pSrcOutputData->buffer.singlePlaneBuffer.fd = pVideoBuffer->planes[0].fd;
pSrcOutputData->allocSize = pVideoBuffer->planes[0].allocSize;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
int i = 0;
while (pSrcOutputData->buffer.singlePlaneBuffer.dataBuffer != pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[0]) {
if (i >= MFC_INPUT_BUFFER_NUM_MAX) {
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
if (OMX_FALSE == Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX)) {
ret = OMX_ErrorNone;
goto EXIT;
ret = OMX_ErrorNone;
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pH264Dec->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pH264Dec->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
goto EXIT;
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pH264Dec->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pH264Dec->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
bufferConf.eCompressionFormat = VIDEO_CODING_H263;
pInbufOps->Set_Shareable(hMFCHandle);
- if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
bufferConf.nSizeImage = pExynosInputPort->portDefinition.format.video.nFrameWidth
* pExynosInputPort->portDefinition.format.video.nFrameHeight * 3 / 2;
inputBufferNumber = MAX_VIDEO_INPUTBUFFER_NUM;
- } else if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
bufferConf.nSizeImage = DEFAULT_MFC_INPUT_BUFFER_SIZE;
inputBufferNumber = MFC_INPUT_BUFFER_NUM_MAX;
}
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
ExynosVideoPlane plane;
goto EXIT;
}
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/* Register input buffer */
for (i = 0; i < pExynosInputPort->portDefinition.nBufferCountActual; i++) {
ExynosVideoPlane plane;
pMpeg4Dec->hMFCMpeg4Handle.bConfiguredMFCSrc = OMX_TRUE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameHeight)) {
pExynosInputPort->portDefinition.format.video.nFrameWidth = pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameWidth;
0,
NULL);
}
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameHeight) ||
(pExynosOutputPort->portDefinition.nBufferCountActual != pMpeg4Dec->hMFCMpeg4Handle.maxDPBNum)) {
/* get dpb count */
nOutbufs = pMpeg4Dec->hMFCMpeg4Handle.maxDPBNum;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* should be done before prepare output buffer */
if (pOutbufOps->Enable_Cacheable(hMFCHandle) != VIDEO_ERROR_NONE) {
ret = OMX_ErrorInsufficientResources;
nAllocLen[1] = calc_plane(pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameWidth,
pMpeg4Dec->hMFCMpeg4Handle.codecOutbufConf.nFrameHeight >> 1);
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* Register output buffer */
for (i = 0; i < nOutbufs; i++) {
pVideoDec->pMFCDecOutputBuffer[i] = (CODEC_DEC_BUFFER *)Exynos_OSAL_Malloc(sizeof(CODEC_DEC_BUFFER));
pOutbufOps->Enqueue(hMFCHandle, (unsigned char **)pVideoDec->pMFCDecOutputBuffer[i]->pVirAddr,
(unsigned int *)dataLen, MFC_OUTPUT_BUFFER_PLANE, NULL);
}
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/* Register output buffer */
/*************/
/* TBD */
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
Mpeg4CodecStop(pOMXComponent, OUTPUT_PORT_INDEX);
}
pMpeg4Dec->hMFCMpeg4Handle.bConfiguredMFCDst = OMX_TRUE;
pInbufOps = pMpeg4Dec->hMFCMpeg4Handle.pInbufOps;
pOutbufOps = pMpeg4Dec->hMFCMpeg4Handle.pOutbufOps;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosInputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosInputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, pVideoDec->pMFCDecInputBuffer[i]);
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosOutputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosOutputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pMpeg4Dec->hSourceStartEvent = NULL;
pMpeg4Dec->bSourceStart = OMX_FALSE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecOutputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_OUTPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosOutputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosOutputPort->codecSemID);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecInputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosInputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosInputPort->codecSemID);
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pSrcOutputData->buffer.singlePlaneBuffer.fd = pVideoBuffer->planes[0].fd;
pSrcOutputData->allocSize = pVideoBuffer->planes[0].allocSize;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
int i = 0;
while (pSrcOutputData->buffer.singlePlaneBuffer.dataBuffer != pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[0]) {
if (i >= MFC_INPUT_BUFFER_NUM_MAX) {
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
if (OMX_FALSE == Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX)) {
ret = OMX_ErrorNone;
goto EXIT;
ret = OMX_ErrorNone;
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pMpeg4Dec->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pMpeg4Dec->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
goto EXIT;
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pMpeg4Dec->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pMpeg4Dec->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
Exynos_OSAL_Memset(&bufferConf, 0, sizeof(bufferConf));
bufferConf.eCompressionFormat = VIDEO_CODING_VP8;
pInbufOps->Set_Shareable(hMFCHandle);
- if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
bufferConf.nSizeImage = pExynosInputPort->portDefinition.format.video.nFrameWidth
* pExynosInputPort->portDefinition.format.video.nFrameHeight * 3 / 2;
inputBufferNumber = MAX_VIDEO_INPUTBUFFER_NUM;
- } else if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
bufferConf.nSizeImage = DEFAULT_MFC_INPUT_BUFFER_SIZE;
inputBufferNumber = MFC_INPUT_BUFFER_NUM_MAX;
}
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
ExynosVideoPlane plane;
goto EXIT;
}
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/* Register input buffer */
for (i = 0; i < pExynosInputPort->portDefinition.nBufferCountActual; i++) {
ExynosVideoPlane plane;
pVp8Dec->hMFCVp8Handle.bConfiguredMFCSrc = OMX_TRUE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameHeight)) {
pExynosInputPort->portDefinition.format.video.nFrameWidth = pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameWidth;
0,
NULL);
}
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pExynosInputPort->portDefinition.format.video.nFrameWidth != pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameWidth) ||
(pExynosInputPort->portDefinition.format.video.nFrameHeight != pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameHeight) ||
(pExynosOutputPort->portDefinition.nBufferCountActual != pVp8Dec->hMFCVp8Handle.maxDPBNum)) {
/* get dpb count */
nOutbufs = pVp8Dec->hMFCVp8Handle.maxDPBNum;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* should be done before prepare output buffer */
if (pOutbufOps->Enable_Cacheable(hMFCHandle) != VIDEO_ERROR_NONE) {
ret = OMX_ErrorInsufficientResources;
nAllocLen[1] = calc_plane(pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameWidth,
pVp8Dec->hMFCVp8Handle.codecOutbufConf.nFrameHeight >> 1);
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* Register output buffer */
for (i = 0; i < nOutbufs; i++) {
pVideoDec->pMFCDecOutputBuffer[i] = (CODEC_DEC_BUFFER *)Exynos_OSAL_Malloc(sizeof(CODEC_DEC_BUFFER));
pOutbufOps->Enqueue(hMFCHandle, (unsigned char **)pVideoDec->pMFCDecOutputBuffer[i]->pVirAddr,
(unsigned int *)dataLen, MFC_OUTPUT_BUFFER_PLANE, NULL);
}
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/* Register output buffer */
/*************/
/* TBD */
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
VP8CodecStop (pOMXComponent, OUTPUT_PORT_INDEX);
}
pVp8Dec->hMFCVp8Handle.bConfiguredMFCDst = OMX_TRUE;
pInbufOps = pVp8Dec->hMFCVp8Handle.pInbufOps;
pOutbufOps = pVp8Dec->hMFCVp8Handle.pOutbufOps;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosInputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosInputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, pVideoDec->pMFCDecInputBuffer[i]);
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosOutputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosOutputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pVp8Dec->hSourceStartEvent = NULL;
pVp8Dec->bSourceStart = OMX_FALSE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecOutputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_OUTPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosOutputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosOutputPort->codecSemID);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
if (pVideoDec->pMFCDecInputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosInputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosInputPort->codecSemID);
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pSrcOutputData->buffer.singlePlaneBuffer.fd = pVideoBuffer->planes[0].fd;
pSrcOutputData->allocSize = pVideoBuffer->planes[0].allocSize;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
int i = 0;
while (pSrcOutputData->buffer.singlePlaneBuffer.dataBuffer != pVideoDec->pMFCDecInputBuffer[i]->pVirAddr[0]) {
if (i >= MFC_INPUT_BUFFER_NUM_MAX) {
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
if (OMX_FALSE == Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX)) {
ret = OMX_ErrorNone;
goto EXIT;
ret = OMX_ErrorNone;
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pVp8Dec->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pVp8Dec->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
goto EXIT;
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pVp8Dec->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pVp8Dec->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
FunctionIn();
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
if ((srcInputData->buffer.multiPlaneBuffer.dataBuffer[0] == NULL) ||
(srcInputData->pPrivate == NULL)) {
ret = OMX_FALSE;
}
if (inputUseBuffer->dataValid == OMX_TRUE) {
- if (exynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosInputPort->bufferProcessType & BUFFER_SHARE) {
Exynos_Shared_BufferToData(inputUseBuffer, srcInputData, ONE_PLANE);
#ifdef USE_METADATABUFFERTYPE
if (exynosInputPort->bStoreMetaData == OMX_TRUE) {
#endif
/* reset dataBuffer */
Exynos_ResetDataBuffer(inputUseBuffer);
- } else if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
checkInputStream = inputUseBuffer->bufferHeader->pBuffer + inputUseBuffer->usedDataLen;
checkInputStreamLen = inputUseBuffer->remainDataLen;
FunctionIn();
- if (exynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if (Exynos_Shared_DataToBuffer(dstOutputData, outputUseBuffer) == OMX_ErrorNone)
outputUseBuffer->dataValid = OMX_TRUE;
}
goto EXIT;
}
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
if (dstOutputData->remainDataLen <= (outputUseBuffer->allocSize - outputUseBuffer->dataLen)) {
copySize = dstOutputData->remainDataLen;
if (copySize > 0)
OMX_EventError, OMX_ErrorUndefined, 0, NULL);
ret = OMX_FALSE;
}
- } else if (exynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (exynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((outputUseBuffer->remainDataLen > 0) ||
((outputUseBuffer->nFlags & OMX_BUFFERFLAG_EOS) == OMX_BUFFERFLAG_EOS) ||
(CHECK_PORT_BEING_FLUSHED(exynosOutputPort)))
Exynos_OSAL_MutexLock(srcInputUseBuffer->bufferMutex);
if (pVideoEnc->bFirstInput == OMX_FALSE) {
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
if ((pSrcInputData->buffer.multiPlaneBuffer.dataBuffer[0] == NULL) || (pSrcInputData->pPrivate == NULL)) {
Exynos_CodecBufferDeQueue(pExynosComponent, INPUT_PORT_INDEX, &codecBuffer);
Exynos_OSAL_SleepMillisec(0);
while (!pVideoEnc->bExitBufferProcessThread) {
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
if (Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX) == OMX_FALSE)
break;
}
ret = pVideoEnc->exynos_codec_srcOutputProcess(pOMXComponent, &srcOutputData);
if (ret == OMX_ErrorNone) {
- if ((exynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosInputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
codecBuffer = srcOutputData.pPrivate;
if (codecBuffer != NULL)
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, codecBuffer);
}
- if (exynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosInputPort->bufferProcessType & BUFFER_SHARE) {
Exynos_Shared_DataToBuffer(&srcOutputData, srcOutputUseBuffer);
Exynos_InputBufferReturn(pOMXComponent);
}
break;
Exynos_OSAL_MutexLock(dstInputUseBuffer->bufferMutex);
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
ret = Exynos_CodecBufferDeQueue(pExynosComponent, OUTPUT_PORT_INDEX, &codecBuffer);
if (ret != OMX_ErrorNone) {
Exynos_Output_CodecBufferToData(pExynosComponent, codecBuffer, &dstInputData);
}
- if (exynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((dstInputUseBuffer->dataValid != OMX_TRUE) &&
(!CHECK_PORT_BEING_FLUSHED(exynosOutputPort))) {
ret = Exynos_OutputBufferGetQueue(pExynosComponent);
break;
Exynos_OSAL_MutexLock(dstOutputUseBuffer->bufferMutex);
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((dstOutputUseBuffer->dataValid != OMX_TRUE) &&
(!CHECK_PORT_BEING_FLUSHED(exynosOutputPort))) {
ret = Exynos_OutputBufferGetQueue(pExynosComponent);
}
if ((dstOutputUseBuffer->dataValid == OMX_TRUE) ||
- (exynosOutputPort->bufferProcessType == BUFFER_SHARE))
+ (exynosOutputPort->bufferProcessType & BUFFER_SHARE))
ret = pVideoEnc->exynos_codec_dstOutputProcess(pOMXComponent, pDstOutputData);
if (((ret == OMX_ErrorNone) && (dstOutputUseBuffer->dataValid == OMX_TRUE)) ||
- (exynosOutputPort->bufferProcessType == BUFFER_SHARE)) {
+ (exynosOutputPort->bufferProcessType & BUFFER_SHARE)) {
Exynos_Postprocess_OutputData(pOMXComponent, pDstOutputData);
}
- if ((exynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (exynosOutputPort->bufferProcessType & BUFFER_COPY) {
OMX_PTR codecBuffer;
codecBuffer = pDstOutputData->pPrivate;
if (codecBuffer != NULL) {
goto EXIT;
}
- if (pExynosPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
mem_type = NORMAL_MEMORY;
} else {
mem_type = SYSTEM_MEMORY;
}
if (pExynosComponent->bMultiThreadProcess == OMX_TRUE) {
- if (pExynosPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
if (pExynosPort->processData.bufferHeader != NULL) {
if (portIndex == INPUT_PORT_INDEX) {
Exynos_OMX_InputBufferReturn(pOMXComponent, pExynosPort->processData.bufferHeader);
pExynosPort = &pExynosComponent->pExynosPort[nPortIndex];
Exynos_OMX_GetFlushBuffer(pExynosPort, flushPortBuffer);
- if ((pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY) == BUFFER_COPY)
+ if (pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY)
Exynos_OSAL_SemaphorePost(pExynosPort->codecSemID);
Exynos_OSAL_SemaphorePost(pExynosPort->bufferSemID);
pVideoEnc->exynos_codec_stop(pOMXComponent, nPortIndex);
Exynos_OSAL_MutexLock(flushPortBuffer[1]->bufferMutex);
ret = Exynos_OMX_FlushPort(pOMXComponent, nPortIndex);
- if ((pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY) == BUFFER_COPY)
+ if (pExynosComponent->pExynosPort[nPortIndex].bufferProcessType & BUFFER_COPY)
pVideoEnc->exynos_codec_enqueueAllBuffer(pOMXComponent, nPortIndex);
Exynos_ResetCodecData(&pExynosPort->processData);
FunctionIn();
- if ((exynosOMXInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosPort->bufferProcessType & BUFFER_COPY) {
dataBuffer = &(exynosOMXInputPort->way.port2WayDataBuffer.inputDataBuffer);
- } else if (exynosOMXInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
dataBuffer = &(exynosOMXInputPort->way.port2WayDataBuffer.outputDataBuffer);
}
FunctionIn();
- if ((pExynosPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosPort->bufferProcessType & BUFFER_COPY) {
outputUseBuffer = &(pExynosPort->way.port2WayDataBuffer.outputDataBuffer);
- } else if (pExynosPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosPort->bufferProcessType & BUFFER_SHARE) {
outputUseBuffer = &(pExynosPort->way.port2WayDataBuffer.inputDataBuffer);
}
/* dataBuffer->nFlags = dataBuffer->bufferHeader->nFlags; */
/* dataBuffer->nTimeStamp = dataBuffer->bufferHeader->nTimeStamp; */
/*
- if (pExynosPort->bufferProcessType == BUFFER_SHARE)
+ if (pExynosPort->bufferProcessType & BUFFER_SHARE)
outputUseBuffer->pPrivate = outputUseBuffer->bufferHeader->pOutputPortPrivate;
- else if ((pExynosPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ else if (pExynosPort->bufferProcessType & BUFFER_COPY) {
pExynosPort->processData.dataBuffer = outputUseBuffer->bufferHeader->pBuffer;
pExynosPort->processData.allocSize = outputUseBuffer->bufferHeader->nAllocLen;
}
bufferConf.nFrameWidth = pExynosInputPort->portDefinition.format.video.nFrameWidth;
bufferConf.nFrameHeight = pExynosInputPort->portDefinition.format.video.nFrameHeight;
pInbufOps->Set_Shareable(hMFCHandle);
- if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
inputBufferNumber = MAX_INPUTBUFFER_NUM_DYNAMIC;
- } else if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
inputBufferNumber = MFC_INPUT_BUFFER_NUM_MAX;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* should be done before prepare input buffer */
if (pInbufOps->Enable_Cacheable(hMFCHandle) != VIDEO_ERROR_NONE) {
ret = OMX_ErrorInsufficientResources;
ExynosVideoPlane planes[MFC_INPUT_BUFFER_PLANE];
int plane;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
goto EXIT;
}
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
if (pExynosInputPort->bStoreMetaData == OMX_TRUE) {
/*************/
/* TBD */
pOutbufOps->Set_Shareable(hMFCHandle);
int SetupBufferNumber = 0;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY)
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY)
SetupBufferNumber = MFC_OUTPUT_BUFFER_NUM_MAX;
else
SetupBufferNumber = pExynosOutputPort->portDefinition.nBufferCountActual;
}
OMX_U32 dataLen[MFC_OUTPUT_BUFFER_PLANE] = {0};
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
ExynosVideoPlane plane;
pOutbufOps->Enqueue(hMFCHandle, (unsigned char **)pVideoEnc->pMFCEncOutputBuffer[i]->pVirAddr,
(unsigned int *)dataLen, MFC_OUTPUT_BUFFER_PLANE, NULL);
}
- } else if ((pExynosOutputPort->bufferProcessType & BUFFER_SHARE) == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/* Register input buffer */
/*************/
/* TBD */
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
OMX_BUFFERHEADERTYPE *OMXBuffer = NULL;
ExynosVideoBuffer *pVideoBuffer = NULL;
if ((pExynosInputPort->bStoreMetaData != OMX_TRUE) &&
(eColorFormat != OMX_COLOR_FormatAndroidOpaque)) {
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosInputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosInputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, pVideoEnc->pMFCEncInputBuffer[i]);
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
}
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosOutputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosOutputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pH264Enc->hSourceStartEvent = NULL;
pH264Enc->bSourceStart = OMX_FALSE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
if (pVideoEnc->pMFCEncOutputBuffer[i] != NULL) {
if (pVideoEnc->pMFCEncOutputBuffer[i]->pVirAddr[0] != NULL)
Exynos_OSAL_QueueTerminate(&pExynosOutputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosOutputPort->codecSemID);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
if (pVideoEnc->pMFCEncInputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosInputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosInputPort->codecSemID);
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
nAllocLen[1] = ALIGN(nAllocLen[0]/2,256);
if ((pExynosInputPort->bStoreMetaData == OMX_TRUE) &&
- (pExynosInputPort->bufferProcessType == BUFFER_SHARE)) {
+ (pExynosInputPort->bufferProcessType & BUFFER_SHARE)) {
codecReturn = pInbufOps->ExtensionEnqueue(hMFCHandle,
(unsigned char **)pSrcInputData->buffer.multiPlaneBuffer.dataBuffer,
(unsigned char **)pSrcInputData->buffer.multiPlaneBuffer.fd,
pVideoBuffer->planes[1].allocSize +
pVideoBuffer->planes[2].allocSize;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
int i = 0;
while (pSrcOutputData->buffer.multiPlaneBuffer.dataBuffer[0] != pVideoEnc->pMFCEncInputBuffer[i]->pVirAddr[0]) {
if (i >= MFC_INPUT_BUFFER_NUM_MAX) {
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
if (OMX_FALSE == Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX)) {
ret = OMX_ErrorNone;
goto EXIT;
ret = OMX_ErrorNone;
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pH264Enc->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pH264Enc->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
goto EXIT;
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pH264Enc->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pH264Enc->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
bufferConf.nFrameWidth = pExynosInputPort->portDefinition.format.video.nFrameWidth;
bufferConf.nFrameHeight = pExynosInputPort->portDefinition.format.video.nFrameHeight;
pInbufOps->Set_Shareable(hMFCHandle);
- if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
inputBufferNumber = MAX_INPUTBUFFER_NUM_DYNAMIC;
- } else if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
inputBufferNumber = MFC_INPUT_BUFFER_NUM_MAX;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* should be done before prepare input buffer */
if (pInbufOps->Enable_Cacheable(hMFCHandle) != VIDEO_ERROR_NONE) {
ret = OMX_ErrorInsufficientResources;
ExynosVideoPlane planes[MFC_INPUT_BUFFER_PLANE];
int plane;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
goto EXIT;
}
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
if (pExynosInputPort->bStoreMetaData == OMX_TRUE) {
/*************/
/* TBD */
pOutbufOps->Set_Shareable(hMFCHandle);
}
int SetupBufferNumber = 0;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY)
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY)
SetupBufferNumber = MFC_OUTPUT_BUFFER_NUM_MAX;
else
SetupBufferNumber = pExynosOutputPort->portDefinition.nBufferCountActual;
}
OMX_U32 dataLen[MFC_OUTPUT_BUFFER_PLANE] = {0};
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
/* Register input buffer */
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
ExynosVideoPlane plane;
pOutbufOps->Enqueue(hMFCHandle, (unsigned char **)pVideoEnc->pMFCEncOutputBuffer[i]->pVirAddr,
(unsigned int *)dataLen, MFC_OUTPUT_BUFFER_PLANE, NULL);
}
- } else if ((pExynosOutputPort->bufferProcessType & BUFFER_SHARE) == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/* Register input buffer */
/*************/
/* TBD */
}
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
OMX_BUFFERHEADERTYPE *OMXBuffer = NULL;
ExynosVideoBuffer *pVideoBuffer = NULL;
if ((pExynosInputPort->bStoreMetaData != OMX_TRUE) &&
(eColorFormat != OMX_COLOR_FormatAndroidOpaque)) {
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosInputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosInputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
Exynos_CodecBufferEnQueue(pExynosComponent, INPUT_PORT_INDEX, pVideoEnc->pMFCEncInputBuffer[i]);
}
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
}
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
Exynos_OSAL_SemaphoreCreate(&pExynosOutputPort->codecSemID);
Exynos_OSAL_QueueCreate(&pExynosOutputPort->codecBufferQ, MAX_QUEUE_ELEMENTS);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
pMpeg4Enc->hSourceStartEvent = NULL;
pMpeg4Enc->bSourceStart = OMX_FALSE;
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
if (pVideoEnc->pMFCEncOutputBuffer[i] != NULL) {
if (pVideoEnc->pMFCEncOutputBuffer[i]->pVirAddr[0] != NULL)
Exynos_OSAL_QueueTerminate(&pExynosOutputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosOutputPort->codecSemID);
- } else if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
/* Does not require any actions. */
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
for (i = 0; i < MFC_INPUT_BUFFER_NUM_MAX; i++) {
if (pVideoEnc->pMFCEncInputBuffer[i] != NULL) {
for (plane = 0; plane < MFC_INPUT_BUFFER_PLANE; plane++) {
Exynos_OSAL_QueueTerminate(&pExynosInputPort->codecBufferQ);
Exynos_OSAL_SemaphoreTerminate(pExynosInputPort->codecSemID);
- } else if (pExynosInputPort->bufferProcessType == BUFFER_SHARE) {
+ } else if (pExynosInputPort->bufferProcessType & BUFFER_SHARE) {
/*************/
/* TBD */
/*************/
nAllocLen[1] = ALIGN(nAllocLen[0]/2,256);
if ((pExynosInputPort->bStoreMetaData == OMX_TRUE) &&
- (pExynosInputPort->bufferProcessType == BUFFER_SHARE)) {
+ (pExynosInputPort->bufferProcessType & BUFFER_SHARE)) {
codecReturn = pInbufOps->ExtensionEnqueue(hMFCHandle,
(unsigned char **)pSrcInputData->buffer.multiPlaneBuffer.dataBuffer,
(unsigned char **)pSrcInputData->buffer.multiPlaneBuffer.fd,
pVideoBuffer->planes[1].allocSize +
pVideoBuffer->planes[2].allocSize;
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
int i = 0;
while (pSrcOutputData->buffer.multiPlaneBuffer.dataBuffer[0] != pVideoEnc->pMFCEncInputBuffer[i]->pVirAddr[0]) {
if (i >= MFC_INPUT_BUFFER_NUM_MAX) {
goto EXIT;
}
- if ((pExynosInputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosInputPort->bufferProcessType & BUFFER_COPY) {
if (OMX_FALSE == Exynos_Check_BufferProcess_State(pExynosComponent, INPUT_PORT_INDEX)) {
ret = OMX_ErrorNone;
goto EXIT;
ret = OMX_ErrorNone;
goto EXIT;
}
- if (pExynosOutputPort->bufferProcessType == BUFFER_SHARE) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_SHARE) {
if ((pMpeg4Enc->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pMpeg4Enc->hDestinationStartEvent, DEF_MAX_WAIT_TIME);
goto EXIT;
}
- if ((pExynosOutputPort->bufferProcessType & BUFFER_COPY) == BUFFER_COPY) {
+ if (pExynosOutputPort->bufferProcessType & BUFFER_COPY) {
if ((pMpeg4Enc->bDestinationStart == OMX_FALSE) &&
(!CHECK_PORT_BEING_FLUSHED(pExynosOutputPort))) {
Exynos_OSAL_SignalWait(pMpeg4Enc->hDestinationStartEvent, DEF_MAX_WAIT_TIME);