Re: [FFmpeg-devel] [PATCH 1/1] segafilm: fetch duration from the container

2018-04-19 Thread Misty De Meo
On Thu, Apr 19, 2018 at 8:31 PM, James Almer  wrote:
>
> > +film->sample_table[i].duration = AV_RB32([12]);
>
> While for video tracks this field seems to report the same packet
> durations that were being calculated pre patch, this field for audio
> tracks is always 1.
>
> Before this patch a codec copy of the sample logo-capcom.cpk in the FATE
> suite gave:
>
> 1,  0,  0,22048,44096, 0xafd250ae
> 0,  2,  2,2,11080, 0xac3a462b
> 0,  4,  4,2,11300, 0xd8ee7f3e
> 0,  6,  6,2,21612, 0x73c3a3f9, F=0x0
> 0,  8,  8,2,21628, 0x00a5b4b9, F=0x0
> 0, 10, 10,2,14772, 0x1332b44f
> 0, 12, 12,2,14744, 0x5ce5d59b
> 0, 14, 14,2,14736, 0xd5ac2877
> 1,  22048,  22048,11028,22056, 0xe08a0f01
>
> Whereas after applying it becomes:
>
> 1,  0,  0,1,44096, 0xafd250ae
> 0,  2,  2,2,11080, 0xac3a462b
> 0,  4,  4,2,11300, 0xd8ee7f3e
> 0,  6,  6,2,21612, 0x73c3a3f9, F=0x0
> 0,  8,  8,2,21628, 0x00a5b4b9, F=0x0
> 0, 10, 10,2,14772, 0x1332b44f
> 0, 12, 12,2,14744, 0x5ce5d59b
> 0, 14, 14,2,14736, 0xd5ac2877
> 1,  22048,  22048,1,22056, 0xe08a0f01
>
> For reference, decoding it always gives the following with or without
> this patch:
>
> 0,  0,  0,1,   215040, 0x067c5362
> 1,  0,  0,22048,88192, 0x23bb50ae
> 0,  2,  2,1,   215040, 0xd9eacb98
> 0,  4,  4,1,   215040, 0x3c8a4cbd
> 0,  6,  6,1,   215040, 0xbdf996e1
> 0,  8,  8,1,   215040, 0x1b7fa123
> 0, 10, 10,1,   215040, 0x834b4a8d
> 0, 12, 12,1,   215040, 0xf4b1bebe
> 0, 14, 14,1,   215040, 0x088c3802
> 1,  22048,  22048,11028,44112, 0x79600f01
>
> Is this change desired/intended?

This is actually intended; since that value is what's in the original
container, it's what should get passed through, especially for stream
copying back into a new FILM file.

>
> Also, unrelated to this patch, but as you can see decoding outputs one
> extra video frame at the beginning that codec copy doesn't. this is
> because packet keyframes are being set wrong: A 0 in the top bit of the
> sample info dword on each sample table entry signals an Intra coded
> frame, whereas 1 signals an Inter coded frame. The demuxer is assuming
> the opposite.

Here's a thread with context on the change to the intra setting:
http://ffmpeg.org/pipermail/ffmpeg-devel/2018-March/227014.html

The keyframe logic was intentionally inverted in
cfe1a9d311de6c36641cf295004cdbc77d7b600c
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/1] Add Sega FILM muxer

2018-04-07 Thread Misty De Meo
On Thu, Apr 5, 2018 at 2:06 PM, Josh de Kock  wrote:
> Thanks, pushed. I also clarified with wm4 on IRC that while he was against
> it he wasn't blocking the muxer if someone else pushes it.

Thank you!
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 0/1] Add Sega FILM muxer

2018-03-22 Thread Misty De Meo
On Thu, Mar 22, 2018 at 3:43 AM, wm4  wrote:
> Why?

Mainly to modify existing videos or encode new videos for Saturn
games. It's particularly useful for fan translation - to mux in new
audio, or encode new video for things like credits sequences.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] avformat/segafilm - fix keyframe detection and set packet, flags

2018-03-21 Thread Misty De Meo
On Wed, Mar 21, 2018 at 1:32 PM, Carl Eugen Hoyos  wrote:
> 2018-03-21 14:37 GMT+01:00, Gyan Doshi :
> Can you comment on why this 15-year old code was wrong?

