diff options
author | Lynne <dev@lynne.ee> | 2024-06-23 15:58:28 +0200 |
---|---|---|
committer | Lynne <dev@lynne.ee> | 2024-06-24 23:53:25 +0200 |
commit | dae12ddb2e5d4ec8cf5a965f4ac793edfa3802d6 (patch) | |
tree | 4161d26f1fdb57c9184fe469841ef0d12f99ebc9 /libavformat/mov.c | |
parent | 0d748eec8d52715f2949bd03519d39f2bf5baac4 (diff) | |
download | ffmpeg-dae12ddb2e5d4ec8cf5a965f4ac793edfa3802d6.tar.gz |
lavu/stereo3d: change the horizontal FOV field to a rational
This avoids hardcoding any implementation-specific limitiations as
part of the API, and allows for future expandability.
This also allows API users to more conveniently convert the
values into floats without hardcoding specific conversion constants.
The API was committed a few days ago, so changing this field now
is within the realms of acceptable.
Diffstat (limited to 'libavformat/mov.c')
-rw-r--r-- | libavformat/mov.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c index f08fec3fb6..fe8a963c6e 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -6782,7 +6782,8 @@ static int mov_read_hfov(MOVContext *c, AVIOContext *pb, MOVAtom atom) return AVERROR(ENOMEM); } - sc->stereo3d->horizontal_field_of_view = avio_rb32(pb); + sc->stereo3d->horizontal_field_of_view.num = avio_rb32(pb); + sc->stereo3d->horizontal_field_of_view.den = 1000; // thousands of a degree return 0; } |