diff mbox series

[FFmpeg-devel,3/5] fftools/ffprobe: Print more Stereo 3D info from side data

Message ID 20240610184408.68171-4-derek.buitenhuis@gmail.com
State New
Headers show
Series Apple Spatial Metadata | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 fail Make fate failed

Commit Message

Derek Buitenhuis June 10, 2024, 6:44 p.m. UTC
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
---
 fftools/ffprobe.c | 8 ++++++++
 1 file changed, 8 insertions(+)

Comments

Michael Niedermayer June 11, 2024, 6:09 p.m. UTC | #1
On Mon, Jun 10, 2024 at 07:44:05PM +0100, Derek Buitenhuis wrote:
> Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
> ---
>  fftools/ffprobe.c | 8 ++++++++
>  1 file changed, 8 insertions(+)

this needs a update to fate


TEST    matroska-spherical-mono
--- ./tests/ref/fate/matroska-spherical-mono	2024-06-11 16:53:26.034199997 +0200
+++ tests/data/fate/matroska-spherical-mono	2024-06-11 20:09:25.226770382 +0200
@@ -3,6 +3,8 @@
 side_data_type=Stereo 3D
 type=2D
 inverted=0
+view=packed
+primary_eye=none
 [/SIDE_DATA]
 [SIDE_DATA]
 side_data_type=Spherical Mapping
Test matroska-spherical-mono failed. Look at tests/data/fate/matroska-spherical-mono.err for details.
make: *** [tests/Makefile:311: fate-matroska-spherical-mono] Error 1

[...]
Derek Buitenhuis June 11, 2024, 6:43 p.m. UTC | #2
On 6/11/2024 7:09 PM, Michael Niedermayer wrote:
>  side_data_type=Stereo 3D
>  type=2D
>  inverted=0
> +view=packed
> +primary_eye=none

Hmm. This does make me think we need a better way to print 'view' and 'inverted' in 
FFprobe. Perhaps if type!=2D?

- Derek
Derek Buitenhuis June 14, 2024, 1:04 p.m. UTC | #3
On 6/11/2024 7:43 PM, Derek Buitenhuis wrote:
> Perhaps if type!=2D?

Changed locally to this and updated the test.

- Derek
diff mbox series

Patch

diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c
index 2d38e5dfdc..082cec8a64 100644
--- a/fftools/ffprobe.c
+++ b/fftools/ffprobe.c
@@ -2544,6 +2544,14 @@  static void print_pkt_side_data(WriterContext *w,
             const AVStereo3D *stereo = (AVStereo3D *)sd->data;
             print_str("type", av_stereo3d_type_name(stereo->type));
             print_int("inverted", !!(stereo->flags & AV_STEREO3D_FLAG_INVERT));
+            print_str("view", av_stereo3d_view_name(stereo->view));
+            print_str("primary_eye", av_stereo3d_primary_eye_name(stereo->primary_eye));
+            if (stereo->baseline)
+                print_int("baseline", stereo->baseline);
+            if (stereo->horizontal_disparity_adjustment)
+                print_int("horizontal_disparity_adjustment", stereo->horizontal_disparity_adjustment);
+            if (stereo->horizontal_field_of_view)
+                print_int("horizontal_field_of_view", stereo->horizontal_field_of_view);
         } else if (sd->type == AV_PKT_DATA_SPHERICAL) {
             const AVSphericalMapping *spherical = (AVSphericalMapping *)sd->data;
             print_str("projection", av_spherical_projection_name(spherical->projection));