I think it was de facto unused before now. Since it wasn't passed
through to AVPacket it wasn't used by many things, and the Cinepak
decoder determines keyframe status by looking at the Cinepak packet
header and ignores what the container says.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/1] mpeg: add experimental support for PSMF audio.

2018-01-05 Thread Misty De Meo
Sorry about that - that was the placeholder title of a commit I
squashed into the mpeg commit, and forgot to remove when rebasing.
I'll remove it from the commit message.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/1] mpeg: add experimental support for PSMF audio.

2018-01-05 Thread Misty De Meo
> so this is unfinished code that work in progress ?
> if so, what is missing ?
> if not, then please write a better commit message

Sorry about that - that was the placeholder title of a commit I
squashed into the mpeg commit, and forgot to remove when rebasing.
I'll remove it from the commit message.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/6] mpeg: add experimental support for PSMF audio.

2017-12-26 Thread Misty De Meo
I originally left this patch alone since it was another person's
commit; I can squash the fixes for that into this commit if you
prefer, though.

On Tue, Dec 26, 2017 at 8:39 AM, Michael Niedermayer
 wrote:
> On Mon, Dec 25, 2017 at 10:28:30AM +0800, mi...@brew.sh wrote:
>> From: Maxim Poliakovski 
>>
>> ---
>>  libavcodec/Makefile|   1 +
>>  libavcodec/allcodecs.c |   1 +
>>  libavcodec/atrac3plus_parser.c | 153 
>> +
>>  libavformat/mpeg.c |  27 +++-
>>  4 files changed, 181 insertions(+), 1 deletion(-)
>>  create mode 100644 libavcodec/atrac3plus_parser.c
>
> This fails to build without the next patch
>
> libavcodec/atrac3plus_parser.c: In function ‘parse_sound_frame_header’:
> libavcodec/atrac3plus_parser.c:41:22: error: ‘ff_oma_srate_tab’ undeclared 
> (first use in this function)
>  c->sample_rate = ff_oma_srate_tab[(atrac_config >> 13) & 7] * 100;
>   ^
> libavcodec/atrac3plus_parser.c:41:22: note: each undeclared identifier is 
> reported only once for each function it appears in
> libavcodec/atrac3plus_parser.c: In function ‘ff_atrac3p_parse’:
> libavcodec/atrac3plus_parser.c:92:32: warning: format ‘%d’ expects argument 
> of type ‘int’, but argument 4 has type ‘size_t’ [-Wformat=]
> bytes_remain, buf_size);
> ^
> libavcodec/atrac3plus_parser.c:123:27: error: ‘ff_oma_chid_to_num_channels’ 
> undeclared (first use in this function)
>  avctx->channels   = ff_oma_chid_to_num_channels[ctx->channel_id 
> - 1];
>^
> libavcodec/atrac3plus_parser.c:124:33: error: ‘ff_oma_chid_to_native_layout’ 
> undeclared (first use in this function)
>  avctx->channel_layout = ff_oma_chid_to_native_layout[ctx->channel_id 
> - 1];
>  ^
> make: *** [libavcodec/atrac3plus_parser.o] Error 1
> make: *** Waiting for unfinished jobs
>
> [...]
> --
> Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> During times of universal deceit, telling the truth becomes a
> revolutionary act. -- George Orwell
>
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/6] mpeg: add experimental support for PSMF audio.

2017-12-25 Thread Misty De Meo
On Tue, Dec 26, 2017 at 8:42 AM, Michael Niedermayer
 wrote:
> returning errors from the parse function will cause assertion failure at:
>
> Assertion index > -0x2000 failed at libavcodec/parser.c:185
>
> [...]

What would be the preferred way to handle that?
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/6] mpeg: add experimental support for PSMF audio.

2017-12-25 Thread Misty De Meo
On Tue, Dec 26, 2017 at 8:39 AM, Michael Niedermayer
 wrote:
> This fails to build without the next patch

I originally left this patch alone since it was another person's
commit; I can squash the fixes for that into this commit if you
prefer, though.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel