Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: Derek Buitenhuis <derek.buitenhuis@gmail.com>
To: ffmpeg-devel@ffmpeg.org
Subject: [FFmpeg-devel] [PATCH v2 1/5] avutil/spherical: Add more spherical types
Date: Mon, 17 Jun 2024 14:41:37 +0100
Message-ID: <20240617134141.224614-2-derek.buitenhuis@gmail.com> (raw)
In-Reply-To: <20240617134141.224614-1-derek.buitenhuis@gmail.com>

These originate from the Apple Vision Pro, and are documented here:

    https://developer.apple.com/documentation/coremedia/cmprojectiontype

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
---
 libavutil/spherical.c |  5 +++++
 libavutil/spherical.h | 16 ++++++++++++++++
 libavutil/version.h   |  2 +-
 3 files changed, 22 insertions(+), 1 deletion(-)

diff --git a/libavutil/spherical.c b/libavutil/spherical.c
index 800d3459a5..64ade1d0ec 100644
--- a/libavutil/spherical.c
+++ b/libavutil/spherical.c
@@ -29,6 +29,8 @@ AVSphericalMapping *av_spherical_alloc(size_t *size)
     if (!spherical)
         return NULL;
 
+    spherical->projection = AV_SPHERICAL_RECTILINEAR;
+
     if (size)
         *size = sizeof(*spherical);
 
@@ -57,6 +59,9 @@ static const char *const spherical_projection_names[] = {
     [AV_SPHERICAL_EQUIRECTANGULAR]      = "equirectangular",
     [AV_SPHERICAL_CUBEMAP]              = "cubemap",
     [AV_SPHERICAL_EQUIRECTANGULAR_TILE] = "tiled equirectangular",
+    [AV_SPHERICAL_HALF_EQUIRECTANGULAR] = "half equirectangular",
+    [AV_SPHERICAL_RECTILINEAR]          = "rectilinear",
+    [AV_SPHERICAL_FISHEYE]              = "fisheye",
 };
 
 const char *av_spherical_projection_name(enum AVSphericalProjection projection)
diff --git a/libavutil/spherical.h b/libavutil/spherical.h
index 828ac836da..2e90f7752d 100644
--- a/libavutil/spherical.h
+++ b/libavutil/spherical.h
@@ -66,6 +66,22 @@ enum AVSphericalProjection {
      * the position of the current video in a larger surface.
      */
     AV_SPHERICAL_EQUIRECTANGULAR_TILE,
+
+    /**
+     * Video frame displays as a 180 degree equirectangular projection.
+     */
+    AV_SPHERICAL_HALF_EQUIRECTANGULAR,
+
+    /**
+     * Video frame displays on a flat, rectangular 2D surface.
+     */
+    AV_SPHERICAL_RECTILINEAR,
+
+    /**
+     * Fisheye projection (Apple).
+     * See: https://developer.apple.com/documentation/coremedia/cmprojectiontype/fisheye
+     */
+    AV_SPHERICAL_FISHEYE,
 };
 
 /**
diff --git a/libavutil/version.h b/libavutil/version.h
index 2756f2aa03..7df546ee22 100644
--- a/libavutil/version.h
+++ b/libavutil/version.h
@@ -79,7 +79,7 @@
  */
 
 #define LIBAVUTIL_VERSION_MAJOR  59
-#define LIBAVUTIL_VERSION_MINOR  22
+#define LIBAVUTIL_VERSION_MINOR  23
 #define LIBAVUTIL_VERSION_MICRO 100
 
 #define LIBAVUTIL_VERSION_INT   AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
-- 
2.43.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

  reply	other threads:[~2024-06-17 13:42 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-17 13:41 [FFmpeg-devel] [PATCH v2 0/5] Vision Pro Spatial Data Derek Buitenhuis
2024-06-17 13:41 ` Derek Buitenhuis [this message]
2024-06-17 13:41 ` [FFmpeg-devel] [PATCH v2 2/5] avutil/stereo3d: Fill out stereo info provided by Vision Pro files Derek Buitenhuis
2024-06-17 16:53   ` James Almer
2024-06-17 17:07     ` Derek Buitenhuis
2024-06-17 18:09       ` James Almer
2024-06-17 19:02         ` Derek Buitenhuis
2024-06-17 13:41 ` [FFmpeg-devel] [PATCH v2 3/5] fftools/ffprobe: Print more Stereo 3D info from side data Derek Buitenhuis
2024-06-17 13:41 ` [FFmpeg-devel] [PATCH v2 4/5] avformat/mov: Add support for exporting Video Extension Usage info Derek Buitenhuis
2024-06-17 13:45   ` Derek Buitenhuis
2024-06-17 13:41 ` [FFmpeg-devel] [PATCH v2 5/5] avformat/mov: Add support for reading and exporting horizontal field of view Derek Buitenhuis
2024-06-17 13:44 ` [FFmpeg-devel] [PATCH v3 4/5] avformat/mov: Add support for exporting Video Extension Usage info Derek Buitenhuis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240617134141.224614-2-derek.buitenhuis@gmail.com \
    --to=derek.buitenhuis@gmail.com \
    --cc=ffmpeg-devel@ffmpeg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git