-
Notifications
You must be signed in to change notification settings - Fork 206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Muxing vc1 into mkv results in video artifacts #1546
Comments
Yeah this definitely seems like more of an FFMPEG issue. I would probably try just running some basic FFMPEG remux commands and see if the issue is still present but probably not something I can fix |
If you can produce an FFMPEG that works correctly please post and I'll try and adjust the script accordingly but for now I'm gonna blame this on FFMPEG and close. |
I have been digging a lot, looks like an issue with keyframes, I have no idea why they happen when ffmpeg writes to matroska files (they are all N/A) but when it's on an mp4 container it works perfectly fine with all keyframes seemingly fine |
Yup, ffmpeg seems to not write timestamps data when it remuxes to matroska, I have no idea why, but mkvmerge works perfectly and does have correct timestamps for each keyframe and playback is correct I know the tool mainly uses ffmpeg and thus mkvmerge usage won't be supported, I will try looking into it to see if timestamps can be fixed by an ffmpeg arg |
I tried many things with ffmpeg but all seem to fail and not produce timestamps So my option seems to be running an mkvmerge script (really just mkvmerge + filename.mp4 would fix it), is there a way to pass the v.codec (like custom.py) to the post processing scripts? |
That information isn't passed to the custom scripts directly, but you can easily import the existing libraries included in the script to read that information without reinventing the wheel and do whatever custom work you need Untested sample (might need to tweak relative import paths) import os
from resources.readsettings import ReadSettings
from resources.mediaprocessor import MediaProcessor
files = os.env.get("SMA_FILES")
settings = ReadSettings()
mp = MediaProcessor(settings)
info = mp.isValidSource(files[0])
print(info.video.codec) |
Oh that's much better than my current script I forgot to update, I have tried both mkvmerge & ffmpeg stuff, many times and in many ways, all of them have this issue Mkvmerge usually produces crashing files, not sure why as the file seems good, and ffmpeg 4.4 (decided to build an ffmpeg 4.4 just to test it out) produces completely unplayable black-boxes-everywhere even if you resume from the middle Best solution I found is to use ffmpeg 5.0 as it partially works, you need to resume from somewhere that's not from 0:00, you will get a few glitches but they go away in a second or 2, if you start the video from the very start you will get those annoying boxes What I'm currently doing is just a basic custom.py to change the extension if it detects vc1 video codec To clarify, this seems to be an issue with the bad & abysmal Android player, so it doesn't affect most other devices (they play normally), I'm changing it from mp4 since most Plex clients only support the codec if it's on an mkv container, mp4 playback is flawless but the server transcodes so it kinda defeats the purpose Hope this helps someone out there |
Describe the bug
After processing a vc1 video content (no encoding, just muxing around and removing some subs), the video when streamed has lots of glitches, sort of like datamoshing, and when played from the start, it gets all black (See screenshot below) and there is barely any actual content that you can see, until you exit the stream and start from a bit further, you still see the moshing artifacts but they go away quickly, it might be something with the I-frames but I haven't dug into it and I don't know much about it
1 - When starting a video from the start:
![image](https://user-images.githubusercontent.com/34054757/155091918-25e95096-b141-4909-a957-7acbc852ce63.png)
2 - When starting/forwarding somewhere further (Goes away quick after a second or 2):
![image](https://user-images.githubusercontent.com/34054757/155092092-a96ed64d-1aaa-417d-bf6d-79ea68ec0c7c.png)
Taken from an Android 12 device, the glitches probably effect other devices
Command or context you are trying to run
from SABnzbd's:
autoProcess.ini settings
Please sensor API keys/private information but include all other settings
Log files
(Basically same as above)
System Information
Expected behavior
For videos to play normally
Additional context
I have looked around and it might be something with ffmpeg, I have downloaded the same content and muxed the data using mkvtoolnix and there was no issues with the playback, something may need to be changed or a command in ffmpeg
I have edited the SABnzbdpostporcess.py to launch Re-locate moov & make it run the custom post-processing scripts
Issues posted without any logs or autoProcess settings will be closed
The text was updated successfully, but these errors were encountered: