Merge "Fix CTS tests" into rvc-dev am: 881b688f68
Change-Id: I7d588274ab732da753d3204233a4f9e8fbae1af0
This commit is contained in:
@@ -700,30 +700,34 @@ public final class MediaParser {
|
|||||||
mDataSource.mInputReader = seekableInputReader;
|
mDataSource.mInputReader = seekableInputReader;
|
||||||
|
|
||||||
// TODO: Apply parameters when creating extractor instances.
|
// TODO: Apply parameters when creating extractor instances.
|
||||||
if (mExtractorName != null) {
|
if (mExtractor == null) {
|
||||||
mExtractor = EXTRACTOR_FACTORIES_BY_NAME.get(mExtractorName).createInstance();
|
if (mExtractorName != null) {
|
||||||
} else if (mExtractor == null) {
|
mExtractor = EXTRACTOR_FACTORIES_BY_NAME.get(mExtractorName).createInstance();
|
||||||
for (String parserName : mParserNamesPool) {
|
mExtractor.init(new ExtractorOutputAdapter());
|
||||||
Extractor extractor = EXTRACTOR_FACTORIES_BY_NAME.get(parserName).createInstance();
|
} else {
|
||||||
try {
|
for (String parserName : mParserNamesPool) {
|
||||||
if (extractor.sniff(mExtractorInput)) {
|
Extractor extractor =
|
||||||
mExtractorName = parserName;
|
EXTRACTOR_FACTORIES_BY_NAME.get(parserName).createInstance();
|
||||||
mExtractor = extractor;
|
try {
|
||||||
mExtractor.init(new ExtractorOutputAdapter());
|
if (extractor.sniff(mExtractorInput)) {
|
||||||
break;
|
mExtractorName = parserName;
|
||||||
|
mExtractor = extractor;
|
||||||
|
mExtractor.init(new ExtractorOutputAdapter());
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
} catch (EOFException e) {
|
||||||
|
// Do nothing.
|
||||||
|
} catch (IOException | InterruptedException e) {
|
||||||
|
throw new IllegalStateException(e);
|
||||||
|
} finally {
|
||||||
|
mExtractorInput.resetPeekPosition();
|
||||||
}
|
}
|
||||||
} catch (EOFException e) {
|
|
||||||
// Do nothing.
|
|
||||||
} catch (IOException | InterruptedException e) {
|
|
||||||
throw new IllegalStateException(e);
|
|
||||||
} finally {
|
|
||||||
mExtractorInput.resetPeekPosition();
|
|
||||||
}
|
}
|
||||||
|
if (mExtractor == null) {
|
||||||
|
throw UnrecognizedInputFormatException.createForExtractors(mParserNamesPool);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
if (mExtractor == null) {
|
|
||||||
throw UnrecognizedInputFormatException.createForExtractors(mParserNamesPool);
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isPendingSeek()) {
|
if (isPendingSeek()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user