[FFmpeg-cvslog] libavutil: Adds gray floating-point pixel formats.

2018-08-11 Thread Sergey Lavrushkin
ffmpeg | branch: master | Sergey Lavrushkin  | Fri Aug  3 
18:02:49 2018 +0300| [00ae3498bf033e9d50608339c2ec4e244f860e13] | committer: 
Michael Niedermayer

libavutil: Adds gray floating-point pixel formats.

Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=00ae3498bf033e9d50608339c2ec4e244f860e13
---

 libavutil/pixdesc.c  | 22 ++
 libavutil/pixfmt.h   |  5 +
 libavutil/version.h  |  4 ++--
 tests/ref/fate/sws-pixdesc-query |  3 +++
 4 files changed, 32 insertions(+), 2 deletions(-)

diff --git a/libavutil/pixdesc.c b/libavutil/pixdesc.c
index 96e079584a..970a83214c 100644
--- a/libavutil/pixdesc.c
+++ b/libavutil/pixdesc.c
@@ -2206,6 +2206,28 @@ static const AVPixFmtDescriptor 
av_pix_fmt_descriptors[AV_PIX_FMT_NB] = {
 .name  = "opencl",
 .flags = AV_PIX_FMT_FLAG_HWACCEL,
 },
+[AV_PIX_FMT_GRAYF32BE] = {
+.name = "grayf32be",
+.nb_components = 1,
+.log2_chroma_w = 0,
+.log2_chroma_h = 0,
+.comp = {
+{ 0, 4, 0, 0, 32, 3, 31, 1 },   /* Y */
+},
+.flags = AV_PIX_FMT_FLAG_BE | AV_PIX_FMT_FLAG_FLOAT,
+.alias = "yf32be",
+},
+[AV_PIX_FMT_GRAYF32LE] = {
+.name = "grayf32le",
+.nb_components = 1,
+.log2_chroma_w = 0,
+.log2_chroma_h = 0,
+.comp = {
+{ 0, 4, 0, 0, 32, 3, 31, 1 },   /* Y */
+},
+.flags = AV_PIX_FMT_FLAG_FLOAT,
+.alias = "yf32le",
+},
 };
 #if FF_API_PLUS1_MINUS1
 FF_ENABLE_DEPRECATION_WARNINGS
diff --git a/libavutil/pixfmt.h b/libavutil/pixfmt.h
index 2b3307845e..6815f8dc7b 100644
--- a/libavutil/pixfmt.h
+++ b/libavutil/pixfmt.h
@@ -337,6 +337,9 @@ enum AVPixelFormat {
 AV_PIX_FMT_GRAY14BE,   ///

[FFmpeg-cvslog] lavf/mov.c: Set start_time for all streams (in case of edit lists).

2018-08-11 Thread Sasi Inguva
ffmpeg | branch: master | Sasi Inguva  | Mon Aug  6 16:28:50 
2018 -0700| [12673bb25342c772e1bf5fd2adebd85f97dc616e] | committer: Michael 
Niedermayer

lavf/mov.c: Set start_time for all streams (in case of edit lists).

Fixes vorbis mp4 audio files, with edit list specified. Since
st->skip_samples is not set in case of vorbis , ffmpeg computes the
start_time as negative.

Signed-off-by: Sasi Inguva 
Signed-off-by: Michael Niedermayer 

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=12673bb25342c772e1bf5fd2adebd85f97dc616e
---

 libavformat/mov.c  | 4 ++--
 tests/fate/mov.mak | 5 +
 tests/ref/fate/mov-neg-firstpts-discard-vorbis | 3 +++
 3 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/libavformat/mov.c b/libavformat/mov.c
index 6885ef3b4b..c863047d79 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -3686,9 +3686,9 @@ static void mov_fix_index(MOVContext *mov, AVStream *st)
 st->index_entries[i].timestamp -= msc->min_corrected_pts;
 }
 }
-// Start time should be equal to zero or the duration of any empty 
edits.
-st->start_time = empty_edits_sum_duration;
 }
+// Start time should be equal to zero or the duration of any empty edits.
+st->start_time = empty_edits_sum_duration;
 
 // Update av stream length, if it ends up shorter than the track's media 
duration
 st->duration = FFMIN(st->duration, edit_list_dts_entry_end - start_dts);
diff --git a/tests/fate/mov.mak b/tests/fate/mov.mak
index 6f0e28d21e..3d9e4280bb 100644
--- a/tests/fate/mov.mak
+++ b/tests/fate/mov.mak
@@ -19,6 +19,7 @@ FATE_MOV = fate-mov-3elist \
fate-mov-stream-shorter-than-movie \
 
 FATE_MOV_FFPROBE = fate-mov-neg-firstpts-discard \
+   fate-mov-neg-firstpts-discard-vorbis \
fate-mov-aac-2048-priming \
fate-mov-zombie \
fate-mov-init-nonkeyframe \
@@ -89,6 +90,10 @@ fate-mov-bbi-elst-starts-b: CMD = framemd5 -flags +bitexact 
-acodec aac_fixed -i
 # Makes sure that the stream start_time is not negative when the first packet 
is a DISCARD packet with negative timestamp.
 fate-mov-neg-firstpts-discard: CMD = run ffprobe$(PROGSSUF)$(EXESUF) 
-show_entries stream=start_time -bitexact 
$(TARGET_SAMPLES)/mov/mov_neg_first_pts_discard.mov
 
+# Makes sure that the VORBIS audio stream start_time is not negative when the 
first few packets are DISCARD packets
+# with negative timestamps (skip_samples is not set for Vorbis, so ffmpeg 
computes start_time as negative if not specified by demuxer).
+fate-mov-neg-firstpts-discard-vorbis: CMD = run ffprobe$(PROGSSUF)$(EXESUF) 
-show_entries stream=start_time -bitexact 
$(TARGET_SAMPLES)/mov/mov_neg_first_pts_discard_vorbis.mp4
+
 # Makes sure that expected frames are generated for 
mov_neg_first_pts_discard.mov with -vsync 1
 fate-mov-neg-firstpts-discard-frames: CMD = framemd5 -flags +bitexact -i 
$(TARGET_SAMPLES)/mov/mov_neg_first_pts_discard.mov -vsync 1
 
diff --git a/tests/ref/fate/mov-neg-firstpts-discard-vorbis 
b/tests/ref/fate/mov-neg-firstpts-discard-vorbis
new file mode 100644
index 00..2e295e3b68
--- /dev/null
+++ b/tests/ref/fate/mov-neg-firstpts-discard-vorbis
@@ -0,0 +1,3 @@
+[STREAM]
+start_time=0.00
+[/STREAM]

___
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog