This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

HDR encoding
#1
Hello,

In case of willing to reencode a 10-bit HEVC HDR source to the same format output, what is needed for the HDR metadata to
be included in the output correctly (to be able to passthrough to the display during play)? Would be using the --repeat-headers parameter enough on the command line?

What "special info" would be needed for the encoder to handle a 10-bit HEVC HDR source correctly (to utilize the HDR metadata during encoding)?
Answer would be really appreciated.
Reply
#2
No, repeat headers won't help at all you need to enter all the her data. Can't tell you how to get all those infos from an existing stream though. Which is why Hybrid has no option for it.
-> unless you know all the data and set the appropriate flags the output might not get processed by your display the way you want.

Cu Selur
Reply
#3
(28.08.2017, 16:18)Selur Wrote: No, repeat headers won't help at all you need to enter all the her data. Can't tell you how to get all those infos from an existing stream though. Which is why Hybrid has no option for it.
-> unless you know all the data and set the appropriate flags the output might not get processed by your display the way you want.

Cu Selur

Mediainfo can read out of such sources the parameters as follows (theoretically, Big Grin ):

Color range
Color primaries
Transfer characteristics
Matrix coefficients
Mastering display color primaries 
Mastering display luminance 
Maximum Content Light Level 
Maximum Frame-Average Light Level 

which can be set on the x265 command line manually. These infos can be determined during encoding surely.
Reply
#4
Quote:which can be set on the x265 command line manually.
Hybrid also has options for all values related to HDR under x265->Signaling.
No clue whether the data reported by MediaInfo can be simply copied, but you can report once you tried.

Cu Selur
Reply
#5
(28.08.2017, 18:16)Selur Wrote:
Quote:which can be set on the x265 command line manually.
Hybrid also has options for all values related to HDR under x265->Signaling.
No clue whether the data reported by MediaInfo can be simply copied, but you can report once you tried.

Cu Selur

Nice. Can I use Hybrid with DGDecNV for decoding 10 bit HEVC UHD HDR (DGDecNV is compatible with HEVC by now)?
Is it possible to import 10 bit HEVC sources in UHD resolution?
Reply
#6
Quote:Can I use Hybrid with DGDecNV for decoding 10 bit HEVC UHD HDR (DGDecNV is compatible with HEVC by now)?
No, Hybrid doesn't support decoding anything above 2048x2048 atm. through DGDecNV.
(VP7 cards should be able to decode HEVC Main and Main 10 profile; VP8 cards should be able to handle HEVC Main 12; VP8 cards should also support 8k resolutions iirc.)
-> might come in the future isn't supported atm. by Hybrid (probably when I get my hands on a newer card, atm. I use a Geforce GTX 980 ti, which doesn't support hevc)

Quote:Is it possible to import 10 bit HEVC sources in UHD resolution?
Yes, through libavsource.
Reply
#7
(28.08.2017, 19:12)Selur Wrote:
Quote:Can I use Hybrid with DGDecNV for decoding 10 bit HEVC UHD HDR (DGDecNV is compatible with HEVC by now)?
No, Hybrid doesn't support decoding anything above 2048x2048 atm. through DGDecNV.
(VP7 cards should be able to decode HEVC Main and Main 10 profile; VP8 cards should be able to handle HEVC Main 12; VP8 cards should also support 8k resolutions iirc.)
-> might come in the future isn't supported atm. by Hybrid (probably when I get my hands on a newer card, atm. I use a Geforce GTX 980 ti, which doesn't support hevc)

Quote:Is it possible to import 10 bit HEVC sources in UHD resolution?
Yes, through libavsource.

Thanks. I have here Geforce GTX 1060. Project crashed. Why may Hybrid leave "--input -" parameter in the command line?

