fix(perf): stop reporting an unmeasured decoder as Software - #4
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The performance overlay reports Software decoding on the Tizen TV, and labels the backend ExoPlayer. Both are false. Video decodes on the TV's own SoC, outside Flutter entirely — that hardware-overlay plane is the whole reason the port exists.
Root cause
PlayerTizen.providesNativeStatsistrue, so stats take the_fetchAndroidStats()path. That branches on the reported player type:'tizen'is not'mpv', so it falls into the ExoPlayer parse. Three failures follow:playerType: 'exoplayer'is hardcoded in that branch.PlayerTizen.getStats()emitted'videoDecoder': 'unknown', but the only reader isstatsMap['videoDecoderName']. Nothing in the codebase reads'videoDecoder'— the backend told the truth and a key mismatch threw it away.hwdecCurrentis only populated in the mpv branch, so it is null here, andhwdecFormattedtreatednullexactly like mpv's'no'.The fix
'tizen'branch that emits only what the backend actually returns. Every other metric stays null, so the overlay printsN/Arather than inventing a value.hwdecFormattedseparates no signal from evidence of software: only mpv's own'no'still reads as Software; null or empty now readsN/A. This is not Tizen-specific — any backend that fails to answer previously got labelled Software.'videoDecoder'key is removed rather than renamed. Emitting it asvideoDecoderNamewould sendhwdecFormatteddown its first branch, fail the hardware-pattern match, and land back on Software.!isMpvmeant "ExoPlayer" when there were two backends. There are three now, so the ExoPlayer-only metrics ask forisExoby name. This also stops Tizen showing aTunneling: Offrow for an ExoPlayer feature it does not have.Why
N/Aand notHardwareCapi exposes no decoder-name or hwdec API, so asserting hardware acceleration would be the same error pointing the other way.
docs/tizen/ACCEPTANCE.mdalready requires this:Verification
flutter analyzeon the changed files — clean.N/A; and mpv's'no'still reads as Software, so the real signal is not lost.downloads_screen_focus_test, which reproduces on cleanmainand is unrelated.hwdecFormattedis shared across every backend, so the whole suite was run rather than the overlay tests alone.Independent of #3; touches no file that PR does.
AI assistance
Written with Claude Opus 5 via Claude Code, per CONTRIBUTING.md.
🤖 Generated with Claude Code