Loading media/libstagefright/rtsp/APacketSource.cpp +13 −8 Original line number Diff line number Diff line Loading @@ -110,13 +110,11 @@ static sp<ABuffer> MakeAVCCodecSpecificData( *height = 0; AString val; if (!GetAttribute(params, "profile-level-id", &val)) { return NULL; } sp<ABuffer> profileLevelID = decodeHex(val); CHECK(profileLevelID != NULL); sp<ABuffer> profileLevelID = NULL; if (GetAttribute(params, "profile-level-id", &val)) { profileLevelID = decodeHex(val); CHECK_EQ(profileLevelID->size(), 3u); } Vector<sp<ABuffer> > paramSets; Loading Loading @@ -176,8 +174,15 @@ static sp<ABuffer> MakeAVCCodecSpecificData( uint8_t *out = csd->data(); *out++ = 0x01; // configurationVersion if (profileLevelID != NULL) { memcpy(out, profileLevelID->data(), 3); out += 3; } else { *out++ = 0x42; // Baseline profile *out++ = 0xE0; // Common subset for all profiles *out++ = 0x0A; // Level 1 } *out++ = (0x3f << 2) | 1; // lengthSize == 2 bytes *out++ = 0xe0 | numSeqParameterSets; Loading Loading
media/libstagefright/rtsp/APacketSource.cpp +13 −8 Original line number Diff line number Diff line Loading @@ -110,13 +110,11 @@ static sp<ABuffer> MakeAVCCodecSpecificData( *height = 0; AString val; if (!GetAttribute(params, "profile-level-id", &val)) { return NULL; } sp<ABuffer> profileLevelID = decodeHex(val); CHECK(profileLevelID != NULL); sp<ABuffer> profileLevelID = NULL; if (GetAttribute(params, "profile-level-id", &val)) { profileLevelID = decodeHex(val); CHECK_EQ(profileLevelID->size(), 3u); } Vector<sp<ABuffer> > paramSets; Loading Loading @@ -176,8 +174,15 @@ static sp<ABuffer> MakeAVCCodecSpecificData( uint8_t *out = csd->data(); *out++ = 0x01; // configurationVersion if (profileLevelID != NULL) { memcpy(out, profileLevelID->data(), 3); out += 3; } else { *out++ = 0x42; // Baseline profile *out++ = 0xE0; // Common subset for all profiles *out++ = 0x0A; // Level 1 } *out++ = (0x3f << 2) | 1; // lengthSize == 2 bytes *out++ = 0xe0 | numSeqParameterSets; Loading