Any programme that arrives as sound with no picture is unplayable, not just AVIs

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-09 17:49:24 +00:00
co-authored by Claude Opus 5.5
parent 127191abbc
commit e6151c9584
@@ -250,12 +250,13 @@ internal fun EmbyPlaybackDialog(session: EmbySampleSession, plan: EmbyPlaybackPl
format.sampleMimeType, format.channelCount, format.sampleRate, format.language, format.width, format.height))
}
val video = tracks.groups.filter { it.type == C.TRACK_TYPE_VIDEO }
// An AVI whose picture Media3 can't even read (DivX 3, found 9 November 2026) comes through as sound alone.
val aviWithoutPicture = video.isEmpty() && tracks.groups.any { it.type == C.TRACK_TYPE_AUDIO } && plan.url.substringBefore('?').endsWith(".avi")
if (scheduled != null && aviWithoutPicture) {
android.util.Log.w("OrbitSchedule", "channel=${scheduled.channel.number} noVideoTrack=avi")
// A file whose picture Media3 can't even read comes through as sound alone (DivX 3 in an AVI, found 9 November
// 2026; an MKV with an unknown picture format does the same). Every Orbit programme has a picture.
val soundWithoutPicture = video.isEmpty() && tracks.groups.any { it.type == C.TRACK_TYPE_AUDIO }
if (scheduled != null && soundWithoutPicture) {
android.util.Log.w("OrbitSchedule", "channel=${scheduled.channel.number} noVideoTrack=${plan.url.substringBefore('?').substringAfterLast('.').take(8)}")
player.stop(); ready = false
Unplayable.note(plan.item.id, plan.item.title, scheduled.channel.number, "This TV can't read the picture in this AVI file.")
Unplayable.note(plan.item.id, plan.item.title, scheduled.channel.number, "This TV can't read the picture in this file.")
onUnplayable?.invoke(plan.item.id)
failure = "This programme won't play on this box. Orbit moves on at ${clock(scheduled.programme.endMs)}."
return