UHD 12-bit HDR encoding just have started using all the infos media info reported after importing the source!!!!
Reply
#8
Quote:Why may Hybrid leave "--input -" parameter in the command line?
Why do you think Hybrid should remove "--input -" from a command line? Only reason for '--input -' not showing up inside the command line of x265 would be if x265 also was the decoder, which it never is in Hybrid. Hybrid doesn't create humongous raw YUV files to feed them to x265.
-> No clue why you think the '--input -' part should be removed.

Quote:Project crashed.
Which can have tons of reasons,... starting with Avisynth running out of RAM.
Since you didn't care about providing any details (which you should know are needed for me to understand what you do) I assume the issue is solved and you don't want/need any help.

Cu Selur
Reply
#9
(28.08.2017, 21:08)Selur Wrote:
Quote:Why may Hybrid leave "--input -" parameter in the command line?
Why do you think Hybrid should remove  "--input -" from a command line? Only reason for '--input -' not showing up inside the command line of x265 would be if x265 also was the decoder, which it never is in Hybrid. Hybrid doesn't create humongous raw YUV files to feed them to x265.
-> No clue why you think the '--input -' part should be removed.

Quote:Project crashed.
Which can have tons of reasons,... starting with Avisynth running out of RAM.
Since you didn't care about providing any details (which you should know are needed for me to understand what you do) I assume the issue is solved and you don't want/need any help.

Cu Selur


Now it seems to be working (encoding has started!) even at 12bit, with cropping etc. I forgot some wrong marks in the command line.
I gave Hybrid all the HDR parameters which could be read out from Mediainfo. The estimated file size is 6GB instead of 55 GB....I like the power of CRF encoding....
I will report back if I can display correctly the results on my old (from 2014) 4K LG TV which do supports some form of HDR.

(28.08.2017, 21:08)Selur Wrote:
Quote:Why may Hybrid leave "--input -" parameter in the command line?
Why do you think Hybrid should remove  "--input -" from a command line? Only reason for '--input -' not showing up inside the command line of x265 would be if x265 also was the decoder, which it never is in Hybrid. Hybrid doesn't create humongous raw YUV files to feed them to x265.
-> No clue why you think the '--input -' part should be removed.

Quote:Project crashed.
Which can have tons of reasons,... starting with Avisynth running out of RAM.
Since you didn't care about providing any details (which you should know are needed for me to understand what you do) I assume the issue is solved and you don't want/need any help.

Cu Selur

Could you please check if it is correct (I just want to crop before converting the source to 12-bit, it seems it is not possible with cropping used to keep the 10bit-12 bit conversion route)
It seems Hybrid thinks the source is 8-bit (wants to dither to 8 bit instead of 10 bit, and doesn't let me modify e.g. the matrix from bt.709 to bt.2020, etc...:

SetMemoryMax(1536)
SetMTMode(5,12) # change MT mode
LoadPlugin("C:\PROGRA~1\Hybrid\AVISYN~1\LSMASHSource.dll")
LoadPlugin("C:\PROGRA~1\Hybrid\AVISYN~1\dither.dll")
LoadPlugin("C:\PROGRA~1\Hybrid\AVISYN~1\flash3kyuu_deband.dll")
Import("C:\Program Files\Hybrid\avisynthPlugins\dither.avsi")
# loading source: D:\x\UHD\x\x.mkv
#  input luminance scale tv
LWLibavVideoSource("D:\x\UHD\x\x.mkv",cache=false,stacked=true,format="YUV420P16",repeat=true)
# current resolution: 3840x2160
SetMTMode(2) # change MT mode
# cropping to 3840x1604
Dither_crop16(0,278,0,-278)
# current resolution: 3840x1604
# dithering from 16 to 8bit for encoder
f3kdb_dither(stacked=true,input_depth=16)
distributor()
return last
Reply
#10
(28.08.2017, 21:08)Selur Wrote:
Quote:Why may Hybrid leave "--input -" parameter in the command line?
Why do you think Hybrid should remove  "--input -" from a command line? 
The filename was missing in the place of "-" that is why I thought that was the reason for crashing.
Reply


Forum Jump:


Users browsing this thread: 10 Guest(s)