diff options
-rw-r--r-- | libcamera/SecCamera.cpp | 10 | ||||
-rw-r--r-- | sec_mm/sec_omx/sec_omx_component/video/enc/SEC_OMX_Venc.c | 14 | ||||
-rw-r--r-- | sec_mm/sec_omx/sec_omx_component/video/enc/h264enc/SEC_OMX_H264enc.c | 5 |
3 files changed, 25 insertions, 4 deletions
diff --git a/libcamera/SecCamera.cpp b/libcamera/SecCamera.cpp index 55baef7..28cd65a 100644 --- a/libcamera/SecCamera.cpp +++ b/libcamera/SecCamera.cpp @@ -3281,9 +3281,15 @@ void SecCamera::setExifFixedAttribute() //2 0th IFD TIFF Tags //3 Maker - strcpy((char *)mExifInfo.maker, EXIF_DEF_MAKER); + property_get("ro.product.brand", property, EXIF_DEF_MAKER); + strncpy((char *)mExifInfo.maker, property, + sizeof(mExifInfo.maker) - 1); + mExifInfo.maker[sizeof(mExifInfo.maker) - 1] = '\0'; //3 Model - strcpy((char *)mExifInfo.model, EXIF_DEF_MODEL); + property_get("ro.product.model", property, EXIF_DEF_MODEL); + strncpy((char *)mExifInfo.model, property, + sizeof(mExifInfo.model) - 1); + mExifInfo.model[sizeof(mExifInfo.model) - 1] = '\0'; //3 Software property_get("ro.build.id", property, EXIF_DEF_SOFTWARE); strncpy((char *)mExifInfo.software, property, diff --git a/sec_mm/sec_omx/sec_omx_component/video/enc/SEC_OMX_Venc.c b/sec_mm/sec_omx/sec_omx_component/video/enc/SEC_OMX_Venc.c index a6e1a18..c1bd4ef 100644 --- a/sec_mm/sec_omx/sec_omx_component/video/enc/SEC_OMX_Venc.c +++ b/sec_mm/sec_omx/sec_omx_component/video/enc/SEC_OMX_Venc.c @@ -794,10 +794,14 @@ OMX_BOOL SEC_Preprocessor_InputData(OMX_COMPONENTTYPE *pOMXComponent) flagEOF = OMX_FALSE; } - if (inputUseBuffer->remainDataLen == 0) + if (inputUseBuffer->remainDataLen == 0) { +#ifdef S5PC110_ENCODE_IN_DATA_BUFFER + if(flagEOF == OMX_FALSE) +#endif SEC_InputBufferReturn(pOMXComponent); - else + } else { inputUseBuffer->dataValid = OMX_TRUE; + } } if (flagEOF == OMX_TRUE) { @@ -965,6 +969,12 @@ OMX_ERRORTYPE SEC_OMX_BufferProcess(OMX_HANDLETYPE hComponent) SEC_OSAL_MutexLock(inputUseBuffer->bufferMutex); SEC_OSAL_MutexLock(outputUseBuffer->bufferMutex); ret = pSECComponent->sec_mfc_bufferProcess(pOMXComponent, inputData, outputData); +#ifdef S5PC110_ENCODE_IN_DATA_BUFFER + if (inputUseBuffer->remainDataLen == 0) + SEC_InputBufferReturn(pOMXComponent); + else + inputUseBuffer->dataValid = OMX_TRUE; +#endif SEC_OSAL_MutexUnlock(outputUseBuffer->bufferMutex); SEC_OSAL_MutexUnlock(inputUseBuffer->bufferMutex); diff --git a/sec_mm/sec_omx/sec_omx_component/video/enc/h264enc/SEC_OMX_H264enc.c b/sec_mm/sec_omx/sec_omx_component/video/enc/h264enc/SEC_OMX_H264enc.c index a118b90..53c025c 100644 --- a/sec_mm/sec_omx/sec_omx_component/video/enc/h264enc/SEC_OMX_H264enc.c +++ b/sec_mm/sec_omx/sec_omx_component/video/enc/h264enc/SEC_OMX_H264enc.c @@ -735,6 +735,11 @@ OMX_ERRORTYPE SEC_MFC_H264_Encode(OMX_COMPONENTTYPE *pOMXComponent, SEC_OMX_DATA goto EXIT; } + if ((pInputData->nFlags & OMX_BUFFERFLAG_ENDOFFRAME) && + (pSECComponent->bUseFlagEOF == OMX_FALSE)) { + pSECComponent->bUseFlagEOF = OMX_TRUE; + } + pSECComponent->timeStamp[pH264Enc->hMFCH264Handle.indexTimestamp] = pInputData->timeStamp; pSECComponent->nFlags[pH264Enc->hMFCH264Handle.indexTimestamp] = pInputData->nFlags; SsbSipMfcEncSetConfig(pH264Enc->hMFCH264Handle.hMFCHandle, MFC_ENC_SETCONF_FRAME_TAG, &(pH264Enc->hMFCH264Handle.indexTimestamp)); |