Lossless media edits causing playback issues in AndroidTV client - Printable Version +- Jellyfin Forum (https://forum.jellyfin.org) +-- Forum: Support (https://forum.jellyfin.org/f-support) +--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting) +--- Thread: Lossless media edits causing playback issues in AndroidTV client (/t-lossless-media-edits-causing-playback-issues-in-androidtv-client) |
Lossless media edits causing playback issues in AndroidTV client - Perseverant - 2024-06-19 There is a program out there called AviDemux that will do lossless chops on I-frames. I do some minor censoring of movies for my family sometimes, and will occasionally take out sections of a film that I'd rather the fam not see, using AviDemux to do it so that I don't have to have the quality loss associated with re-encoding it. My edited films play great in VLC on my PC, and my buddy (who also owns the same film) threw it on his Plex server and it played without issue, but Jellyfin is another matter... In the AndroidTV client, when exoplayer reaches the place in the movie where I chopped things, it fails, retries a few times, and then gives up. If I use VLClib to play it instead, playback won't hard-fail on an error like it does with exoplayer, but it shows some garbled frames for a second or two where I cut, then resumes playback, and it's jarring enough to totally take you out of the movie. I hope what I'm describing makes sense, but I have no idea what information I can offer to help you guys troubleshoot this issue. Please let me know whatever info I can get you and I'll try to track it down. RE: Lossless media edits causing playback issues in AndroidTV client - TheDreadPirate - 2024-06-19 I'm not sure how AviDemux works in the background, but one thing you can try is to repackage the file. Code: /usr/lib/jellyfin-ffmpeg/ffmpeg -fflags genpts -i "/path/to/video.mkv" -map 0:v -map 0:a -map 0:s -map_chapters 0 -c:v copy -c:a copy -c:s copy outputFile.mkv This will copy the video, audio, and subs unmodified and just regenerate the packet time stamps. Jellyfin, and a lot of the players Jellyfin uses, are not very tolerant of faults and out of spec files. RE: Lossless media edits causing playback issues in AndroidTV client - Perseverant - 2024-06-19 (2024-06-19, 05:26 PM)TheDreadPirate Wrote: I'm not sure how AviDemux works in the background, but one thing you can try is to repackage the file. Thank you. I can take a crack at doing that, though I can't say I use ffmpeg command line much. Would re-multiplexing the file in MKVtoolnix achieve the same end? If so this workaround is probably a dead-end, but I'm willing to take a crack at it regardless. RE: Lossless media edits causing playback issues in AndroidTV client - TheDreadPirate - 2024-06-19 What we're doing is re-multiplexing, yes. How different the command I specified is from how MKVToolnix does things, I don't know. RE: Lossless media edits causing playback issues in AndroidTV client - Perseverant - 2024-06-19 (2024-06-19, 06:25 PM)TheDreadPirate Wrote: What we're doing is re-multiplexing, yes. How different the command I specified is from how MKVToolnix does things, I don't know.Unfortunately, it's a bust - same problem after re-multiplexing. FFMPEG yielded a larger file that had the same issue (MKVtoolnix apparently has some optimizations that vanilla FFMPEG lacks). What would you recommend in terms of next steps? I don't want to bug the developers, but it would be great if Jellyfin could be enhanced to handle whatever file-level issues are going on seamlessly like VLC and Plex do. RE: Lossless media edits causing playback issues in AndroidTV client - TheDreadPirate - 2024-06-19 Jellyfin doesn't make an in-house media engine. We use various open source engines like exoplayer or libVLC on Android/AndroidTV, whatever HTML video player is built in to your browser, MPV in Jellyfin Media Player, etc. So we have little control over fault tolerance or out of spec files. What happens when you force transcoding? Setting the quality to a bit rate lower than the video's native bit rate. As for next steps. I don't really have a good answer. If transcoding works, that kind of answers the question, though. RE: Lossless media edits causing playback issues in AndroidTV client - SethBacon - 2024-06-19 This is kinda fascinating. Could you possibly give some example titles/scenes you remove? Ive thought about adding further epilogue cards to older documentaries, so I guess I cant get on a horse about editing art but still, didn't Marge learn this lesson trying to censor itchy and scratchy circa 1991? RE: Lossless media edits causing playback issues in AndroidTV client - Perseverant - 2024-06-19 (2024-06-19, 07:29 PM)TheDreadPirate Wrote: Jellyfin doesn't make an in-house media engine. We use various open source engines like exoplayer or libVLC on Android/AndroidTV, whatever HTML video player is built in to your browser, MPV in Jellyfin Media Player, etc. So we have little control over fault tolerance or out of spec files. That makes sense. Bit of a bummer. Since it plays perfectly in VLC I would think that libVLC would also play it properly, but there must be some internal differences between them. I wonder if there is a newer version of libVLC that might work better. I disable transcoding since quality is a top priority for me (I encode prior to putting things on the server with "very slow" presets), but sounds like I might end up having to try re-encoding it and just take the quality hit. Thanks for brainstorming. |