Re: [FFmpeg-devel] [PATCH V3] [RFC] GSoC: FLIF16 Image format parser

2020-03-14 Thread Anamitra Ghorui
Hello,

March 15, 2020 2:15 AM, "Jai Luthra"  wrote:
>On Fri, Mar 06, 2020 at 06:10:04PM +, Anamitra Ghorui wrote:
>>The parser has been tested and is able to correctly identify the start
>>of the compressed bitstream. The patch has a set of printf statements
>>which print a "tracing table" of the behaviour. Upon Nicolas George's
>>suggestion I have made it so that the varints are read into a uint64_t.
>>Hence the varints are limited in the range 0 to 2^64 - 1.

>Yes afaics parser does not generally return errors. Usually the parser splits 
>the frames out if it is able to, and the decoder verifies if something is 
>wrong within the packet bitstream.
>
>I am not certain how this should be handled here as you plan to do entropy 
>decoding within the parser.
>
>Parser's ret value being < 0 usually implies that frame start was in previous 
>packet, but look around other parsers and ask in #ffmpeg-devel if your 
>approach is feasible.

The main reason I was trying to decode the bitstream in the parser itself was
that the specification doesn't mention anything about the size of the compressed
bitstream from what I can see. We however can read through the second/image 
description header and the uncompressed length of the pixel data is already 
known. 

Another approach I would suggest is simply to send the bytes over to the output 
buffer unaltered without doing anything, but then there is no need
to even really have the parser aside from just being congruent to the standard 
decoding procedure given in the example code (decode_video.c), and finding 
the start of the bitstream.

The decoder will then throw a series of AVERROR(EAGAIN)s while the bitstream is
being read.

I will ask around.

>>Now comes the part of decompressing the bitstream and finding the bounds
>>of the data. I haven't yet properly gone through the reference
>>implementation due to a lack of time (I will have now), but I'm thinking
>>of defining a few functions:
>>
>>int ff_flif16_read_rac(uint8_t *buf, unsigned int buf_size,
>>  unsinged int offset,
>>  FLIF16ChanceTable chance);
>>int ff_flif16_read_uni_int(int min, int max);
>>int ff_flif16_read_nz_int(int min, int max,  FLIF16ChanceTable context);
>>int ff_flif16_read_gnz_int(int min, int max, FLIF16ChanceTable context);
>>(...)
>
>I haven't heard from the other applicant who was working on the entropy 
>decoding task, so I would suggest you can go ahead with implementing this. I 
>think you may be able to use/modify the existing range coder ffmpeg module.

I see, but I am a bit confused about the tasks that we are to complete during 
the official work period and now. Where should I stop?

>>
>>The decoder itself will not handle decompressing or decoding the
>>bitstream, rather we will alter the buffer to add in the decompressed
>>bitstream, then run it through the parser and add it to the AVPacket,
>>and finally pass it to the decoder. The decoder will then decode all
>>the frames from that single packet.
>>
>
>
>>+typedef struct FLIF16ParseContext {
>>+ParseContext pc;
>>+int state;  ///< The section of the file the parser is in 
>>currently.
>>+unsigned int index; ///< An index based on the current state.
>>+uint8_t iac;///< Interlaced, animated, color palette info
>
>For testing this is good enough, but I think it would be a better idea to have 
>separate fields in the context for interlaced/animated/color pallete etc. so 
>that you don't need to do bitshifts everywhere you need to use them as done 
>below.

Okay

Regards,
Anamitra

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

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

Re: [FFmpeg-devel] [PATCH] doc/muxers: add missing MOV muxer options

2020-03-14 Thread Gyan Doshi



On 15-03-2020 12:47 am, Lou Logan wrote:

On Fri, Mar 13, 2020, at 10:23 PM, Gyan Doshi wrote:

Do you mind if I continue with my own patch? I started reviewing this
and noticed that many of the option description should have caveats
since they can be silently (i.e. unlogged) modified based on other
options. I think it's best for me to walk the code and check.

I don't mind. I'll drop this patch.

While you're editing the MOV muxer section could you add a sentence
explaining the -/+ prefix and how to chain multiple movflags together?
It's not mentioned anywhere, AFAIK.


That belongs on the utils doc page, since it is a feature of the option 
parser - it is useful in multiple places e.g. -fflags


Will do.

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

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

Re: [FFmpeg-devel] [PATCH 09/18] vp3: eliminate copy_fields

2020-03-14 Thread Peter Ross
On Fri, Mar 13, 2020 at 11:28:41AM +0100, Anton Khirnov wrote:
> It is very fragile against fields being moved and hides what is actually
> being copied. Copy all the fields explicitly instead.
> ---
>  libavcodec/vp3.c | 12 +---
>  1 file changed, 5 insertions(+), 7 deletions(-)
> 
> diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
> index 0a8c8ad286..81d0b9b7bb 100644
> --- a/libavcodec/vp3.c
> +++ b/libavcodec/vp3.c
> @@ -2590,10 +2590,6 @@ static int vp3_update_thread_context(AVCodecContext 
> *dst, const AVCodecContext *
>  Vp3DecodeContext *s = dst->priv_data, *s1 = src->priv_data;
>  int qps_changed = 0, i, err;
>  
> -#define copy_fields(to, from, start_field, end_field)
>  \
> -memcpy(>start_field, >start_field, 
>  \
> -   (char *) >end_field - (char *) >start_field)
> -
>  if (!s1->current_frame.f->data[0] ||
>  s->width != s1->width || s->height != s1->height) {
>  if (s != s1)
> @@ -2620,9 +2616,11 @@ static int vp3_update_thread_context(AVCodecContext 
> *dst, const AVCodecContext *
>  memcpy(>bounding_values_array, >bounding_values_array,
> sizeof(s->bounding_values_array));
>  
> -if (qps_changed)
> -copy_fields(s, s1, qps, superblock_count);
> -#undef copy_fields
> +if (qps_changed) {
> +memcpy(s->qps,  s1->qps,  sizeof(s->qps));
> +memcpy(s->last_qps, s1->last_qps, sizeof(s->last_qps));
> +s->nqps = s1->nqps;
> +}
>  }
>  
>  return update_frames(dst);

Looks good.

-- Peter
(A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH v2 6/7] avformat/mxfenc: allow all frame rates if -strict mode is set to unofficial or lower

2020-03-14 Thread Marton Balint



On Sat, 14 Mar 2020, Tomas Härdin wrote:


tor 2020-03-12 klockan 22:21 +0100 skrev Marton Balint:


On Sat, 7 Mar 2020, Tomas Härdin wrote:

> tor 2020-03-05 klockan 22:56 +0100 skrev Marton Balint:
> > There was no consensus wheter or not to allow unofficial frame rates due to
> > possible interoperability issues, a compromise is to only allow it if 
-strict
> > mode is set to unofficial.
> > 
> > Signed-off-by: Marton Balint 

> > ---
> >  libavformat/mxfenc.c | 8 ++--
> >  1 file changed, 6 insertions(+), 2 deletions(-)
> > 
> > diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c

> > index 51e2dc5f31..6279ba9d6d 100644
> > --- a/libavformat/mxfenc.c
> > +++ b/libavformat/mxfenc.c
> > @@ -2413,8 +2413,12 @@ static int mxf_init_timecode(AVFormatContext *s, 
AVStream *st, AVRational tbc)
> >  AVDictionaryEntry *tcr = av_dict_get(s->metadata, "timecode", NULL, 0);
> > 
> >  if (!ff_mxf_get_content_package_rate(tbc)) {

> > -av_log(s, AV_LOG_ERROR, "Unsupported frame rate %d/%d\n", tbc.den, 
tbc.num);
> > -return AVERROR(EINVAL);
> > +if (s->strict_std_compliance > FF_COMPLIANCE_UNOFFICIAL) {
> > +av_log(s, AV_LOG_ERROR, "Unsupported frame rate %d/%d. Set -strict 
option to 'unofficial' or lower in order to allow it!\n", tbc.den, tbc.num);
> > +return AVERROR(EINVAL);
> > +} else {
> > +av_log(s, AV_LOG_WARNING, "Unofficial frame rate %d/%d.\n", 
tbc.den, tbc.num);
> > +}
> 
> This can work. That way we make it clear to users that here be dragons


Thanks, it seems there are no further comments for patches 1-6, so I plan 
to apply them soon.





Thanks, applied.

Regards,
Marton
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH 03/17] avformat/smoothstreaming: Fix memleaks on errors

2020-03-14 Thread Michael Niedermayer
On Thu, Dec 26, 2019 at 11:53:28AM +0100, Andreas Rheinhardt wrote:
> If an AVFormatContext could be allocated, but white-/blacklists couldn't
> be copied, the AVFormatContext would leak as it was only accessible
> through a local variable that goes out of scope when one goes to fail.
> 
> Furthermore, in case writing a header of a submuxer failed, the options
> used for said call could leak.
> 
> Both of these memleaks have been fixed.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/smoothstreamingenc.c | 8 
>  1 file changed, 4 insertions(+), 4 deletions(-)

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The bravest are surely those who have the clearest vision
of what is before them, glory and danger alike, and yet
notwithstanding go out to meet it. -- Thucydides


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH 29/30] avformat/matroskaenc: Check BlockAdditional size before use

2020-03-14 Thread Michael Niedermayer
On Sun, Jan 26, 2020 at 06:10:27AM +0100, Andreas Rheinhardt wrote:
> Don't read a 64bit number before having checked that the data is at
> least 8 bytes long.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/matroskaenc.c | 10 +++---
>  1 file changed, 7 insertions(+), 3 deletions(-)

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Old school: Use the lowest level language in which you can solve the problem
conveniently.
New school: Use the highest level language in which the latest supercomputer
can solve the problem without the user falling asleep waiting.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH] avformat/nutenc: Drop redundant frees

2020-03-14 Thread Michael Niedermayer
On Sat, Mar 14, 2020 at 05:32:17PM +0100, Andreas Rheinhardt wrote:
> Should writing the header fail, the allocations already performed will
> be freed during deinit so remove the frees in nut_write_header().
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/nutenc.c | 6 +-
>  1 file changed, 1 insertion(+), 5 deletions(-)

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Asymptotically faster algorithms should always be preferred if you have
asymptotical amounts of data


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH] avformat/avienc: Use AV_STRINGIFY for compile time constant

2020-03-14 Thread Michael Niedermayer
On Sat, Mar 14, 2020 at 06:08:45PM +0100, Andreas Rheinhardt wrote:
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/avienc.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Many things microsoft did are stupid, but not doing something just because
microsoft did it is even more stupid. If everything ms did were stupid they
would be bankrupt already.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH V3] [RFC] GSoC: FLIF16 Image format parser

2020-03-14 Thread Jai Luthra

Hi Anamitra,

Good progres on the parser, I tested it on the samples you provided, lgtm. 
Comments inline.


On Fri, Mar 06, 2020 at 06:10:04PM +, Anamitra Ghorui wrote:

The parser has been tested and is able to correctly identify the start
of the compressed bitstream. The patch has a set of printf statements
which print a "tracing table" of the behaviour. Upon Nicolas George's
suggestion I have made it so that the varints are read into a uint64_t.
Hence the varints are limited in the range 0 to 2^64 - 1.
The test cases are as follows:
1. 1x1 png image (a.flif)
2. 1x1 png image with dummy EXIF data (a1.flif)
3. 2x2 png image (b.flif)
4. 300x200 png image (d.flif)
5. 10x10 gif image, 2 frames (f.flif)
These have been provided as an attachment.
The way I have used AVERROR in the parser may be wrong.

The testing code has been adapted from:
https://ffmpeg.org/doxygen/trunk/decode_video_8c-example.html
The concerned part is (available as attachment):
...
while (!feof(f)) {
   /* read raw data from the input file */
   data_size = fread(inbuf, 1, INBUF_SIZE, f);
   if (!data_size)
   break;
   /* use the parser to split the data into frames */
   data = inbuf;
   while (data_size > 0) {
   ret = av_parser_parse2(parser, c, >data, >size,
  data, data_size, AV_NOPTS_VALUE, 
AV_NOPTS_VALUE, 0);
   if (ret < 0) {
   fprintf(stderr, "Error while parsing\n");
   exit(1);
   }
   data  += ret;
   data_size -= ret;
   if (pkt->size > 0)
   {
   printf("Reached bitstream at 0x%x (%dd)\n", pkt->size,
  pkt->size);
   goto end;
   }
   }
   }
   end:
...



Yes afaics parser does not generally return errors. Usually the parser splits 
the frames out if it is able to, and the decoder verifies if something is 
wrong within the packet bitstream.


I am not certain how this should be handled here as you plan to do entropy 
decoding within the parser.


Parser's ret value being < 0 usually implies that frame start was in previous 
packet, but look around other parsers and ask in #ffmpeg-devel if your 
approach is feasible.



Now comes the part of decompressing the bitstream and finding the bounds
of the data. I haven't yet properly gone through the reference
implementation due to a lack of time (I will have now), but I'm thinking
of defining a few functions:

int ff_flif16_read_rac(uint8_t *buf, unsigned int buf_size,
unsinged int offset,
FLIF16ChanceTable chance);
int ff_flif16_read_uni_int(int min, int max);
int ff_flif16_read_nz_int(int min, int max,  FLIF16ChanceTable context);
int ff_flif16_read_gnz_int(int min, int max, FLIF16ChanceTable context);
(...)


I haven't heard from the other applicant who was working on the entropy 
decoding task, so I would suggest you can go ahead with implementing this. I 
think you may be able to use/modify the existing range coder ffmpeg module.




The decoder itself will not handle decompressing or decoding the
bitstream, rather we will alter the buffer to add in the decompressed
bitstream, then run it through the parser and add it to the AVPacket,
and finally pass it to the decoder. The decoder will then decode all
the frames from that single packet.





+typedef struct FLIF16ParseContext {
+ParseContext pc;
+int state;  ///< The section of the file the parser is in 
currently.
+unsigned int index; ///< An index based on the current state.
+uint8_t iac;///< Interlaced, animated, color palette info


For testing this is good enough, but I think it would be a better idea to have 
separate fields in the context for interlaced/animated/color pallete etc. so 
that you don't need to do bitshifts everywhere you need to use them as done 
below.



+uint8_t varint; ///< Number of varints to process in sequence
+uint64_t width;
+uint64_t height;
+uint64_t frames;
+uint64_t meta;  ///< Size of a meta chunk
+uint64_t count;
+} FLIF16ParseContext;
+
+static int flif16_find_frame(FLIF16ParseContext *f, const uint8_t *buf,
+ int buf_size)
+{
+int next = END_NOT_FOUND;
+int index;
+
+printf("pos\tfindex\tstate\tval\tw\th\tframes\tmeta\tvarintn\n");
+for (index = 0; index < buf_size; index++) {
+printf("%d\t%d\t%d\t0x%x\t0x%lx\t0x%lx\t%lx\t%lx\t%d\n", index,
+   f->index, f->state, buf[index], f->width, f->height, f->frames,
+   f->meta, f->varint);
+if (!f->state) {
+if (!memcmp(flif16_header, buf + index, 4))
+f->state = FLIF16_HEADER;
+++f->index;
+} else if (f->state == FLIF16_HEADER) {
+if (f->index == 3 + 1) { // Interlaced/animated/color palette info
+f->iac = 

Re: [FFmpeg-devel] [PATCH] doc/muxers: add missing MOV muxer options

2020-03-14 Thread Lou Logan
On Fri, Mar 13, 2020, at 10:23 PM, Gyan Doshi wrote:
>
> Do you mind if I continue with my own patch? I started reviewing this 
> and noticed that many of the option description should have caveats 
> since they can be silently (i.e. unlogged) modified based on other 
> options. I think it's best for me to walk the code and check.

I don't mind. I'll drop this patch.

While you're editing the MOV muxer section could you add a sentence
explaining the -/+ prefix and how to chain multiple movflags together?
It's not mentioned anywhere, AFAIK.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH 5/5] avformat/mpeg: Don't use unintialized value

2020-03-14 Thread Andreas Rheinhardt
Andreas Rheinhardt:
> On Sun, Jan 19, 2020 at 3:44 PM Andreas Rheinhardt <
> andreas.rheinha...@gmail.com> wrote:
> 
>> Michael Niedermayer:
>>> On Tue, Oct 22, 2019 at 03:16:45PM +0200, Andreas Rheinhardt wrote:
 vobsub_read_packet() didn't check whether an index in array of AVPackets
 was valid and therefore used uninitialized values.

 Signed-off-by: Andreas Rheinhardt 
 ---
 Actually I only wanted to use Valgrind to check for memleaks...

  libavformat/mpeg.c | 4 
  1 file changed, 4 insertions(+)

 diff --git a/libavformat/mpeg.c b/libavformat/mpeg.c
 index 73ade71d95..474afd06b9 100644
 --- a/libavformat/mpeg.c
 +++ b/libavformat/mpeg.c
 @@ -930,6 +930,10 @@ static int vobsub_read_packet(AVFormatContext *s,
>> AVPacket *pkt)
  FFDemuxSubtitlesQueue *tmpq = >q[i];
  int64_t ts;
  av_assert0(tmpq->nb_subs);
 +
 +if (tmpq->current_sub_idx >= tmpq->nb_subs)
 +continue;
>>>
>>> How can this issue be reproduced ?
>>>
>>> thx
>>>
>>> [...]
>>
>> Read a VobSub subtitle till the end:
>> ffmpeg -i  -c copy -f null -
>>
>> - Andreas
>>
> 
> Ping.
> 
> - Andreas
> 
Ping.

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

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

Re: [FFmpeg-devel] [PATCH] avformat/mxfenc: Reorder fields in MXFIndexEntry to make it smaller

2020-03-14 Thread Michael Niedermayer
On Sat, Mar 14, 2020 at 11:21:51AM +0100, Tomas Härdin wrote:
> fre 2020-03-13 klockan 11:18 +0100 skrev Andreas Rheinhardt:
> > Signed-off-by: Andreas Rheinhardt 
> > ---
> >  libavformat/mxfenc.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c
> > index 5e0dc0e889..55c715d776 100644
> > --- a/libavformat/mxfenc.c
> > +++ b/libavformat/mxfenc.c
> > @@ -72,10 +72,10 @@ typedef struct MXFLocalTagPair {
> >  } MXFLocalTagPair;
> >  
> >  typedef struct MXFIndexEntry {
> > -uint8_t flags;
> >  uint64_t offset;
> >  unsigned slice_offset; ///< offset of audio slice
> >  uint16_t temporal_ref;
> > +uint8_t flags;
> >  } MXFIndexEntry;
> >  
> >  typedef struct MXFStreamContext {
> 
> Good catch. Looks fine. I took a look at the fields in the struck, and
> it doesn't seem like we can shrink any of them without limiting what
> the muxer can currently do.

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

If you fake or manipulate statistics in a paper in physics you will never
get a job again.
If you fake or manipulate statistics in a paper in medicin you will get
a job for life at the pharma industry.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH] libavcodec, libpostproc: Remove outcommented START/STOP_TIMER

2020-03-14 Thread Michael Niedermayer
On Fri, Mar 13, 2020 at 02:06:01PM +0100, Andreas Rheinhardt wrote:
> as well as includes of libavutil/timer.h.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavcodec/cabac.c |  1 -
>  libavcodec/dnxhddec.c  |  3 --
>  libavcodec/dnxhdenc.c  |  4 +-
>  libavcodec/ffv1.c  |  1 -
>  libavcodec/ffv1.h  |  1 -
>  libavcodec/ffv1dec.c   |  3 --
>  libavcodec/ffv1enc.c   |  3 --
>  libavcodec/h264_cabac.c|  3 --
>  libavcodec/h264_picture.c  |  1 -
>  libavcodec/h264_slice.c|  3 --
>  libavcodec/h264dec.c   |  1 -
>  libavcodec/ivi.c   |  5 --
>  libavcodec/mpegvideo.c |  4 --
>  libavcodec/mpegvideo_enc.c | 76 ++
>  libpostproc/postprocess.c  |  7 +--
>  libpostproc/postprocess_template.c |  8 +---
>  16 files changed, 6 insertions(+), 118 deletions(-)

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

"You are 36 times more likely to die in a bathtub than at the hands of a
terrorist. Also, you are 2.5 times more likely to become a president and
2 times more likely to become an astronaut, than to die in a terrorist
attack." -- Thoughty2



signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH 1/2] avformat/mux: Remove redundant checks for write errors

2020-03-14 Thread Michael Niedermayer
On Thu, Mar 12, 2020 at 06:54:07PM +0100, Andreas Rheinhardt wrote:
> If writing a packet didn't directly return an error, the AVIOContext's
> error flag is checked for errors (if existing) by write_packet(). And if
> write_packet() didn't indicate an error, its callers checked the error
> flag of the AVIOContext (if existing). The latter check is redundant.
> 
> The reason for checking twice lies in the FFmpeg-Libav split: The check
> in write_packet() has been added in 9ad1e0c1 in Libav. FFmpeg already
> had the other checks (since aec9390a), but when 9ad1e0c1 was merged
> (in 1f1c1008), no one noticed the redundant checks.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/mux.c | 6 --
>  1 file changed, 6 deletions(-)

will apply the 2 patches of the set

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

When the tyrant has disposed of foreign enemies by conquest or treaty, and
there is nothing more to fear from them, then he is always stirring up
some war or other, in order that the people may require a leader. -- Plato


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

[FFmpeg-devel] [PATCH] avformat/avienc: Use AV_STRINGIFY for compile time constant

2020-03-14 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt 
---
 libavformat/avienc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/avienc.c b/libavformat/avienc.c
index 07e1c3319e..297d5b8964 100644
--- a/libavformat/avienc.c
+++ b/libavformat/avienc.c
@@ -268,8 +268,8 @@ static int avi_write_header(AVFormatContext *s)
 int padding;
 
 if (s->nb_streams > AVI_MAX_STREAM_COUNT) {
-av_log(s, AV_LOG_ERROR, "AVI does not support >%d streams\n",
-   AVI_MAX_STREAM_COUNT);
+av_log(s, AV_LOG_ERROR, "AVI does not support "
+   ">"AV_STRINGIFY(AVI_MAX_STREAM_COUNT)" streams\n");
 return AVERROR(EINVAL);
 }
 
-- 
2.20.1

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

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

Re: [FFmpeg-devel] [PATCH v3 7/7] avformat/audiointerleave: use a fixed frame duration for non-audio packets

2020-03-14 Thread Marton Balint



On Sat, 14 Mar 2020, Tomas Härdin wrote:


fre 2020-03-13 klockan 02:31 +0100 skrev Marton Balint:

The packet durations might not be set properly which can cause the MXF muxer
to write more than one packet of a stream to an edit unit messing up the
constant byte per element index...


Shouldn't this be fixed "higher up"?


It should also be fixed higher up, but the MXF muxer should never write 
broken files, so it should be fixed here as well, either with a warning, 
and discarding input timestamps/durations or rejecting such attempts 
completely.





Also warn the user if the incoming DTS is not increasing by frame duration
because in that case A-V sync issues can occur because of the DTS rewriting.


I'm not a huge fan of this, shouldn't we investigate why this happens
instead? DTS being non-monotonic is a big deal


fate-copy-trac4914 is an example of this, it is a stream copy for video.

Regards,
Marton
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

[FFmpeg-devel] [PATCH] avformat/nutenc: Drop redundant frees

2020-03-14 Thread Andreas Rheinhardt
Should writing the header fail, the allocations already performed will
be freed during deinit so remove the frees in nut_write_header().

Signed-off-by: Andreas Rheinhardt 
---
 libavformat/nutenc.c | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/libavformat/nutenc.c b/libavformat/nutenc.c
index 44773924dd..1d48625815 100644
--- a/libavformat/nutenc.c
+++ b/libavformat/nutenc.c
@@ -703,12 +703,8 @@ static int nut_write_header(AVFormatContext *s)
 nut->chapter  = av_calloc(s->nb_chapters, sizeof(*nut->chapter));
 nut->time_base= av_calloc(s->nb_streams +
   s->nb_chapters, sizeof(*nut->time_base));
-if (!nut->stream || !nut->chapter || !nut->time_base) {
-av_freep(>stream);
-av_freep(>chapter);
-av_freep(>time_base);
+if (!nut->stream || !nut->chapter || !nut->time_base)
 return AVERROR(ENOMEM);
-}
 
 for (i = 0; i < s->nb_streams; i++) {
 AVStream *st = s->streams[i];
-- 
2.20.1

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

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

[FFmpeg-devel] [PATCH] Encapsulation func to get width and height most of mb's checked oper are defined in mpegutils' marcos, so mb's checked oper about width/height should be put it together with oth

2020-03-14 Thread numberwolf
Reviewed-by: Carl Eugen Hoyos 
Signed-off-by: numberwolf 
---
 libavcodec/mpegutils.c | 4 ++--
 libavcodec/mpegutils.h | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mpegutils.c b/libavcodec/mpegutils.c
index c0ee3aa..819293c 100644
--- a/libavcodec/mpegutils.c
+++ b/libavcodec/mpegutils.c
@@ -34,8 +34,8 @@ static int add_mb(AVMotionVector *mb, uint32_t mb_type,
   int motion_x, int motion_y, int motion_scale,
   int direction)
 {
-mb->w = IS_8X8(mb_type) || IS_8X16(mb_type) ? 8 : 16;
-mb->h = IS_8X8(mb_type) || IS_16X8(mb_type) ? 8 : 16;
+mb->w = MB_SIZE_WIDTH(mb_type);
+mb->h = MB_SIZE_HEIGHT(mb_type);
 mb->motion_x = motion_x;
 mb->motion_y = motion_y;
 mb->motion_scale = motion_scale;
diff --git a/libavcodec/mpegutils.h b/libavcodec/mpegutils.h
index 1ed21c1..ed59716 100644
--- a/libavcodec/mpegutils.h
+++ b/libavcodec/mpegutils.h
@@ -95,6 +95,9 @@
 #define IS_QUANT(a)  ((a) & MB_TYPE_QUANT)
 #define IS_DIR(a, part, list) ((a) & (MB_TYPE_P0L0 << ((part) + 2 * (list
 
+#define MB_SIZE_WIDTH(a)  (((a) & MB_TYPE_8x8) || ((a) & MB_TYPE_8x16)) ? 
8 : 16
+#define MB_SIZE_HEIGHT(a) (((a) & MB_TYPE_8x8) || ((a) & MB_TYPE_16x8)) ? 
8 : 16
+
 // does this mb use listX, note does not work if subMBs
 #define USES_LIST(a, list) ((a) & ((MB_TYPE_P0L0 | MB_TYPE_P1L0) << (2 * 
(list
 
-- 
2.17.2 (Apple Git-113)

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

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

[FFmpeg-devel] [PATCH] remove useless mv The function which add motion info, but do not need motionless vectors, its useless. And, when u export mvs , loop oper will spend many times for useless vecto

2020-03-14 Thread numberwolf
Signed-off-by: numberwolf 
---
 libavcodec/mpegutils.c | 10 --
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mpegutils.c b/libavcodec/mpegutils.c
index c0ee3aa..148d3e7 100644
--- a/libavcodec/mpegutils.c
+++ b/libavcodec/mpegutils.c
@@ -34,6 +34,12 @@ static int add_mb(AVMotionVector *mb, uint32_t mb_type,
   int motion_x, int motion_y, int motion_scale,
   int direction)
 {
+int src_x = dst_x + motion_x / motion_scale;
+int src_y = dst_y + motion_y / motion_scale;
+
+if (src_x == dst_x && src_y == dst_y) {
+return 0;
+}
 mb->w = IS_8X8(mb_type) || IS_8X16(mb_type) ? 8 : 16;
 mb->h = IS_8X8(mb_type) || IS_16X8(mb_type) ? 8 : 16;
 mb->motion_x = motion_x;
@@ -41,8 +47,8 @@ static int add_mb(AVMotionVector *mb, uint32_t mb_type,
 mb->motion_scale = motion_scale;
 mb->dst_x = dst_x;
 mb->dst_y = dst_y;
-mb->src_x = dst_x + motion_x / motion_scale;
-mb->src_y = dst_y + motion_y / motion_scale;
+mb->src_x = src_x;
+mb->src_y = src_y;
 mb->source = direction ? 1 : -1;
 mb->flags = 0; // XXX: does mb_type contain extra information that could 
be exported here?
 return 1;
-- 
2.17.2 (Apple Git-113)

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

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

Re: [FFmpeg-devel] [PATCH]lavf/tty: Reduce probe score and fix ffmetadata auto-detection

2020-03-14 Thread Carl Eugen Hoyos
Am Fr., 13. März 2020 um 00:54 Uhr schrieb Carl Eugen Hoyos
:

> Attached patch fixes ticket #8568 for me.

Patch applied.

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH v4 1/3] avcodec/v4l2_m2m_enc: Reduce log verbosity for some params

2020-03-14 Thread Andriy Gelman
On Sun, 23. Feb 13:47, Andriy Gelman wrote:
> From: Andriy Gelman 
> 
> Currently the user gets unhelpful warnings when some default parameters
> are not supported by the device. The verbosity of these log messages has
> been changed to AV_LOG_DEBUG.
> 
> Signed-off-by: Andriy Gelman 
> ---
>  libavcodec/v4l2_m2m_enc.c | 36 +---
>  1 file changed, 21 insertions(+), 15 deletions(-)
> 
> diff --git a/libavcodec/v4l2_m2m_enc.c b/libavcodec/v4l2_m2m_enc.c
> index c9f1741bfd0..859feb7bde7 100644
> --- a/libavcodec/v4l2_m2m_enc.c
> +++ b/libavcodec/v4l2_m2m_enc.c
> @@ -47,7 +47,7 @@ static inline void v4l2_set_timeperframe(V4L2m2mContext *s, 
> unsigned int num, un
>  av_log(s->avctx, AV_LOG_WARNING, "Failed to set timeperframe");
>  }
>  
> -static inline void v4l2_set_ext_ctrl(V4L2m2mContext *s, unsigned int id, 
> signed int value, const char *name)
> +static inline void v4l2_set_ext_ctrl(V4L2m2mContext *s, unsigned int id, 
> signed int value, const char *name, int log_warning)
>  {
>  struct v4l2_ext_controls ctrls = { { 0 } };
>  struct v4l2_ext_control ctrl = { 0 };
> @@ -62,12 +62,13 @@ static inline void v4l2_set_ext_ctrl(V4L2m2mContext *s, 
> unsigned int id, signed
>  ctrl.id = id;
>  
>  if (ioctl(s->fd, VIDIOC_S_EXT_CTRLS, ) < 0)
> -av_log(s->avctx, AV_LOG_WARNING, "Failed to set %s: %s\n", name, 
> strerror(errno));
> +av_log(s->avctx, log_warning || errno != EINVAL ? AV_LOG_WARNING : 
> AV_LOG_DEBUG,
> +   "Failed to set %s: %s\n", name, strerror(errno));
>  else
>  av_log(s->avctx, AV_LOG_DEBUG, "Encoder: %s = %d\n", name, value);
>  }
>  
> -static inline int v4l2_get_ext_ctrl(V4L2m2mContext *s, unsigned int id, 
> signed int *value, const char *name)
> +static inline int v4l2_get_ext_ctrl(V4L2m2mContext *s, unsigned int id, 
> signed int *value, const char *name, int log_warning)
>  {
>  struct v4l2_ext_controls ctrls = { { 0 } };
>  struct v4l2_ext_control ctrl = { 0 };
> @@ -83,7 +84,8 @@ static inline int v4l2_get_ext_ctrl(V4L2m2mContext *s, 
> unsigned int id, signed i
>  
>  ret = ioctl(s->fd, VIDIOC_G_EXT_CTRLS, );
>  if (ret < 0) {
> -av_log(s->avctx, AV_LOG_WARNING, "Failed to get %s\n", name);
> +av_log(s->avctx, log_warning || errno != EINVAL ? AV_LOG_WARNING : 
> AV_LOG_DEBUG,
> +   "Failed to get %s\n", name);
>  return ret;
>  }
>  
> @@ -145,8 +147,8 @@ static int v4l2_check_b_frame_support(V4L2m2mContext *s)
>  if (s->avctx->max_b_frames)
>  av_log(s->avctx, AV_LOG_WARNING, "Encoder does not support b-frames 
> yet\n");
>  
> -v4l2_set_ext_ctrl(s, MPEG_CID(B_FRAMES), 0, "number of B-frames");
> -v4l2_get_ext_ctrl(s, MPEG_CID(B_FRAMES), >avctx->max_b_frames, 
> "number of B-frames");
> +v4l2_set_ext_ctrl(s, MPEG_CID(B_FRAMES), 0, "number of B-frames", 0);
> +v4l2_get_ext_ctrl(s, MPEG_CID(B_FRAMES), >avctx->max_b_frames, 
> "number of B-frames", 0);
>  if (s->avctx->max_b_frames == 0)
>  return 0;
>  
> @@ -175,9 +177,9 @@ static int v4l2_prepare_encoder(V4L2m2mContext *s)
>  v4l2_set_timeperframe(s, avctx->framerate.num, avctx->framerate.den);
>  
>  /* set ext ctrls */
> -v4l2_set_ext_ctrl(s, MPEG_CID(HEADER_MODE), 
> MPEG_VIDEO(HEADER_MODE_SEPARATE), "header mode");
> -v4l2_set_ext_ctrl(s, MPEG_CID(BITRATE) , avctx->bit_rate, "bit rate");
> -v4l2_set_ext_ctrl(s, MPEG_CID(GOP_SIZE), avctx->gop_size,"gop size");
> +v4l2_set_ext_ctrl(s, MPEG_CID(HEADER_MODE), 
> MPEG_VIDEO(HEADER_MODE_SEPARATE), "header mode", 0);
> +v4l2_set_ext_ctrl(s, MPEG_CID(BITRATE) , avctx->bit_rate, "bit rate", 1);
> +v4l2_set_ext_ctrl(s, MPEG_CID(GOP_SIZE), avctx->gop_size,"gop size", 1);
>  
>  av_log(avctx, AV_LOG_DEBUG,
>  "Encoder Context: id (%d), profile (%d), frame rate(%d/%d), number 
> b-frames (%d), "
> @@ -187,26 +189,30 @@ static int v4l2_prepare_encoder(V4L2m2mContext *s)
>  
>  switch (avctx->codec_id) {
>  case AV_CODEC_ID_H264:
> +if (avctx->profile != FF_PROFILE_UNKNOWN) {
>  val = v4l2_h264_profile_from_ff(avctx->profile);
>  if (val < 0)
>  av_log(avctx, AV_LOG_WARNING, "h264 profile not found\n");
>  else
> -v4l2_set_ext_ctrl(s, MPEG_CID(H264_PROFILE), val, "h264 
> profile");
> +v4l2_set_ext_ctrl(s, MPEG_CID(H264_PROFILE), val, "h264 
> profile", 1);
> +}
>  qmin_cid = MPEG_CID(H264_MIN_QP);
>  qmax_cid = MPEG_CID(H264_MAX_QP);
>  qmin = 0;
>  qmax = 51;
>  break;
>  case AV_CODEC_ID_MPEG4:
> +if (avctx->profile != FF_PROFILE_UNKNOWN) {
>  val = v4l2_mpeg4_profile_from_ff(avctx->profile);
>  if (val < 0)
>  av_log(avctx, AV_LOG_WARNING, "mpeg4 profile not found\n");
>  else
> -v4l2_set_ext_ctrl(s, MPEG_CID(MPEG4_PROFILE), val, "mpeg4 
> profile");
> +

Re: [FFmpeg-devel] [PATCH] web/download: update min. kernel version for linux binaries

2020-03-14 Thread Carl Eugen Hoyos
Am Sa., 14. März 2020 um 14:24 Uhr schrieb Gyan Doshi :
>
>
>
> On 14-03-2020 06:11 pm, Carl Eugen Hoyos wrote:
> > Am Sa., 14. März 2020 um 13:19 Uhr schrieb Gyan Doshi :
> >>
> >>
> >> On 14-03-2020 04:29 pm, Carl Eugen Hoyos wrote:
> >>> Am Sa., 14. März 2020 um 07:31 Uhr schrieb Gyan Doshi :
>  As per https://johnvansickle.com/ffmpeg/
>  ---
> src/download | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
>  diff --git a/src/download b/src/download
>  index 6292a7e..d9155ee 100644
>  --- a/src/download
>  +++ b/src/download
>  @@ -70,7 +70,7 @@
> Linux Static Builds
> 
>     href="https://johnvansickle.com/ffmpeg/;>32-bit and
>  -64-bit for kernel 2.6.32 and above
>  +64-bit for kernel 3.2.0 and above
> >>> Shouldn't we instead remove the line?
> >> Why?
> > Because we cannot know which kernel version the binaries currently require
>
> We know, because the provider mentions it.
>
> > Are we mentioning that the Zeranoe binaries do not work on XP?
>
> Or on Vista, as mentioned by the provider.  That should be noted.
>
> As long as the qualifications don't get too verbose, no harm in
> adding/maintaining the practice.

I believe it is better if Zeranoe and johnvansickle mention it, we
should remove the existing line.

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH] web/download: update min. kernel version for linux binaries

2020-03-14 Thread Gyan Doshi



On 14-03-2020 06:11 pm, Carl Eugen Hoyos wrote:

Am Sa., 14. März 2020 um 13:19 Uhr schrieb Gyan Doshi :



On 14-03-2020 04:29 pm, Carl Eugen Hoyos wrote:

Am Sa., 14. März 2020 um 07:31 Uhr schrieb Gyan Doshi :

As per https://johnvansickle.com/ffmpeg/
---
   src/download | 2 +-
   1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/download b/src/download
index 6292a7e..d9155ee 100644
--- a/src/download
+++ b/src/download
@@ -70,7 +70,7 @@
   Linux Static Builds
   
 https://johnvansickle.com/ffmpeg/;>32-bit and
-64-bit for kernel 2.6.32 and above
+64-bit for kernel 3.2.0 and above

Shouldn't we instead remove the line?

Why?

Because we cannot know which kernel version the binaries currently require


We know, because the provider mentions it.


Are we mentioning that the Zeranoe binaries do not work on XP?


Or on Vista, as mentioned by the provider.  That should be noted.

As long as the qualifications don't get too verbose, no harm in 
adding/maintaining the practice.


Gyan


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

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

Re: [FFmpeg-devel] [PATCH 01/18] mpeg4videodec: do not copy a range of fields at once

2020-03-14 Thread Carl Eugen Hoyos
Am Sa., 14. März 2020 um 12:58 Uhr schrieb Paul B Mahol :
>
> On 3/14/20, Carl Eugen Hoyos  wrote:
> > Am Fr., 13. März 2020 um 11:30 Uhr schrieb Anton Khirnov
> > :
> >>
> >> This is extremely fragile against reordering and hides what is actually
> >> being copied. Copy all the fields manually instead.
> >> ---
> >>  libavcodec/mpeg4videodec.c | 27 ++-
> >>  1 file changed, 26 insertions(+), 1 deletion(-)
> >>
> >> diff --git a/libavcodec/mpeg4videodec.c b/libavcodec/mpeg4videodec.c
> >> index cc03486646..a51985d51b 100644
> >> --- a/libavcodec/mpeg4videodec.c
> >> +++ b/libavcodec/mpeg4videodec.c
> >> @@ -3460,7 +3460,32 @@ static int
> >> mpeg4_update_thread_context(AVCodecContext *dst,
> >>  if (ret < 0)
> >>  return ret;
> >>
> >> -memcpy(((uint8_t*)s) + sizeof(MpegEncContext), ((uint8_t*)s1) +
> >> sizeof(MpegEncContext), sizeof(Mpeg4DecContext) - sizeof(MpegEncContext));
> >> +s->time_increment_bits   = s1->time_increment_bits;
> >> +s->shape = s1->shape;
> >> +s->vol_sprite_usage  = s1->vol_sprite_usage;
> >> +s->sprite_brightness_change  = s1->sprite_brightness_change;
> >> +s->num_sprite_warping_points = s1->num_sprite_warping_points;
> >> +s->rvlc  = s1->rvlc;
> >> +s->resync_marker = s1->resync_marker;
> >> +s->t_frame   = s1->t_frame;
> >> +s->new_pred  = s1->new_pred;
> >> +s->enhancement_type  = s1->enhancement_type;
> >> +s->scalability   = s1->scalability;
> >> +s->use_intra_dc_vlc  = s1->use_intra_dc_vlc;
> >> +s->intra_dc_threshold= s1->intra_dc_threshold;
> >> +s->divx_version  = s1->divx_version;
> >> +s->divx_build= s1->divx_build;
> >> +s->xvid_build= s1->xvid_build;
> >> +s->lavc_build= s1->lavc_build;
> >> +s->showed_packed_warning = s1->showed_packed_warning;
> >> +s->vol_control_parameters= s1->vol_control_parameters;
> >> +s->cplx_estimation_trash_i   = s1->cplx_estimation_trash_i;
> >> +s->cplx_estimation_trash_p   = s1->cplx_estimation_trash_p;
> >> +s->cplx_estimation_trash_b   = s1->cplx_estimation_trash_b;
> >> +s->rgb   = s1->rgb;
> >> +
> >> +memcpy(s->sprite_shift, s1->sprite_shift, sizeof(s1->sprite_shift));
> >> +memcpy(s->sprite_traj,  s1->sprite_traj,  sizeof(s1->sprite_traj));
> >
> > Am I really the only one who finds the code more "fragile" after this
> > change?
>
> Elaborate how it is "fragile"?

Because new fields might be forgotten.

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH] web/download: update min. kernel version for linux binaries

2020-03-14 Thread Carl Eugen Hoyos
Am Sa., 14. März 2020 um 13:19 Uhr schrieb Gyan Doshi :
>
>
>
> On 14-03-2020 04:29 pm, Carl Eugen Hoyos wrote:
> > Am Sa., 14. März 2020 um 07:31 Uhr schrieb Gyan Doshi :
> >> As per https://johnvansickle.com/ffmpeg/
> >> ---
> >>   src/download | 2 +-
> >>   1 file changed, 1 insertion(+), 1 deletion(-)
> >>
> >> diff --git a/src/download b/src/download
> >> index 6292a7e..d9155ee 100644
> >> --- a/src/download
> >> +++ b/src/download
> >> @@ -70,7 +70,7 @@
> >>   Linux Static Builds
> >>   
> >>  >> href="https://johnvansickle.com/ffmpeg/;>32-bit and
> >> -64-bit for kernel 2.6.32 and above
> >> +64-bit for kernel 3.2.0 and above
> > Shouldn't we instead remove the line?
>
> Why?

Because we cannot know which kernel version the binaries currently require
and because people with ancient kernels probably won't download current
FFmpeg.

Are we mentioning that the Zeranoe binaries do not work on XP?

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH 2/2] avformat: add fwse demuxer

2020-03-14 Thread Paul B Mahol
On 3/14/20, Andreas Rheinhardt  wrote:
> Paul B Mahol:
>> Signed-off-by: Paul B Mahol 
>> ---
>>  libavformat/Makefile |  1 +
>>  libavformat/allformats.c |  1 +
>>  libavformat/fwse.c   | 88 
>>  3 files changed, 90 insertions(+)
>>  create mode 100644 libavformat/fwse.c
>>
>> diff --git a/libavformat/Makefile b/libavformat/Makefile
>> index f84becd30a..cd3e9163f5 100644
>> --- a/libavformat/Makefile
>> +++ b/libavformat/Makefile
>> @@ -198,6 +198,7 @@ OBJS-$(CONFIG_FRAMEHASH_MUXER)   += hashenc.o
>> framehash.o
>>  OBJS-$(CONFIG_FRAMEMD5_MUXER)+= hashenc.o framehash.o
>>  OBJS-$(CONFIG_FRM_DEMUXER)   += frmdec.o
>>  OBJS-$(CONFIG_FSB_DEMUXER)   += fsb.o
>> +OBJS-$(CONFIG_FWSE_DEMUXER)  += fwse.o
>>  OBJS-$(CONFIG_GIF_MUXER) += gif.o
>>  OBJS-$(CONFIG_GIF_DEMUXER)   += gifdec.o
>>  OBJS-$(CONFIG_GSM_DEMUXER)   += gsmdec.o
>> diff --git a/libavformat/allformats.c b/libavformat/allformats.c
>> index 08012ea208..d275c1017b 100644
>> --- a/libavformat/allformats.c
>> +++ b/libavformat/allformats.c
>> @@ -156,6 +156,7 @@ extern AVOutputFormat ff_framehash_muxer;
>>  extern AVOutputFormat ff_framemd5_muxer;
>>  extern AVInputFormat  ff_frm_demuxer;
>>  extern AVInputFormat  ff_fsb_demuxer;
>> +extern AVInputFormat  ff_fwse_demuxer;
>>  extern AVInputFormat  ff_g722_demuxer;
>>  extern AVOutputFormat ff_g722_muxer;
>>  extern AVInputFormat  ff_g723_1_demuxer;
>> diff --git a/libavformat/fwse.c b/libavformat/fwse.c
>> new file mode 100644
>> index 00..76ed6b0c23
>> --- /dev/null
>> +++ b/libavformat/fwse.c
>> @@ -0,0 +1,88 @@
>> +/*
>> + * FWSE demuxer
>> + * Copyright (c) 2020 Paul B Mahol
>> + *
>> + * This file is part of FFmpeg.
>> + *
>> + * FFmpeg is free software; you can redistribute it and/or
>> + * modify it under the terms of the GNU Lesser General Public
>> + * License as published by the Free Software Foundation; either
>> + * version 2.1 of the License, or (at your option) any later version.
>> + *
>> + * FFmpeg is distributed in the hope that it will be useful,
>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
>> + * Lesser General Public License for more details.
>> + *
>> + * You should have received a copy of the GNU Lesser General Public
>> + * License along with FFmpeg; if not, write to the Free Software
>> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
>> 02110-1301 USA
>> + */
>> +
>> +#include "libavutil/intreadwrite.h"
>> +#include "libavcodec/internal.h"
>
> What are you using from this header?

Will remove.

>
>> +#include "avformat.h"
>> +#include "internal.h"
>> +#include "pcm.h"
>> +
>> +typedef struct FWSEDemuxContext {
>> +unsigned dsp_int_type;
>> +unsigned interleave_size;
>> +} FWSEDemuxContext;
>
> This structure is completely unused.

Will remove.

>> +
>> +static int fwse_probe(const AVProbeData *p)
>> +{
>> +if (AV_RL32(p->buf) != MKTAG('F','W','S','E'))
>> +return 0;
>> +if (AV_RL32(p->buf+4) != 2 && AV_RL32(p->buf+4) != 3)
>> +return 0;
>> +
>> +return AVPROBE_SCORE_MAX / 3 * 2;
>> +}
>> +
>> +static int fwse_read_header(AVFormatContext *s)
>> +{
>> +FWSEDemuxContext *c = s->priv_data;
>
> Doesn't your compiler warn you about unused variables like this one?

Will remove.

>
>> +unsigned start_offset, version;
>> +AVStream *st;
>> +
>> +avio_skip(s->pb, 4);
>
> You're checking the version, yet you are not checking the tag?

That is valid case, if somebody forces demuxer.

>
>> +version = avio_rl32(s->pb);
>> +if (version != 1 && version != 2)
>
> fwse_probe wants 2 or 3 and here it is 1 or 2.

Fill fix.

>
>> +return AVERROR_INVALIDDATA;
>> +avio_skip(s->pb, 4);
>> +start_offset = avio_rl32(s->pb);
>> +
>> +st = avformat_new_stream(s, NULL);
>> +if (!st)
>> +return AVERROR(ENOMEM);
>> +
>> +st->codecpar->codec_type  = AVMEDIA_TYPE_AUDIO;
>
> Why don't you access codecpar via its own pointer to reduce the amount
> of writing? (You could do the same with s->pb.)

Why not.

>
>> +st->codecpar->codec_id= AV_CODEC_ID_ADPCM_IMA_MTF;
>> +st->codecpar->format  = AV_SAMPLE_FMT_S16;
>> +st->codecpar->channels= avio_rl32(s->pb);
>> +if (st->codecpar->channels != 1 && st->codecpar->channels != 2)> +
>> return AVERROR_INVALIDDATA;
>
> Why don't you just add this as another else at the end of the following
> checks? (And why don't you check for this during probing?)

Why not.

>
>> +if (st->codecpar->channels == 1)
>> +st->codecpar->channel_layout = AV_CH_LAYOUT_MONO;
>> +else if (st->codecpar->channels == 2)
>> +st->codecpar->channel_layout = AV_CH_LAYOUT_STEREO;
>> +st->duration = avio_rl32(s->pb);
>> +st->codecpar->sample_rate = avio_rl32(s->pb);
>
> No check for 

Re: [FFmpeg-devel] [PATCH] web/download: update min. kernel version for linux binaries

2020-03-14 Thread Gyan Doshi



On 14-03-2020 04:29 pm, Carl Eugen Hoyos wrote:

Am Sa., 14. März 2020 um 07:31 Uhr schrieb Gyan Doshi :

As per https://johnvansickle.com/ffmpeg/
---
  src/download | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/download b/src/download
index 6292a7e..d9155ee 100644
--- a/src/download
+++ b/src/download
@@ -70,7 +70,7 @@
  Linux Static Builds
  
https://johnvansickle.com/ffmpeg/;>32-bit and
-64-bit for kernel 2.6.32 and above
+64-bit for kernel 3.2.0 and above

Shouldn't we instead remove the line?


Why?

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

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

Re: [FFmpeg-devel] [PATCH 2/2] avformat: add fwse demuxer

2020-03-14 Thread Andreas Rheinhardt
Paul B Mahol:
> Signed-off-by: Paul B Mahol 
> ---
>  libavformat/Makefile |  1 +
>  libavformat/allformats.c |  1 +
>  libavformat/fwse.c   | 88 
>  3 files changed, 90 insertions(+)
>  create mode 100644 libavformat/fwse.c
> 
> diff --git a/libavformat/Makefile b/libavformat/Makefile
> index f84becd30a..cd3e9163f5 100644
> --- a/libavformat/Makefile
> +++ b/libavformat/Makefile
> @@ -198,6 +198,7 @@ OBJS-$(CONFIG_FRAMEHASH_MUXER)   += hashenc.o 
> framehash.o
>  OBJS-$(CONFIG_FRAMEMD5_MUXER)+= hashenc.o framehash.o
>  OBJS-$(CONFIG_FRM_DEMUXER)   += frmdec.o
>  OBJS-$(CONFIG_FSB_DEMUXER)   += fsb.o
> +OBJS-$(CONFIG_FWSE_DEMUXER)  += fwse.o
>  OBJS-$(CONFIG_GIF_MUXER) += gif.o
>  OBJS-$(CONFIG_GIF_DEMUXER)   += gifdec.o
>  OBJS-$(CONFIG_GSM_DEMUXER)   += gsmdec.o
> diff --git a/libavformat/allformats.c b/libavformat/allformats.c
> index 08012ea208..d275c1017b 100644
> --- a/libavformat/allformats.c
> +++ b/libavformat/allformats.c
> @@ -156,6 +156,7 @@ extern AVOutputFormat ff_framehash_muxer;
>  extern AVOutputFormat ff_framemd5_muxer;
>  extern AVInputFormat  ff_frm_demuxer;
>  extern AVInputFormat  ff_fsb_demuxer;
> +extern AVInputFormat  ff_fwse_demuxer;
>  extern AVInputFormat  ff_g722_demuxer;
>  extern AVOutputFormat ff_g722_muxer;
>  extern AVInputFormat  ff_g723_1_demuxer;
> diff --git a/libavformat/fwse.c b/libavformat/fwse.c
> new file mode 100644
> index 00..76ed6b0c23
> --- /dev/null
> +++ b/libavformat/fwse.c
> @@ -0,0 +1,88 @@
> +/*
> + * FWSE demuxer
> + * Copyright (c) 2020 Paul B Mahol
> + *
> + * This file is part of FFmpeg.
> + *
> + * FFmpeg is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU Lesser General Public
> + * License as published by the Free Software Foundation; either
> + * version 2.1 of the License, or (at your option) any later version.
> + *
> + * FFmpeg is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
> + * Lesser General Public License for more details.
> + *
> + * You should have received a copy of the GNU Lesser General Public
> + * License along with FFmpeg; if not, write to the Free Software
> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
> USA
> + */
> +
> +#include "libavutil/intreadwrite.h"
> +#include "libavcodec/internal.h"

What are you using from this header?

> +#include "avformat.h"
> +#include "internal.h"
> +#include "pcm.h"
> +
> +typedef struct FWSEDemuxContext {
> +unsigned dsp_int_type;
> +unsigned interleave_size;
> +} FWSEDemuxContext;

This structure is completely unused.
> +
> +static int fwse_probe(const AVProbeData *p)
> +{
> +if (AV_RL32(p->buf) != MKTAG('F','W','S','E'))
> +return 0;
> +if (AV_RL32(p->buf+4) != 2 && AV_RL32(p->buf+4) != 3)
> +return 0;
> +
> +return AVPROBE_SCORE_MAX / 3 * 2;
> +}
> +
> +static int fwse_read_header(AVFormatContext *s)
> +{
> +FWSEDemuxContext *c = s->priv_data;

Doesn't your compiler warn you about unused variables like this one?

> +unsigned start_offset, version;
> +AVStream *st;
> +
> +avio_skip(s->pb, 4);

You're checking the version, yet you are not checking the tag?

> +version = avio_rl32(s->pb);
> +if (version != 1 && version != 2)

fwse_probe wants 2 or 3 and here it is 1 or 2.

> +return AVERROR_INVALIDDATA;
> +avio_skip(s->pb, 4);
> +start_offset = avio_rl32(s->pb);
> +
> +st = avformat_new_stream(s, NULL);
> +if (!st)
> +return AVERROR(ENOMEM);
> +
> +st->codecpar->codec_type  = AVMEDIA_TYPE_AUDIO;

Why don't you access codecpar via its own pointer to reduce the amount
of writing? (You could do the same with s->pb.)

> +st->codecpar->codec_id= AV_CODEC_ID_ADPCM_IMA_MTF;
> +st->codecpar->format  = AV_SAMPLE_FMT_S16;
> +st->codecpar->channels= avio_rl32(s->pb);
> +if (st->codecpar->channels != 1 && st->codecpar->channels != 2)> +   
>  return AVERROR_INVALIDDATA;

Why don't you just add this as another else at the end of the following
checks? (And why don't you check for this during probing?)

> +if (st->codecpar->channels == 1)
> +st->codecpar->channel_layout = AV_CH_LAYOUT_MONO;
> +else if (st->codecpar->channels == 2)
> +st->codecpar->channel_layout = AV_CH_LAYOUT_STEREO;
> +st->duration = avio_rl32(s->pb);
> +st->codecpar->sample_rate = avio_rl32(s->pb);

No check for insane values?

> +st->codecpar->block_align = 1;
> +avio_skip(s->pb, start_offset - avio_tell(s->pb));

avio_seek(s->pb, start_offset, SEEK_SET)?
> +
> +avpriv_set_pts_info(st, 64, 1, st->codecpar->sample_rate);
> +
> +return 0;
> +}
> +
> +AVInputFormat ff_fwse_demuxer = {
> +.name  

[FFmpeg-devel] GSoC 2020:Audio tones source filter

2020-03-14 Thread apk120
Audio tones source filter to generate random audio tones using fluidsynth

diff --git a/Makefile b/Makefile
index 45a22b0cb3..44cf1b5710 100644
--- a/Makefile
+++ b/Makefile
@@ -111,7 +111,7 @@ else
 endif
 
 %$(PROGSSUF)_g$(EXESUF): $(FF_DEP_LIBS)
-   $(LD) $(LDFLAGS) $(LDEXEFLAGS) $(LD_O) $(OBJS-$*) $(FF_EXTRALIBS)
+   $(LD) $(LDFLAGS) $(LDEXEFLAGS) $(LD_O) $(OBJS-$*) $(FF_EXTRALIBS) 
-lfluidsynth
 
 VERSION_SH  = $(SRC_PATH)/ffbuild/version.sh
 GIT_LOG = $(SRC_PATH)/.git/logs/HEAD
diff --git a/libavfilter/Makefile b/libavfilter/Makefile
index 750412da6b..b1f0c4be35 100644
--- a/libavfilter/Makefile
+++ b/libavfilter/Makefile
@@ -151,6 +151,7 @@ OBJS-$(CONFIG_FLITE_FILTER)  += asrc_flite.o
 OBJS-$(CONFIG_HILBERT_FILTER)+= asrc_hilbert.o
 OBJS-$(CONFIG_SINC_FILTER)   += asrc_sinc.o
 OBJS-$(CONFIG_SINE_FILTER)   += asrc_sine.o
+OBJS-$(CONFIG_ATONE_FILTER)  += asrc_atone.o
 
 OBJS-$(CONFIG_ANULLSINK_FILTER)  += asink_anullsink.o
 
diff --git a/libavfilter/allfilters.c b/libavfilter/allfilters.c
index 501e5d041b..4d3efc7e15 100644
--- a/libavfilter/allfilters.c
+++ b/libavfilter/allfilters.c
@@ -145,6 +145,7 @@ extern AVFilter ff_asrc_flite;
 extern AVFilter ff_asrc_hilbert;
 extern AVFilter ff_asrc_sinc;
 extern AVFilter ff_asrc_sine;
+extern AVFilter ff_asrc_atone;
 
 extern AVFilter ff_asink_anullsink;
 
diff --git a/libavfilter/asrc_atone.c b/libavfilter/asrc_atone.c
new file mode 100644
index 00..e3703f5e4b
--- /dev/null
+++ b/libavfilter/asrc_atone.c
@@ -0,0 +1,244 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with FFmpeg; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include "libavutil/avassert.h"
+#include "libavutil/channel_layout.h"
+#include "libavutil/eval.h"
+#include "libavutil/opt.h"
+#include "libavutil/lfg.h"
+#include "libavutil/random_seed.h"
+#include "audio.h"
+#include "avfilter.h"
+#include "internal.h"
+
+typedef struct AtoneContext
+{
+const AVClass* class;
+int64_t duration;
+int nb_samples;
+int sample_rate;
+int64_t pts;
+int infinite;
+
+fluid_settings_t* settings;
+fluid_synth_t* synth;
+char* sfont;///< soundfont file
+int sfont_id;
+int midi_chan; ///< midi channel number
+int velocity;  ///< velocity of key
+int changerate;///< get the frequency of changing tones
+float* left;   ///< store the left buffer
+float* right;  ///< store the right buffer
+AVLFG key;  
+}AtoneContext;
+
+#define CONTEXT AtoneContext
+#define FLAGS AV_OPT_FLAG_AUDIO_PARAM|AV_OPT_FLAG_FILTERING_PARAM
+
+#define OPT_GENERIC(name, field, def, min, max, descr, type, deffield, ...) \
+{ name, descr, offsetof(CONTEXT, field), AV_OPT_TYPE_ ## type,  \
+  { .deffield = def }, min, max, FLAGS, __VA_ARGS__ }
+
+#define OPT_INT(name, field, def, min, max, descr, ...) \
+OPT_GENERIC(name, field, def, min, max, descr, INT, i64, __VA_ARGS__)
+
+#define OPT_DUR(name, field, def, min, max, descr, ...) \
+OPT_GENERIC(name, field, def, min, max, descr, DURATION, str, __VA_ARGS__)
+
+#define OPT_STR(name, field, def, min, max, descr, ...) \
+OPT_GENERIC(name, field, def, min, max, descr, STRING, str, __VA_ARGS__)
+
+static const AVOption atone_options[] = {
+OPT_INT("velocity",  velocity,   80,   
   0, INT_MAX, "set the velocity of key press",),
+OPT_INT("v", velocity,   80,   
   0, INT_MAX, "set the velocity of key press",),
+OPT_INT("sample_rate",   sample_rate,44100,
   1, INT_MAX, "set the sample rate",),
+OPT_INT("r", sample_rate,44100,
   1, INT_MAX, "set the sample rate",),
+OPT_DUR("duration",  duration,   0,
   0, INT64_MAX,   "set the audio duration",),
+OPT_DUR("d", duration,   0,
 

Re: [FFmpeg-devel] [PATCH 01/18] mpeg4videodec: do not copy a range of fields at once

2020-03-14 Thread Paul B Mahol
On 3/14/20, Carl Eugen Hoyos  wrote:
> Am Fr., 13. März 2020 um 11:30 Uhr schrieb Anton Khirnov
> :
>>
>> This is extremely fragile against reordering and hides what is actually
>> being copied. Copy all the fields manually instead.
>> ---
>>  libavcodec/mpeg4videodec.c | 27 ++-
>>  1 file changed, 26 insertions(+), 1 deletion(-)
>>
>> diff --git a/libavcodec/mpeg4videodec.c b/libavcodec/mpeg4videodec.c
>> index cc03486646..a51985d51b 100644
>> --- a/libavcodec/mpeg4videodec.c
>> +++ b/libavcodec/mpeg4videodec.c
>> @@ -3460,7 +3460,32 @@ static int
>> mpeg4_update_thread_context(AVCodecContext *dst,
>>  if (ret < 0)
>>  return ret;
>>
>> -memcpy(((uint8_t*)s) + sizeof(MpegEncContext), ((uint8_t*)s1) +
>> sizeof(MpegEncContext), sizeof(Mpeg4DecContext) - sizeof(MpegEncContext));
>> +s->time_increment_bits   = s1->time_increment_bits;
>> +s->shape = s1->shape;
>> +s->vol_sprite_usage  = s1->vol_sprite_usage;
>> +s->sprite_brightness_change  = s1->sprite_brightness_change;
>> +s->num_sprite_warping_points = s1->num_sprite_warping_points;
>> +s->rvlc  = s1->rvlc;
>> +s->resync_marker = s1->resync_marker;
>> +s->t_frame   = s1->t_frame;
>> +s->new_pred  = s1->new_pred;
>> +s->enhancement_type  = s1->enhancement_type;
>> +s->scalability   = s1->scalability;
>> +s->use_intra_dc_vlc  = s1->use_intra_dc_vlc;
>> +s->intra_dc_threshold= s1->intra_dc_threshold;
>> +s->divx_version  = s1->divx_version;
>> +s->divx_build= s1->divx_build;
>> +s->xvid_build= s1->xvid_build;
>> +s->lavc_build= s1->lavc_build;
>> +s->showed_packed_warning = s1->showed_packed_warning;
>> +s->vol_control_parameters= s1->vol_control_parameters;
>> +s->cplx_estimation_trash_i   = s1->cplx_estimation_trash_i;
>> +s->cplx_estimation_trash_p   = s1->cplx_estimation_trash_p;
>> +s->cplx_estimation_trash_b   = s1->cplx_estimation_trash_b;
>> +s->rgb   = s1->rgb;
>> +
>> +memcpy(s->sprite_shift, s1->sprite_shift, sizeof(s1->sprite_shift));
>> +memcpy(s->sprite_traj,  s1->sprite_traj,  sizeof(s1->sprite_traj));
>
> Am I really the only one who finds the code more "fragile" after this
> change?

Elaborate how it is "fragile"?

>
> Carl Eugen
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

[FFmpeg-devel] [PATCH 1/2] avcodec: add ADPCM IMA MTF decoder

2020-03-14 Thread Paul B Mahol
Signed-off-by: Paul B Mahol 
---
 libavcodec/Makefile |  1 +
 libavcodec/adpcm.c  | 33 +
 libavcodec/allcodecs.c  |  1 +
 libavcodec/avcodec.h|  1 +
 libavcodec/codec_desc.c |  7 +++
 5 files changed, 43 insertions(+)

diff --git a/libavcodec/Makefile b/libavcodec/Makefile
index a3326a45e7..b50a26907f 100644
--- a/libavcodec/Makefile
+++ b/libavcodec/Makefile
@@ -843,6 +843,7 @@ OBJS-$(CONFIG_ADPCM_IMA_DK4_DECODER)  += adpcm.o 
adpcm_data.o
 OBJS-$(CONFIG_ADPCM_IMA_EA_EACS_DECODER)  += adpcm.o adpcm_data.o
 OBJS-$(CONFIG_ADPCM_IMA_EA_SEAD_DECODER)  += adpcm.o adpcm_data.o
 OBJS-$(CONFIG_ADPCM_IMA_ISS_DECODER)  += adpcm.o adpcm_data.o
+OBJS-$(CONFIG_ADPCM_IMA_MTF_DECODER)  += adpcm.o adpcm_data.o
 OBJS-$(CONFIG_ADPCM_IMA_OKI_DECODER)  += adpcm.o adpcm_data.o
 OBJS-$(CONFIG_ADPCM_IMA_QT_DECODER)   += adpcm.o adpcm_data.o
 OBJS-$(CONFIG_ADPCM_IMA_QT_ENCODER)   += adpcmenc.o adpcm_data.o
diff --git a/libavcodec/adpcm.c b/libavcodec/adpcm.c
index 4f5980f7d5..e9abddc43c 100644
--- a/libavcodec/adpcm.c
+++ b/libavcodec/adpcm.c
@@ -89,6 +89,11 @@ static const int8_t zork_index_table[8] = {
 -1, -1, -1, 1, 4, 7, 10, 12,
 };
 
+static const int8_t mtf_index_table[16] = {
+ 8,  6,  4,  2, -1, -1, -1, -1,
+-1, -1, -1, -1,  2,  4,  6,  8,
+};
+
 /* end of tables */
 
 typedef struct ADPCMDecodeContext {
@@ -304,6 +309,22 @@ static inline int16_t 
adpcm_ima_alp_expand_nibble(ADPCMChannelStatus *c, int8_t
 return (int16_t)c->predictor;
 }
 
+static inline int16_t adpcm_ima_mtf_expand_nibble(ADPCMChannelStatus *c, int 
nibble)
+{
+int step_index, step, delta, predictor;
+
+step = ff_adpcm_step_table[c->step_index];
+
+delta = step * (2 * nibble - 15);
+predictor = c->predictor + delta;
+
+step_index = c->step_index + mtf_index_table[(unsigned)nibble];
+c->predictor = av_clip_int16(predictor >> 4);
+c->step_index = av_clip(step_index, 0, 88);
+
+return (int16_t)c->predictor;
+}
+
 static inline int16_t adpcm_ima_wav_expand_nibble(ADPCMChannelStatus *c, 
GetBitContext *gb, int bps)
 {
 int nibble, step_index, predictor, sign, delta, diff, step, shift;
@@ -700,6 +721,7 @@ static int get_nb_samples(AVCodecContext *avctx, 
GetByteContext *gb,
 case AV_CODEC_ID_ADPCM_IMA_SSI:
 case AV_CODEC_ID_ADPCM_IMA_APM:
 case AV_CODEC_ID_ADPCM_IMA_ALP:
+case AV_CODEC_ID_ADPCM_IMA_MTF:
 nb_samples = buf_size * 2 / ch;
 break;
 }
@@ -1956,6 +1978,16 @@ static int adpcm_decode_frame(AVCodecContext *avctx, 
void *data,
 *samples++ = adpcm_zork_expand_nibble(>status[n % 
avctx->channels], v);
 }
 break;
+case AV_CODEC_ID_ADPCM_IMA_MTF:
+for (n = nb_samples / 2; n > 0; n--) {
+for (channel = 0; channel < avctx->channels; channel++) {
+int v = bytestream2_get_byteu();
+*samples++  = adpcm_ima_mtf_expand_nibble(>status[channel], 
v >> 4);
+samples[st] = adpcm_ima_mtf_expand_nibble(>status[channel], 
v & 0x0F);
+}
+samples += avctx->channels;
+}
+break;
 default:
 av_assert0(0); // unsupported codec_id should not happen
 }
@@ -2027,6 +2059,7 @@ ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_DK4, 
sample_fmts_s16,  adpcm_ima_dk4,
 ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_EA_EACS, sample_fmts_s16,  
adpcm_ima_ea_eacs, "ADPCM IMA Electronic Arts EACS");
 ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_EA_SEAD, sample_fmts_s16,  
adpcm_ima_ea_sead, "ADPCM IMA Electronic Arts SEAD");
 ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_ISS, sample_fmts_s16,  adpcm_ima_iss,  
   "ADPCM IMA Funcom ISS");
+ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_MTF, sample_fmts_s16,  adpcm_ima_mtf,  
   "ADPCM IMA Capcom's MT Framework");
 ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_OKI, sample_fmts_s16,  adpcm_ima_oki,  
   "ADPCM IMA Dialogic OKI");
 ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_QT,  sample_fmts_s16p, adpcm_ima_qt,   
   "ADPCM IMA QuickTime");
 ADPCM_DECODER(AV_CODEC_ID_ADPCM_IMA_RAD, sample_fmts_s16,  adpcm_ima_rad,  
   "ADPCM IMA Radical");
diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c
index f4cf180716..379c5f7b81 100644
--- a/libavcodec/allcodecs.c
+++ b/libavcodec/allcodecs.c
@@ -608,6 +608,7 @@ extern AVCodec ff_adpcm_ima_dk4_decoder;
 extern AVCodec ff_adpcm_ima_ea_eacs_decoder;
 extern AVCodec ff_adpcm_ima_ea_sead_decoder;
 extern AVCodec ff_adpcm_ima_iss_decoder;
+extern AVCodec ff_adpcm_ima_mtf_decoder;
 extern AVCodec ff_adpcm_ima_oki_decoder;
 extern AVCodec ff_adpcm_ima_qt_encoder;
 extern AVCodec ff_adpcm_ima_qt_decoder;
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index aca3825fd3..9ac97a122b 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -553,6 +553,7 @@ enum AVCodecID {
 AV_CODEC_ID_ADPCM_ZORK,
 AV_CODEC_ID_ADPCM_IMA_APM,
 AV_CODEC_ID_ADPCM_IMA_ALP,
+AV_CODEC_ID_ADPCM_IMA_MTF,
 
 /* AMR */
 

[FFmpeg-devel] [PATCH 2/2] avformat: add fwse demuxer

2020-03-14 Thread Paul B Mahol
Signed-off-by: Paul B Mahol 
---
 libavformat/Makefile |  1 +
 libavformat/allformats.c |  1 +
 libavformat/fwse.c   | 88 
 3 files changed, 90 insertions(+)
 create mode 100644 libavformat/fwse.c

diff --git a/libavformat/Makefile b/libavformat/Makefile
index f84becd30a..cd3e9163f5 100644
--- a/libavformat/Makefile
+++ b/libavformat/Makefile
@@ -198,6 +198,7 @@ OBJS-$(CONFIG_FRAMEHASH_MUXER)   += hashenc.o 
framehash.o
 OBJS-$(CONFIG_FRAMEMD5_MUXER)+= hashenc.o framehash.o
 OBJS-$(CONFIG_FRM_DEMUXER)   += frmdec.o
 OBJS-$(CONFIG_FSB_DEMUXER)   += fsb.o
+OBJS-$(CONFIG_FWSE_DEMUXER)  += fwse.o
 OBJS-$(CONFIG_GIF_MUXER) += gif.o
 OBJS-$(CONFIG_GIF_DEMUXER)   += gifdec.o
 OBJS-$(CONFIG_GSM_DEMUXER)   += gsmdec.o
diff --git a/libavformat/allformats.c b/libavformat/allformats.c
index 08012ea208..d275c1017b 100644
--- a/libavformat/allformats.c
+++ b/libavformat/allformats.c
@@ -156,6 +156,7 @@ extern AVOutputFormat ff_framehash_muxer;
 extern AVOutputFormat ff_framemd5_muxer;
 extern AVInputFormat  ff_frm_demuxer;
 extern AVInputFormat  ff_fsb_demuxer;
+extern AVInputFormat  ff_fwse_demuxer;
 extern AVInputFormat  ff_g722_demuxer;
 extern AVOutputFormat ff_g722_muxer;
 extern AVInputFormat  ff_g723_1_demuxer;
diff --git a/libavformat/fwse.c b/libavformat/fwse.c
new file mode 100644
index 00..76ed6b0c23
--- /dev/null
+++ b/libavformat/fwse.c
@@ -0,0 +1,88 @@
+/*
+ * FWSE demuxer
+ * Copyright (c) 2020 Paul B Mahol
+ *
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "libavutil/intreadwrite.h"
+#include "libavcodec/internal.h"
+#include "avformat.h"
+#include "internal.h"
+#include "pcm.h"
+
+typedef struct FWSEDemuxContext {
+unsigned dsp_int_type;
+unsigned interleave_size;
+} FWSEDemuxContext;
+
+static int fwse_probe(const AVProbeData *p)
+{
+if (AV_RL32(p->buf) != MKTAG('F','W','S','E'))
+return 0;
+if (AV_RL32(p->buf+4) != 2 && AV_RL32(p->buf+4) != 3)
+return 0;
+
+return AVPROBE_SCORE_MAX / 3 * 2;
+}
+
+static int fwse_read_header(AVFormatContext *s)
+{
+FWSEDemuxContext *c = s->priv_data;
+unsigned start_offset, version;
+AVStream *st;
+
+avio_skip(s->pb, 4);
+version = avio_rl32(s->pb);
+if (version != 1 && version != 2)
+return AVERROR_INVALIDDATA;
+avio_skip(s->pb, 4);
+start_offset = avio_rl32(s->pb);
+
+st = avformat_new_stream(s, NULL);
+if (!st)
+return AVERROR(ENOMEM);
+
+st->codecpar->codec_type  = AVMEDIA_TYPE_AUDIO;
+st->codecpar->codec_id= AV_CODEC_ID_ADPCM_IMA_MTF;
+st->codecpar->format  = AV_SAMPLE_FMT_S16;
+st->codecpar->channels= avio_rl32(s->pb);
+if (st->codecpar->channels != 1 && st->codecpar->channels != 2)
+return AVERROR_INVALIDDATA;
+if (st->codecpar->channels == 1)
+st->codecpar->channel_layout = AV_CH_LAYOUT_MONO;
+else if (st->codecpar->channels == 2)
+st->codecpar->channel_layout = AV_CH_LAYOUT_STEREO;
+st->duration = avio_rl32(s->pb);
+st->codecpar->sample_rate = avio_rl32(s->pb);
+st->codecpar->block_align = 1;
+avio_skip(s->pb, start_offset - avio_tell(s->pb));
+
+avpriv_set_pts_info(st, 64, 1, st->codecpar->sample_rate);
+
+return 0;
+}
+
+AVInputFormat ff_fwse_demuxer = {
+.name   = "fwse",
+.long_name  = NULL_IF_CONFIG_SMALL("Capcom's MT Framework sound"),
+.priv_data_size = sizeof(FWSEDemuxContext),
+.read_probe = fwse_probe,
+.read_header= fwse_read_header,
+.read_packet= ff_pcm_read_packet,
+.extensions = "fwse",
+};
-- 
2.17.1

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

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

[FFmpeg-devel] [PATCH v4] web/generate-doc.sh: use --disable-asm instead of --disable-yasm

2020-03-14 Thread Steven Liu
Suggested-by: Carl Eugen Hoyos 
Reviewed-by: Lou Logan 
Signed-off-by: Steven Liu 
---
 generate-doc.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/generate-doc.sh b/generate-doc.sh
index d8d01d3..45a9901 100755
--- a/generate-doc.sh
+++ b/generate-doc.sh
@@ -34,7 +34,7 @@ export FA_ICONS=true
 
 rm -rf build-doc
 mkdir build-doc && cd build-doc
-$src/configure --enable-gpl --disable-yasm || die "configure failed"
+$src/configure --enable-gpl --disable-asm || die "configure failed"
 make doc || die "doc not made"
 cp doc/*.html ../htdocs/ || die "copy failed"
 
-- 
2.25.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-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [ffmpeg-devel][PATCH] Encapsulation func to get width and height

2020-03-14 Thread Carl Eugen Hoyos
Am Sa., 14. März 2020 um 10:57 Uhr schrieb numberwolf :
>
> ---
>  libavcodec/mpegutils.c | 4 ++--
>  libavcodec/mpegutils.h | 3 +++
>  2 files changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/libavcodec/mpegutils.c b/libavcodec/mpegutils.c
> index c0ee3aa..819293c 100644
> --- a/libavcodec/mpegutils.c
> +++ b/libavcodec/mpegutils.c
> @@ -34,8 +34,8 @@ static int add_mb(AVMotionVector *mb, uint32_t mb_type,
>int motion_x, int motion_y, int motion_scale,
>int direction)
>  {
> -mb->w = IS_8X8(mb_type) || IS_8X16(mb_type) ? 8 : 16;
> -mb->h = IS_8X8(mb_type) || IS_16X8(mb_type) ? 8 : 16;
> +mb->w = MB_SIZE_WIDTH(mb_type);
> +mb->h = MB_SIZE_HEIGHT(mb_type);
>  mb->motion_x = motion_x;
>  mb->motion_y = motion_y;
>  mb->motion_scale = motion_scale;
> diff --git a/libavcodec/mpegutils.h b/libavcodec/mpegutils.h
> index 1ed21c1..ed59716 100644
> --- a/libavcodec/mpegutils.h
> +++ b/libavcodec/mpegutils.h
> @@ -95,6 +95,9 @@
>  #define IS_QUANT(a)  ((a) & MB_TYPE_QUANT)
>  #define IS_DIR(a, part, list) ((a) & (MB_TYPE_P0L0 << ((part) + 2 * (list
>
> +#define MB_SIZE_WIDTH(a)  (((a) & MB_TYPE_8x8) || ((a) & MB_TYPE_8x16)) 
> ? 8 : 16
> +#define MB_SIZE_HEIGHT(a) (((a) & MB_TYPE_8x8) || ((a) & MB_TYPE_16x8)) 
> ? 8 : 16

Doesn't this patch make the code less readable / isn't the existing macro
enough to easily understand above assignment?

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH v3] web/generate-doc.sh: use --disable-x86asm instead of --disable-yasm

2020-03-14 Thread Steven Liu


> 2020年3月14日 下午6:58,Carl Eugen Hoyos  写道:
> 
> Am Sa., 14. März 2020 um 09:08 Uhr schrieb Steven Liu :
>> 
>> Reviewed-by: Lou Logan 
>> Signed-off-by: Steven Liu 
>> ---
>> generate-doc.sh | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/generate-doc.sh b/generate-doc.sh
>> index d8d01d3..2da5e64 100755
>> --- a/generate-doc.sh
>> +++ b/generate-doc.sh
>> @@ -34,7 +34,7 @@ export FA_ICONS=true
>> 
>> rm -rf build-doc
>> mkdir build-doc && cd build-doc
>> -$src/configure --enable-gpl --disable-yasm || die "configure failed"
> 
>> +$src/configure --enable-gpl --disable-x86asm || die "configure failed"
> 
> Why isn't this "--disable-asm" which I expect to also work on (for
> example) windows arm64 if gas-preprocessor is not installed?
Ah, yes you are right, I should use disable-asm
> 
> Carl Eugen
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".



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

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

Re: [FFmpeg-devel] [PATCH v3] web/generate-doc.sh: use --disable-x86asm instead of --disable-yasm

2020-03-14 Thread Steven Liu


> 2020年3月14日 下午6:58,Carl Eugen Hoyos  写道:
> 
> Am Sa., 14. März 2020 um 09:08 Uhr schrieb Steven Liu :
>> 
>> Reviewed-by: Lou Logan 
>> Signed-off-by: Steven Liu 
>> ---
>> generate-doc.sh | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/generate-doc.sh b/generate-doc.sh
>> index d8d01d3..2da5e64 100755
>> --- a/generate-doc.sh
>> +++ b/generate-doc.sh
>> @@ -34,7 +34,7 @@ export FA_ICONS=true
>> 
>> rm -rf build-doc
>> mkdir build-doc && cd build-doc
>> -$src/configure --enable-gpl --disable-yasm || die "configure failed"
> 
>> +$src/configure --enable-gpl --disable-x86asm || die "configure failed"
> 
> Why isn't this "--disable-asm" which I expect to also work on (for
> example) windows arm64 if gas-preprocessor is not installed?
Hi  Carl,


Because when I use the command line:

liuqi05:web liuqi$ ./generate-doc.sh ~/multimedia/ffmpeg/

it tell me :

License: GPL version 2 or later

WARNING: The --disable-yasm option is only provided for compatibility and will 
be
 removed in the future. Use --enable-x86asm / --disable-x86asm instead.
GEN libavutil/libavutil.version

I think it need not use asm when just build documents.

Thanks

Steven

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

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

Re: [FFmpeg-devel] [PATCH 01/18] mpeg4videodec: do not copy a range of fields at once

2020-03-14 Thread Carl Eugen Hoyos
Am Fr., 13. März 2020 um 11:30 Uhr schrieb Anton Khirnov :
>
> This is extremely fragile against reordering and hides what is actually
> being copied. Copy all the fields manually instead.
> ---
>  libavcodec/mpeg4videodec.c | 27 ++-
>  1 file changed, 26 insertions(+), 1 deletion(-)
>
> diff --git a/libavcodec/mpeg4videodec.c b/libavcodec/mpeg4videodec.c
> index cc03486646..a51985d51b 100644
> --- a/libavcodec/mpeg4videodec.c
> +++ b/libavcodec/mpeg4videodec.c
> @@ -3460,7 +3460,32 @@ static int mpeg4_update_thread_context(AVCodecContext 
> *dst,
>  if (ret < 0)
>  return ret;
>
> -memcpy(((uint8_t*)s) + sizeof(MpegEncContext), ((uint8_t*)s1) + 
> sizeof(MpegEncContext), sizeof(Mpeg4DecContext) - sizeof(MpegEncContext));
> +s->time_increment_bits   = s1->time_increment_bits;
> +s->shape = s1->shape;
> +s->vol_sprite_usage  = s1->vol_sprite_usage;
> +s->sprite_brightness_change  = s1->sprite_brightness_change;
> +s->num_sprite_warping_points = s1->num_sprite_warping_points;
> +s->rvlc  = s1->rvlc;
> +s->resync_marker = s1->resync_marker;
> +s->t_frame   = s1->t_frame;
> +s->new_pred  = s1->new_pred;
> +s->enhancement_type  = s1->enhancement_type;
> +s->scalability   = s1->scalability;
> +s->use_intra_dc_vlc  = s1->use_intra_dc_vlc;
> +s->intra_dc_threshold= s1->intra_dc_threshold;
> +s->divx_version  = s1->divx_version;
> +s->divx_build= s1->divx_build;
> +s->xvid_build= s1->xvid_build;
> +s->lavc_build= s1->lavc_build;
> +s->showed_packed_warning = s1->showed_packed_warning;
> +s->vol_control_parameters= s1->vol_control_parameters;
> +s->cplx_estimation_trash_i   = s1->cplx_estimation_trash_i;
> +s->cplx_estimation_trash_p   = s1->cplx_estimation_trash_p;
> +s->cplx_estimation_trash_b   = s1->cplx_estimation_trash_b;
> +s->rgb   = s1->rgb;
> +
> +memcpy(s->sprite_shift, s1->sprite_shift, sizeof(s1->sprite_shift));
> +memcpy(s->sprite_traj,  s1->sprite_traj,  sizeof(s1->sprite_traj));

Am I really the only one who finds the code more "fragile" after this change?

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH] web/download: update min. kernel version for linux binaries

2020-03-14 Thread Carl Eugen Hoyos
Am Sa., 14. März 2020 um 07:31 Uhr schrieb Gyan Doshi :
>
> As per https://johnvansickle.com/ffmpeg/
> ---
>  src/download | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/download b/src/download
> index 6292a7e..d9155ee 100644
> --- a/src/download
> +++ b/src/download
> @@ -70,7 +70,7 @@
>  Linux Static Builds
>  
> href="https://johnvansickle.com/ffmpeg/;>32-bit and
> -64-bit for kernel 2.6.32 and above
> +64-bit for kernel 3.2.0 and above

Shouldn't we instead remove the line?

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH v3] web/generate-doc.sh: use --disable-x86asm instead of --disable-yasm

2020-03-14 Thread Carl Eugen Hoyos
Am Sa., 14. März 2020 um 09:08 Uhr schrieb Steven Liu :
>
> Reviewed-by: Lou Logan 
> Signed-off-by: Steven Liu 
> ---
>  generate-doc.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/generate-doc.sh b/generate-doc.sh
> index d8d01d3..2da5e64 100755
> --- a/generate-doc.sh
> +++ b/generate-doc.sh
> @@ -34,7 +34,7 @@ export FA_ICONS=true
>
>  rm -rf build-doc
>  mkdir build-doc && cd build-doc
> -$src/configure --enable-gpl --disable-yasm || die "configure failed"

> +$src/configure --enable-gpl --disable-x86asm || die "configure failed"

Why isn't this "--disable-asm" which I expect to also work on (for
example) windows arm64 if gas-preprocessor is not installed?

Carl Eugen
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

Re: [FFmpeg-devel] [PATCH][GSOC] avfilter: add atone filter

2020-03-14 Thread Paul B Mahol
Please follow coding style from http://ffmpeg.org/developer.html

Otherwise patch looks fine.
Could you make note on/off switching not depend on number of output
samples per frame?

On 3/14/20, Marshall Murmu  wrote:
>  Author:Marshall Murmu 
>
>
> ---
>  Changelog|   1 +
>  configure|   4 +
>  doc/filters.texi |  29 +++
>  libavfilter/Makefile |   1 +
>  libavfilter/allfilters.c |   1 +
>  libavfilter/asrc_atone.c | 172 +++
>  libavfilter/version.h|   2 +-
>  7 files changed, 209 insertions(+), 1 deletion(-)
>  create mode 100644 libavfilter/asrc_atone.c
>
> diff --git a/Changelog b/Changelog
> index d1572553a5..5ddd2484b0 100644
> --- a/Changelog
> +++ b/Changelog
> @@ -48,6 +48,7 @@ version :
>  - AMQP 0-9-1 protocol (RabbitMQ)
>  - Vulkan support
>  - avgblur_vulkan, overlay_vulkan, scale_vulkan and chromaber_vulkan filters
> +- atone filter
>
>
>  version 4.2:
> diff --git a/configure b/configure
> index 6ceb0c7af4..be48a22770 100755
> --- a/configure
> +++ b/configure
> @@ -233,6 +233,7 @@ External library support:
> and libraw1394 [no]
>--enable-libfdk-aac  enable AAC de/encoding via libfdk-aac [no]
>--enable-libfliteenable flite (voice synthesis) support via
> libflite [no]
> +  --enable-libfluidsynth   enable fluidsynth support via libfluidsynth [no]
>--enable-libfontconfig   enable libfontconfig, useful for drawtext filter
> [no]
>--enable-libfreetype enable libfreetype, needed for drawtext filter
> [no]
>--enable-libfribidi  enable libfribidi, improves drawtext filter [no]
> @@ -1770,6 +1771,7 @@ EXTERNAL_LIBRARY_LIST="
>  libdc1394
>  libdrm
>  libflite
> +libfluidsynth
>  libfontconfig
>  libfreetype
>  libfribidi
> @@ -3465,6 +3467,7 @@ asr_filter_deps="pocketsphinx"
>  ass_filter_deps="libass"
>  atempo_filter_deps="avcodec"
>  atempo_filter_select="rdft"
> +atone_filter_deps="libfluidsynth"
>  avgblur_opencl_filter_deps="opencl"
>  avgblur_vulkan_filter_deps="vulkan libglslang"
>  azmq_filter_deps="libzmq"
> @@ -6270,6 +6273,7 @@ enabled libfdk_aac&& { check_pkg_config
> libfdk_aac fdk-aac "fdk-aac/aace
>   warn "using libfdk without pkg-config"; }
> }
>  flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal
> -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish
> -lflite_cmulex -lflite"
>  enabled libflite  && require libflite "flite/flite.h" flite_init
> $flite_extralibs
> +enabled libfluidsynth && require_pkg_config libfluidsynth fluidsynth
> "fluidsynth.h" fluid_log
>  enabled fontconfig&& enable libfontconfig
>  enabled libfontconfig && require_pkg_config libfontconfig fontconfig
> "fontconfig/fontconfig.h" FcInit
>  enabled libfreetype   && require_pkg_config libfreetype freetype2
> "ft2build.h FT_FREETYPE_H" FT_Init_FreeType
> diff --git a/doc/filters.texi b/doc/filters.texi
> index 328e984e92..0ef3e83e65 100644
> --- a/doc/filters.texi
> +++ b/doc/filters.texi
> @@ -5946,6 +5946,35 @@ anullsrc=r=48000:cl=mono
>
>  All the parameters need to be explicitly defined.
>
> +@section atone
> +
> +Synthesize random notes using libfluidsynth library.
> +
> +To compile this filter you need to configure FFmpeg with
> +@code{--enable-libfluidsynth}.
> +
> +The filter accepts the following options:
> +
> +@table @option
> +@item sample_rate, r
> +Set the sample rate of the synthesizer. Default value is 44100.
> +
> +@item nb_samples, n
> +Set the number of samples per frame. Default value is 1024.
> +
> +@item duration, d
> +Set the duration of sound generation. Default value is 10 sec.
> +
> +@item soundfont
> +Enter the location of the soundfont. Without loading the soundfont
> fluidsynth won't be able to synthesize.
> +
> +@item chan
> +Set the MIDI channel. Default value is 0.
> +
> +@item seed
> +Set the seed value for the PRNG
> +@end table
> +
>  @section flite
>
>  Synthesize a voice utterance using the libflite library.
> diff --git a/libavfilter/Makefile b/libavfilter/Makefile
> index 750412da6b..020c4553cb 100644
> --- a/libavfilter/Makefile
> +++ b/libavfilter/Makefile
> @@ -147,6 +147,7 @@ OBJS-$(CONFIG_AEVALSRC_FILTER)   += aeval.o
>  OBJS-$(CONFIG_AFIRSRC_FILTER)+= asrc_afirsrc.o
>  OBJS-$(CONFIG_ANOISESRC_FILTER)  += asrc_anoisesrc.o
>  OBJS-$(CONFIG_ANULLSRC_FILTER)   += asrc_anullsrc.o
> +OBJS-$(CONFIG_ATONE_FILTER)  += asrc_atone.o
>  OBJS-$(CONFIG_FLITE_FILTER)  += asrc_flite.o
>  OBJS-$(CONFIG_HILBERT_FILTER)+= asrc_hilbert.o
>  OBJS-$(CONFIG_SINC_FILTER)   += asrc_sinc.o
> diff --git a/libavfilter/allfilters.c b/libavfilter/allfilters.c
> index 501e5d041b..d167499cf1 100644
> --- a/libavfilter/allfilters.c
> +++ b/libavfilter/allfilters.c
> @@ -141,6 +141,7 @@ 

[FFmpeg-devel] [PATCH][GSOC] avfilter: add atone filter

2020-03-14 Thread Marshall Murmu
 Author:Marshall Murmu 


---
 Changelog|   1 +
 configure|   4 +
 doc/filters.texi |  29 +++
 libavfilter/Makefile |   1 +
 libavfilter/allfilters.c |   1 +
 libavfilter/asrc_atone.c | 172 +++
 libavfilter/version.h|   2 +-
 7 files changed, 209 insertions(+), 1 deletion(-)
 create mode 100644 libavfilter/asrc_atone.c

diff --git a/Changelog b/Changelog
index d1572553a5..5ddd2484b0 100644
--- a/Changelog
+++ b/Changelog
@@ -48,6 +48,7 @@ version :
 - AMQP 0-9-1 protocol (RabbitMQ)
 - Vulkan support
 - avgblur_vulkan, overlay_vulkan, scale_vulkan and chromaber_vulkan filters
+- atone filter
 
 
 version 4.2:
diff --git a/configure b/configure
index 6ceb0c7af4..be48a22770 100755
--- a/configure
+++ b/configure
@@ -233,6 +233,7 @@ External library support:
and libraw1394 [no]
   --enable-libfdk-aac  enable AAC de/encoding via libfdk-aac [no]
   --enable-libfliteenable flite (voice synthesis) support via libflite 
[no]
+  --enable-libfluidsynth   enable fluidsynth support via libfluidsynth [no]
   --enable-libfontconfig   enable libfontconfig, useful for drawtext filter 
[no]
   --enable-libfreetype enable libfreetype, needed for drawtext filter [no]
   --enable-libfribidi  enable libfribidi, improves drawtext filter [no]
@@ -1770,6 +1771,7 @@ EXTERNAL_LIBRARY_LIST="
 libdc1394
 libdrm
 libflite
+libfluidsynth
 libfontconfig
 libfreetype
 libfribidi
@@ -3465,6 +3467,7 @@ asr_filter_deps="pocketsphinx"
 ass_filter_deps="libass"
 atempo_filter_deps="avcodec"
 atempo_filter_select="rdft"
+atone_filter_deps="libfluidsynth"
 avgblur_opencl_filter_deps="opencl"
 avgblur_vulkan_filter_deps="vulkan libglslang"
 azmq_filter_deps="libzmq"
@@ -6270,6 +6273,7 @@ enabled libfdk_aac&& { check_pkg_config 
libfdk_aac fdk-aac "fdk-aac/aace
  warn "using libfdk without pkg-config"; } }
 flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal 
-lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish 
-lflite_cmulex -lflite"
 enabled libflite  && require libflite "flite/flite.h" flite_init 
$flite_extralibs
+enabled libfluidsynth && require_pkg_config libfluidsynth fluidsynth 
"fluidsynth.h" fluid_log
 enabled fontconfig&& enable libfontconfig
 enabled libfontconfig && require_pkg_config libfontconfig fontconfig 
"fontconfig/fontconfig.h" FcInit
 enabled libfreetype   && require_pkg_config libfreetype freetype2 
"ft2build.h FT_FREETYPE_H" FT_Init_FreeType
diff --git a/doc/filters.texi b/doc/filters.texi
index 328e984e92..0ef3e83e65 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -5946,6 +5946,35 @@ anullsrc=r=48000:cl=mono
 
 All the parameters need to be explicitly defined.
 
+@section atone
+
+Synthesize random notes using libfluidsynth library.
+
+To compile this filter you need to configure FFmpeg with
+@code{--enable-libfluidsynth}.
+
+The filter accepts the following options:
+
+@table @option
+@item sample_rate, r
+Set the sample rate of the synthesizer. Default value is 44100.
+
+@item nb_samples, n
+Set the number of samples per frame. Default value is 1024.
+
+@item duration, d
+Set the duration of sound generation. Default value is 10 sec.
+
+@item soundfont
+Enter the location of the soundfont. Without loading the soundfont fluidsynth 
won't be able to synthesize.
+
+@item chan
+Set the MIDI channel. Default value is 0.
+
+@item seed
+Set the seed value for the PRNG
+@end table
+
 @section flite
 
 Synthesize a voice utterance using the libflite library.
diff --git a/libavfilter/Makefile b/libavfilter/Makefile
index 750412da6b..020c4553cb 100644
--- a/libavfilter/Makefile
+++ b/libavfilter/Makefile
@@ -147,6 +147,7 @@ OBJS-$(CONFIG_AEVALSRC_FILTER)   += aeval.o
 OBJS-$(CONFIG_AFIRSRC_FILTER)+= asrc_afirsrc.o
 OBJS-$(CONFIG_ANOISESRC_FILTER)  += asrc_anoisesrc.o
 OBJS-$(CONFIG_ANULLSRC_FILTER)   += asrc_anullsrc.o
+OBJS-$(CONFIG_ATONE_FILTER)  += asrc_atone.o
 OBJS-$(CONFIG_FLITE_FILTER)  += asrc_flite.o
 OBJS-$(CONFIG_HILBERT_FILTER)+= asrc_hilbert.o
 OBJS-$(CONFIG_SINC_FILTER)   += asrc_sinc.o
diff --git a/libavfilter/allfilters.c b/libavfilter/allfilters.c
index 501e5d041b..d167499cf1 100644
--- a/libavfilter/allfilters.c
+++ b/libavfilter/allfilters.c
@@ -141,6 +141,7 @@ extern AVFilter ff_asrc_aevalsrc;
 extern AVFilter ff_asrc_afirsrc;
 extern AVFilter ff_asrc_anoisesrc;
 extern AVFilter ff_asrc_anullsrc;
+extern AVFilter ff_asrc_atone;
 extern AVFilter ff_asrc_flite;
 extern AVFilter ff_asrc_hilbert;
 extern AVFilter ff_asrc_sinc;
diff --git a/libavfilter/asrc_atone.c b/libavfilter/asrc_atone.c
new file mode 100644
index 00..f3ebab906e
--- /dev/null
+++ b/libavfilter/asrc_atone.c
@@ -0,0 +1,172 @@
+/*
+ * This 

Re: [FFmpeg-devel] [PATCH v3 7/7] avformat/audiointerleave: use a fixed frame duration for non-audio packets

2020-03-14 Thread Tomas Härdin
fre 2020-03-13 klockan 02:31 +0100 skrev Marton Balint:
> The packet durations might not be set properly which can cause the MXF muxer
> to write more than one packet of a stream to an edit unit messing up the
> constant byte per element index...

Shouldn't this be fixed "higher up"?

> Also warn the user if the incoming DTS is not increasing by frame duration
> because in that case A-V sync issues can occur because of the DTS rewriting.

I'm not a huge fan of this, shouldn't we investigate why this happens
instead? DTS being non-monotonic is a big deal

> Also use nb_samples directly to calculate dts of audio packets because adding
> packet durations might not be precise.

lavf is such a mess...

The patch itself looks fine, modulo the above concerns

/Tomas

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

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

Re: [FFmpeg-devel] [PATCH] avformat/mxfenc: Reorder fields in MXFIndexEntry to make it smaller

2020-03-14 Thread Tomas Härdin
fre 2020-03-13 klockan 11:18 +0100 skrev Andreas Rheinhardt:
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/mxfenc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c
> index 5e0dc0e889..55c715d776 100644
> --- a/libavformat/mxfenc.c
> +++ b/libavformat/mxfenc.c
> @@ -72,10 +72,10 @@ typedef struct MXFLocalTagPair {
>  } MXFLocalTagPair;
>  
>  typedef struct MXFIndexEntry {
> -uint8_t flags;
>  uint64_t offset;
>  unsigned slice_offset; ///< offset of audio slice
>  uint16_t temporal_ref;
> +uint8_t flags;
>  } MXFIndexEntry;
>  
>  typedef struct MXFStreamContext {

Good catch. Looks fine. I took a look at the fields in the struck, and
it doesn't seem like we can shrink any of them without limiting what
the muxer can currently do.

/Tomas

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

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

Re: [FFmpeg-devel] [PATCH v2 6/7] avformat/mxfenc: allow all frame rates if -strict mode is set to unofficial or lower

2020-03-14 Thread Tomas Härdin
tor 2020-03-12 klockan 22:21 +0100 skrev Marton Balint:
> 
> On Sat, 7 Mar 2020, Tomas Härdin wrote:
> 
> > tor 2020-03-05 klockan 22:56 +0100 skrev Marton Balint:
> > > There was no consensus wheter or not to allow unofficial frame rates due 
> > > to
> > > possible interoperability issues, a compromise is to only allow it if 
> > > -strict
> > > mode is set to unofficial.
> > > 
> > > Signed-off-by: Marton Balint 
> > > ---
> > >  libavformat/mxfenc.c | 8 ++--
> > >  1 file changed, 6 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c
> > > index 51e2dc5f31..6279ba9d6d 100644
> > > --- a/libavformat/mxfenc.c
> > > +++ b/libavformat/mxfenc.c
> > > @@ -2413,8 +2413,12 @@ static int mxf_init_timecode(AVFormatContext *s, 
> > > AVStream *st, AVRational tbc)
> > >  AVDictionaryEntry *tcr = av_dict_get(s->metadata, "timecode", NULL, 
> > > 0);
> > > 
> > >  if (!ff_mxf_get_content_package_rate(tbc)) {
> > > -av_log(s, AV_LOG_ERROR, "Unsupported frame rate %d/%d\n", 
> > > tbc.den, tbc.num);
> > > -return AVERROR(EINVAL);
> > > +if (s->strict_std_compliance > FF_COMPLIANCE_UNOFFICIAL) {
> > > +av_log(s, AV_LOG_ERROR, "Unsupported frame rate %d/%d. Set 
> > > -strict option to 'unofficial' or lower in order to allow it!\n", 
> > > tbc.den, tbc.num);
> > > +return AVERROR(EINVAL);
> > > +} else {
> > > +av_log(s, AV_LOG_WARNING, "Unofficial frame rate %d/%d.\n", 
> > > tbc.den, tbc.num);
> > > +}
> > 
> > This can work. That way we make it clear to users that here be dragons
> 
> Thanks, it seems there are no further comments for patches 1-6, so I plan 
> to apply them soon.


/Tomas

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

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

[FFmpeg-devel] [ffmpeg-devel][PATCH] Encapsulation func to get width and height

2020-03-14 Thread numberwolf
---
 libavcodec/mpegutils.c | 4 ++--
 libavcodec/mpegutils.h | 3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mpegutils.c b/libavcodec/mpegutils.c
index c0ee3aa..819293c 100644
--- a/libavcodec/mpegutils.c
+++ b/libavcodec/mpegutils.c
@@ -34,8 +34,8 @@ static int add_mb(AVMotionVector *mb, uint32_t mb_type,
   int motion_x, int motion_y, int motion_scale,
   int direction)
 {
-mb->w = IS_8X8(mb_type) || IS_8X16(mb_type) ? 8 : 16;
-mb->h = IS_8X8(mb_type) || IS_16X8(mb_type) ? 8 : 16;
+mb->w = MB_SIZE_WIDTH(mb_type);
+mb->h = MB_SIZE_HEIGHT(mb_type);
 mb->motion_x = motion_x;
 mb->motion_y = motion_y;
 mb->motion_scale = motion_scale;
diff --git a/libavcodec/mpegutils.h b/libavcodec/mpegutils.h
index 1ed21c1..ed59716 100644
--- a/libavcodec/mpegutils.h
+++ b/libavcodec/mpegutils.h
@@ -95,6 +95,9 @@
 #define IS_QUANT(a)  ((a) & MB_TYPE_QUANT)
 #define IS_DIR(a, part, list) ((a) & (MB_TYPE_P0L0 << ((part) + 2 * (list
 
+#define MB_SIZE_WIDTH(a)  (((a) & MB_TYPE_8x8) || ((a) & MB_TYPE_8x16)) ? 
8 : 16
+#define MB_SIZE_HEIGHT(a) (((a) & MB_TYPE_8x8) || ((a) & MB_TYPE_16x8)) ? 
8 : 16
+
 // does this mb use listX, note does not work if subMBs
 #define USES_LIST(a, list) ((a) & ((MB_TYPE_P0L0 | MB_TYPE_P1L0) << (2 * 
(list
 
-- 
2.17.2 (Apple Git-113)

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

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

[FFmpeg-devel] [PATCH v3] web/generate-doc.sh: use --disable-x86asm instead of --disable-yasm

2020-03-14 Thread Steven Liu
Reviewed-by: Lou Logan 
Signed-off-by: Steven Liu 
---
 generate-doc.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/generate-doc.sh b/generate-doc.sh
index d8d01d3..2da5e64 100755
--- a/generate-doc.sh
+++ b/generate-doc.sh
@@ -34,7 +34,7 @@ export FA_ICONS=true
 
 rm -rf build-doc
 mkdir build-doc && cd build-doc
-$src/configure --enable-gpl --disable-yasm || die "configure failed"
+$src/configure --enable-gpl --disable-x86asm || die "configure failed"
 make doc || die "doc not made"
 cp doc/*.html ../htdocs/ || die "copy failed"
 
-- 
2.25.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-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH v2] web/generate-doc.sh: use --enable-x86asm instead of --disable-yasm

2020-03-14 Thread Steven Liu


> 2020年3月14日 下午3:08,Hendrik Leppkes  写道:
> 
> On Sat, Mar 14, 2020 at 2:37 AM Steven Liu  wrote:
>> 
>> Reviewed-by: Lou Logan 
>> Signed-off-by: Steven Liu 
>> ---
>> generate-doc.sh | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> diff --git a/generate-doc.sh b/generate-doc.sh
>> index d8d01d3..e316c05 100755
>> --- a/generate-doc.sh
>> +++ b/generate-doc.sh
>> @@ -34,7 +34,7 @@ export FA_ICONS=true
>> 
>> rm -rf build-doc
>> mkdir build-doc && cd build-doc
>> -$src/configure --enable-gpl --disable-yasm || die "configure failed"
>> +$src/configure --enable-gpl --enable-x86asm || die "configure failed"
>> make doc || die "doc not made"
>> cp doc/*.html ../htdocs/ || die "copy failed"
>> 
> 
Before patch output is attached
> These options do quite
Do you mean add --quiet option in this line?

> the opposite of each other, perhaps then
> neither should be used?
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe”.


Thanks

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

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

Re: [FFmpeg-devel] [PATCH v2] web/generate-doc.sh: use --enable-x86asm instead of --disable-yasm

2020-03-14 Thread Hendrik Leppkes
On Sat, Mar 14, 2020 at 2:37 AM Steven Liu  wrote:
>
> Reviewed-by: Lou Logan 
> Signed-off-by: Steven Liu 
> ---
>  generate-doc.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/generate-doc.sh b/generate-doc.sh
> index d8d01d3..e316c05 100755
> --- a/generate-doc.sh
> +++ b/generate-doc.sh
> @@ -34,7 +34,7 @@ export FA_ICONS=true
>
>  rm -rf build-doc
>  mkdir build-doc && cd build-doc
> -$src/configure --enable-gpl --disable-yasm || die "configure failed"
> +$src/configure --enable-gpl --enable-x86asm || die "configure failed"
>  make doc || die "doc not made"
>  cp doc/*.html ../htdocs/ || die "copy failed"
>

These options do quite the opposite of each other, perhaps then
neither should be used?
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

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

[FFmpeg-devel] [PATCH] web/download: update min. kernel version for linux binaries

2020-03-14 Thread Gyan Doshi
As per https://johnvansickle.com/ffmpeg/
---
 src/download | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/download b/src/download
index 6292a7e..d9155ee 100644
--- a/src/download
+++ b/src/download
@@ -70,7 +70,7 @@
 Linux Static Builds
 
   https://johnvansickle.com/ffmpeg/;>32-bit and
-64-bit for kernel 2.6.32 and above
+64-bit for kernel 3.2.0 and above
  
 

-- 
2.25.1

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

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

Re: [FFmpeg-devel] [PATCH] doc/muxers: add missing MOV muxer options

2020-03-14 Thread Gyan Doshi



On 13-03-2020 10:02 am, Gyan Doshi wrote:



On 13-03-2020 12:08 am, Lou Logan wrote:

Signed-off-by: Lou Logan 
---
The options for this muxer have a separate section about fragmenting.
I tried to organize the missing options into the proper sections, but
I don't use fragmenting so I may have placed them in the wrong section.


I already started on this after I added the MOV demuxer options.

But this is a good start. I'll probably want to expand descriptions 
later on.


Will have a look and push this weekend.


Do you mind if I continue with my own patch? I started reviewing this 
and noticed that many of the option description should have caveats 
since they can be silently (i.e. unlogged) modified based on other 
options. I think it's best for me to walk the code and check.


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

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