diff mbox series

[FFmpeg-devel,1/3,v5] avutil/stereo3d: add a Stereo3D type to signal that the packing is unspecified

Message ID 20240626233059.10846-1-jamrial@gmail.com
State New
Headers show
Series [FFmpeg-devel,1/3,v5] avutil/stereo3d: add a Stereo3D type to signal that the packing is unspecified | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

James Almer June 26, 2024, 11:30 p.m. UTC
Given that a video stream/frame may have only one view or both views coded with
the packing information being unavailable, this commit adds a new type value
AV_STEREO3D_UNSPEC for this purpose.
The most common case for this is container level signaling of Stereo3D video
where the specifics are defined at the bitstream level.

Signed-off-by: James Almer <jamrial@gmail.com>
---
 libavutil/stereo3d.c | 1 +
 libavutil/stereo3d.h | 5 +++++
 2 files changed, 6 insertions(+)

Comments

James Almer June 28, 2024, 2:52 p.m. UTC | #1
On 6/26/2024 8:30 PM, James Almer wrote:
> Given that a video stream/frame may have only one view or both views coded with
> the packing information being unavailable, this commit adds a new type value
> AV_STEREO3D_UNSPEC for this purpose.
> The most common case for this is container level signaling of Stereo3D video
> where the specifics are defined at the bitstream level.
> 
> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
>   libavutil/stereo3d.c | 1 +
>   libavutil/stereo3d.h | 5 +++++
>   2 files changed, 6 insertions(+)
> 
> diff --git a/libavutil/stereo3d.c b/libavutil/stereo3d.c
> index 7ea3dceb33..647f9a952a 100644
> --- a/libavutil/stereo3d.c
> +++ b/libavutil/stereo3d.c
> @@ -74,6 +74,7 @@ static const char * const stereo3d_type_names[] = {
>       [AV_STEREO3D_SIDEBYSIDE_QUINCUNX] = "side by side (quincunx subsampling)",
>       [AV_STEREO3D_LINES]               = "interleaved lines",
>       [AV_STEREO3D_COLUMNS]             = "interleaved columns",
> +    [AV_STEREO3D_UNSPEC]              = "unspecified",
>   };
>   
>   static const char * const stereo3d_view_names[] = {
> diff --git a/libavutil/stereo3d.h b/libavutil/stereo3d.h
> index 386455a5a4..e3da3257d7 100644
> --- a/libavutil/stereo3d.h
> +++ b/libavutil/stereo3d.h
> @@ -136,6 +136,11 @@ enum AVStereo3DType {
>        * @endcode
>        */
>       AV_STEREO3D_COLUMNS,
> +
> +    /**
> +     * Video is stereoscopic but the packing is unspecified.
> +     */
> +    AV_STEREO3D_UNSPEC,
>   };
>   
>   /**

Will add APIchanges entry and version bump, then push the set.
diff mbox series

Patch

diff --git a/libavutil/stereo3d.c b/libavutil/stereo3d.c
index 7ea3dceb33..647f9a952a 100644
--- a/libavutil/stereo3d.c
+++ b/libavutil/stereo3d.c
@@ -74,6 +74,7 @@  static const char * const stereo3d_type_names[] = {
     [AV_STEREO3D_SIDEBYSIDE_QUINCUNX] = "side by side (quincunx subsampling)",
     [AV_STEREO3D_LINES]               = "interleaved lines",
     [AV_STEREO3D_COLUMNS]             = "interleaved columns",
+    [AV_STEREO3D_UNSPEC]              = "unspecified",
 };
 
 static const char * const stereo3d_view_names[] = {
diff --git a/libavutil/stereo3d.h b/libavutil/stereo3d.h
index 386455a5a4..e3da3257d7 100644
--- a/libavutil/stereo3d.h
+++ b/libavutil/stereo3d.h
@@ -136,6 +136,11 @@  enum AVStereo3DType {
      * @endcode
      */
     AV_STEREO3D_COLUMNS,
+
+    /**
+     * Video is stereoscopic but the packing is unspecified.
+     */
+    AV_STEREO3D_UNSPEC,
 };
 
 /**