Merge "Add some explicit error log messages" into gingerbread
This commit is contained in:
@@ -93,6 +93,9 @@ static int32_t getColorFormat(const char* colorFormat) {
|
|||||||
return OMX_COLOR_Format16bitRGB565;
|
return OMX_COLOR_Format16bitRGB565;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LOGE("Uknown color format (%s), please add it to "
|
||||||
|
"CameraSource::getColorFormat", colorFormat);
|
||||||
|
|
||||||
CHECK_EQ(0, "Unknown color format");
|
CHECK_EQ(0, "Unknown color format");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1675,9 +1675,9 @@ status_t MPEG4Writer::Track::threadEntry() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mSampleSizes.empty()) {
|
if (mSampleSizes.empty() || // no samples written
|
||||||
err = ERROR_MALFORMED;
|
(!mIsAudio && mNumStssTableEntries == 0) || // no sync frames for video
|
||||||
} else if (OK != checkCodecSpecificData()) {
|
(OK != checkCodecSpecificData())) { // no codec specific data
|
||||||
err = ERROR_MALFORMED;
|
err = ERROR_MALFORMED;
|
||||||
}
|
}
|
||||||
mOwner->trackProgressStatus(this, -1, err);
|
mOwner->trackProgressStatus(this, -1, err);
|
||||||
@@ -1794,13 +1794,13 @@ status_t MPEG4Writer::Track::checkCodecSpecificData() const {
|
|||||||
!strcasecmp(MEDIA_MIMETYPE_VIDEO_AVC, mime)) {
|
!strcasecmp(MEDIA_MIMETYPE_VIDEO_AVC, mime)) {
|
||||||
if (!mCodecSpecificData ||
|
if (!mCodecSpecificData ||
|
||||||
mCodecSpecificDataSize <= 0) {
|
mCodecSpecificDataSize <= 0) {
|
||||||
// Missing codec specific data
|
LOGE("Missing codec specific data");
|
||||||
return ERROR_MALFORMED;
|
return ERROR_MALFORMED;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (mCodecSpecificData ||
|
if (mCodecSpecificData ||
|
||||||
mCodecSpecificDataSize > 0) {
|
mCodecSpecificDataSize > 0) {
|
||||||
// Unexepected codec specific data found
|
LOGE("Unexepected codec specific data found");
|
||||||
return ERROR_MALFORMED;
|
return ERROR_MALFORMED;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -811,8 +811,7 @@ status_t OMXCodec::isColorFormatSupported(
|
|||||||
if (OMX_ErrorNone != mOMX->getParameter(
|
if (OMX_ErrorNone != mOMX->getParameter(
|
||||||
mNode, OMX_IndexParamVideoPortFormat,
|
mNode, OMX_IndexParamVideoPortFormat,
|
||||||
&portFormat, sizeof(portFormat))) {
|
&portFormat, sizeof(portFormat))) {
|
||||||
|
break;
|
||||||
return UNKNOWN_ERROR;
|
|
||||||
}
|
}
|
||||||
// Make sure that omx component does not overwrite
|
// Make sure that omx component does not overwrite
|
||||||
// the incremented index (bug 2897413).
|
// the incremented index (bug 2897413).
|
||||||
@@ -832,6 +831,8 @@ status_t OMXCodec::isColorFormatSupported(
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LOGE("color format %d is not supported", colorFormat);
|
||||||
return UNKNOWN_ERROR;
|
return UNKNOWN_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user