ffmpeginteropx / FFmpegInteropX

FFmpeg decoding library for Windows 10 UWP and WinUI 3 Apps
Apache License 2.0
212 stars 53 forks source link

Expose IsActive and IsHdr for Audio and Video stream infos #444

Closed brabebhin closed 3 days ago

brabebhin commented 5 days ago

This PR adds the following properties: IsActive to VideoStreamInfo and AudioStreamInfo. This is a convenience method for determining which StreamInfo is the active stream info without querying the FFmpegMediaSource.

IsHdr for VideoStreamInfo to determine if a stream has HDR metadata when we use uncompressed providers (Directx or ffmpeg software decoder)

brabebhin commented 4 days ago

hi @lukasf

Thanks for the info. So my understanding of the applyHdrColorInfo flag was kinda wrong after all. ^^

Not sure why I can't relay to your main comment.

brabebhin commented 4 days ago

However, I realize this doesn't actually fully help me and we will probably need a 2nd flag, which will show if we actually "consider" the stream as HDR. i.e. when applyHdrColorInfo is false, even if the stream actually contains HDR metadata.

lukasf commented 4 days ago

That could be a second flag then, e.g. IsHdrActive. A stream could be HDR but it is not used. Then IsHdr = true and IsHdrActive = false.

brabebhin commented 4 days ago

@lukasf take a look at the new commit. thanks.