Upgrade dackka and fix some generation errors

#minor-release

PiperOrigin-RevId: 484483080
This commit is contained in:
andrewlewis 2022-10-28 10:03:56 +00:00 committed by microkatz
parent 42057cc9f8
commit fc1eca10f4
3 changed files with 8 additions and 8 deletions

View File

@ -21,7 +21,7 @@ class CombinedJavadocPlugin implements Plugin<Project> {
// Dackka snapshots are listed at https://androidx.dev/dackka/builds. // Dackka snapshots are listed at https://androidx.dev/dackka/builds.
static final String DACKKA_JAR_URL = static final String DACKKA_JAR_URL =
"https://androidx.dev/dackka/builds/8003564/artifacts/dackka-0.0.14.jar" "https://androidx.dev/dackka/builds/9221390/artifacts/dackka-1.0.4-all.jar"
@Override @Override
void apply(Project project) { void apply(Project project) {

View File

@ -573,10 +573,10 @@ public class SampleQueue implements TrackOutput {
// TrackOutput implementation. Called by the loading thread. // TrackOutput implementation. Called by the loading thread.
@Override @Override
public final void format(Format unadjustedUpstreamFormat) { public final void format(Format format) {
Format adjustedUpstreamFormat = getAdjustedUpstreamFormat(unadjustedUpstreamFormat); Format adjustedUpstreamFormat = getAdjustedUpstreamFormat(format);
upstreamFormatAdjustmentRequired = false; upstreamFormatAdjustmentRequired = false;
this.unadjustedUpstreamFormat = unadjustedUpstreamFormat; unadjustedUpstreamFormat = format;
boolean upstreamFormatChanged = setUpstreamFormat(adjustedUpstreamFormat); boolean upstreamFormatChanged = setUpstreamFormat(adjustedUpstreamFormat);
if (upstreamFormatChangeListener != null && upstreamFormatChanged) { if (upstreamFormatChangeListener != null && upstreamFormatChanged) {
upstreamFormatChangeListener.onUpstreamFormatChanged(adjustedUpstreamFormat); upstreamFormatChangeListener.onUpstreamFormatChanged(adjustedUpstreamFormat);

View File

@ -169,8 +169,8 @@ public final class AviExtractor implements Extractor {
} }
@Override @Override
public int read(ExtractorInput input, PositionHolder positionHolder) throws IOException { public int read(ExtractorInput input, PositionHolder seekPosition) throws IOException {
if (resolvePendingReposition(input, positionHolder)) { if (resolvePendingReposition(input, seekPosition)) {
return RESULT_SEEK; return RESULT_SEEK;
} }
switch (state) { switch (state) {
@ -303,14 +303,14 @@ public final class AviExtractor implements Extractor {
* {@link ExtractorInput#getPosition() current position}, but not further than {@link * {@link ExtractorInput#getPosition() current position}, but not further than {@link
* #RELOAD_MINIMUM_SEEK_DISTANCE}. * #RELOAD_MINIMUM_SEEK_DISTANCE}.
*/ */
private boolean resolvePendingReposition(ExtractorInput input, PositionHolder positionHolder) private boolean resolvePendingReposition(ExtractorInput input, PositionHolder seekPosition)
throws IOException { throws IOException {
boolean needSeek = false; boolean needSeek = false;
if (pendingReposition != C.POSITION_UNSET) { if (pendingReposition != C.POSITION_UNSET) {
long currentPosition = input.getPosition(); long currentPosition = input.getPosition();
if (pendingReposition < currentPosition if (pendingReposition < currentPosition
|| pendingReposition > currentPosition + RELOAD_MINIMUM_SEEK_DISTANCE) { || pendingReposition > currentPosition + RELOAD_MINIMUM_SEEK_DISTANCE) {
positionHolder.position = pendingReposition; seekPosition.position = pendingReposition;
needSeek = true; needSeek = true;
} else { } else {
// The distance to the target position is short enough that it makes sense to just skip the // The distance to the target position is short enough that it makes sense to just skip the