Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
27th September 2022, 19:18 | #1 | Link |
Lost my old account :(
Join Date: Jul 2017
Posts: 322
|
decode at realtime?
Hi,
This is surly the wrong section for this, but I wasnt sure were to post this as its more of a ffmpeg question. But as I'm going to to use HEVC endcoders i might as well try to post it here. Please feel free to move it if there is a more appropriate section for it. I wanna do some tests with real time encoding for HEVC-encoders, I usually use ffmpeg and pipe the decoded video to the encoder. Is it possible to limit the decode speed to the source framerate of the video file with ffmpeg? And that way limit the encoding speed to real time. I know its possible when doing different types of capture with ffmpeg, but it should be possible with file input as well, right? Last edited by excellentswordfight; 27th September 2022 at 19:25. |
27th September 2022, 19:37 | #2 | Link |
Banana User
Join Date: Sep 2008
Posts: 985
|
I don't understand why you need to limit decoding, then you are limiting encoding too.
__________________
InpaintDelogo, DoomDelogo, JerkyWEB Fixer, Standalone Faster-Whisper - AI subtitling |
27th September 2022, 21:26 | #4 | Link |
Banana User
Join Date: Sep 2008
Posts: 985
|
I'd use fastest decoding possible [something like MagicYUV] and let encoding to run full speed.
Faster encoding in full speed = better performance in "realtime".
__________________
InpaintDelogo, DoomDelogo, JerkyWEB Fixer, Standalone Faster-Whisper - AI subtitling |
27th September 2022, 22:25 | #6 | Link | |
Registered User
Join Date: Dec 2013
Posts: 343
|
Quote:
As input is a file I would not use that as a clock, I would limit the speed by blocking the encoder output and not accept further data from the encoder until a certain time has passed. |
|
2nd October 2022, 01:19 | #7 | Link |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,883
|
Well, it's gonna be easy to limit it to real time: you just need a live feed.
For instance, if you have a capture card like a BlackMagic Decklink, you can use that input and re-encode that, otherwise if you don't have anything like that, you can always grab the video from the webcam (assuming you have one) and encode that. It's all easily doable with FFMpeg, so you can easily grab the input and pipe it to x265. If you don't have anything like that, you can still grab the desktop and encode the desktop... |
2nd October 2022, 09:40 | #8 | Link | |
Lost my old account :(
Join Date: Jul 2017
Posts: 322
|
Quote:
Last edited by excellentswordfight; 2nd October 2022 at 09:43. |
|
2nd October 2022, 12:29 | #9 | Link |
Registered User
Join Date: Dec 2013
Posts: 343
|
Are you planning to do this within ffmpeg, with audio or some other high level stuff after or around the h.265 encoder or can you pipe the bitstream from the h.265 encoder to somewhere ?
So my question is, is it something simple like this: ffmpeg.exe <args> | x265.exe <args> -o out.265 Or is it something like this: handbrake.exe *edit* Reading the initial post again reminds me to go and have my long term memory looked at. Last edited by rwill; 2nd October 2022 at 18:10. |
2nd October 2022, 18:08 | #10 | Link |
Registered User
Join Date: Dec 2013
Posts: 343
|
I got interested into power consumption and CPU load @ realtime as well due to this post. So I threw together this:
https://github.com/rwillenbacher/piclimiter |
2nd October 2022, 20:40 | #13 | Link |
Lost my old account :(
Join Date: Jul 2017
Posts: 322
|
Well I feel stupid now, that was the first thing i tried, and when I piped it to QSVEncC64 I saw that it started at 200fps and I canceled it and moved on... I can see now that it goes down to around 60 rather fast so it does indeed seem to be working! Thank you!
I'm still gonna give you a huge A for effort |
Thread Tools | Search this Thread |
Display Modes | |
|
|