Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-19 Thread Nicolas George
Le primidi 1er prairial, an CCXXIV, Michael Niedermayer a écrit : > applications which supported both libav and ffmpeg cannot use symbols > that exist in only one of the forks as it would break linking. > > the same AVOption based code works with both forks though > > using accessors 2 different

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-19 Thread James Almer
On 5/19/2016 11:38 AM, Ronald S. Bultje wrote: > Hi, > > On Thu, May 19, 2016 at 8:14 AM, Michael Niedermayer > wrote: > >> On Thu, May 19, 2016 at 12:08:25PM +0200, Nicolas George wrote: >>> Le nonidi 29 floréal, an CCXXIV, Michael Niedermayer a écrit : there where and are accessor function

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-19 Thread Ronald S. Bultje
Hi, On Thu, May 19, 2016 at 8:14 AM, Michael Niedermayer wrote: > On Thu, May 19, 2016 at 12:08:25PM +0200, Nicolas George wrote: > > Le nonidi 29 floréal, an CCXXIV, Michael Niedermayer a écrit : > > > there where and are accessor functions: > > > git grep MAKE_ACCESSORS > > > > Yes, and they s

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-19 Thread Michael Niedermayer
On Thu, May 19, 2016 at 12:08:25PM +0200, Nicolas George wrote: > Le nonidi 29 floréal, an CCXXIV, Michael Niedermayer a écrit : > > there where and are accessor functions: > > git grep MAKE_ACCESSORS > > Yes, and they should have been the only way of avoiding ABI compatibility > issues. applicat

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-19 Thread Nicolas George
Le nonidi 29 floréal, an CCXXIV, Michael Niedermayer a écrit : > there where and are accessor functions: > git grep MAKE_ACCESSORS Yes, and they should have been the only way of avoiding ABI compatibility issues. Another point against AVClass: FFmpeg is mostly in C, C has static typing and static

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-18 Thread Michael Niedermayer
On Tue, May 17, 2016 at 06:49:44AM -0400, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 6:07 AM, Michael Niedermayer > wrote: > > > Most of the major public structures contain an AVClass. > > > What are you hoping to accomplish with this struct that can currently not > be done beca

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
On Tue, May 17, 2016 at 07:08:42PM +0200, Michael Niedermayer wrote: > On Tue, May 17, 2016 at 12:26:18PM -0400, Ronald S. Bultje wrote: > > Hi, > > > > On Tue, May 17, 2016 at 11:18 AM, Michael Niedermayer < > > mich...@niedermayer.cc> wrote: > > > > > AVCodecContext contains all the fields that

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
On Tue, May 17, 2016 at 10:00:38PM +0200, Nicolas George wrote: > Le nonidi 29 floréal, an CCXXIV, Ronald S. Bultje a écrit : > > It's not for us (ffmpeg.c developers), it's for people using the ffmpeg > > libraries on other language platforms (e.g. python). > > I think one of the cruxes of the is

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Nicolas George
Le nonidi 29 floréal, an CCXXIV, Ronald S. Bultje a écrit : > It's not for us (ffmpeg.c developers), it's for people using the ffmpeg > libraries on other language platforms (e.g. python). I think one of the cruxes of the issue is that we are (ab)using the AVOption system for two different things:

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Hendrik Leppkes
On Tue, May 17, 2016 at 9:04 PM, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 2:29 PM, Hendrik Leppkes > wrote: > >> On Tue, May 17, 2016 at 7:46 PM, Ronald S. Bultje >> wrote: >> > Hi, >> > >> > On Tue, May 17, 2016 at 1:24 PM, Hendrik Leppkes >> > wrote: >> > >> >> On Tue, May 17

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Ronald S. Bultje
Hi, On Tue, May 17, 2016 at 2:29 PM, Hendrik Leppkes wrote: > On Tue, May 17, 2016 at 7:46 PM, Ronald S. Bultje > wrote: > > Hi, > > > > On Tue, May 17, 2016 at 1:24 PM, Hendrik Leppkes > > wrote: > > > >> On Tue, May 17, 2016 at 7:22 PM, Ronald S. Bultje > >> wrote: > >> > Hi, > >> > > >> >

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Hendrik Leppkes
On Tue, May 17, 2016 at 7:46 PM, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 1:24 PM, Hendrik Leppkes > wrote: > >> On Tue, May 17, 2016 at 7:22 PM, Ronald S. Bultje >> wrote: >> > Hi, >> > >> > On Tue, May 17, 2016 at 12:34 PM, Hendrik Leppkes >> > wrote: >> > >> >> On Tue, May 1

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Ronald S. Bultje
Hi, On Tue, May 17, 2016 at 1:24 PM, Hendrik Leppkes wrote: > On Tue, May 17, 2016 at 7:22 PM, Ronald S. Bultje > wrote: > > Hi, > > > > On Tue, May 17, 2016 at 12:34 PM, Hendrik Leppkes > > wrote: > > > >> On Tue, May 17, 2016 at 6:26 PM, Ronald S. Bultje > >> wrote: > >> > Hi, > >> > > >> >

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Hendrik Leppkes
On Tue, May 17, 2016 at 7:22 PM, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 12:34 PM, Hendrik Leppkes > wrote: > >> On Tue, May 17, 2016 at 6:26 PM, Ronald S. Bultje >> wrote: >> > Hi, >> > >> > On Tue, May 17, 2016 at 11:18 AM, Michael Niedermayer < >> > mich...@niedermayer.cc> w

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Ronald S. Bultje
Hi, On Tue, May 17, 2016 at 12:34 PM, Hendrik Leppkes wrote: > On Tue, May 17, 2016 at 6:26 PM, Ronald S. Bultje > wrote: > > Hi, > > > > On Tue, May 17, 2016 at 11:18 AM, Michael Niedermayer < > > mich...@niedermayer.cc> wrote: > > > >> AVCodecContext contains all the fields that AVCodecParame

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
On Tue, May 17, 2016 at 12:26:18PM -0400, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 11:18 AM, Michael Niedermayer < > mich...@niedermayer.cc> wrote: > > > AVCodecContext contains all the fields that AVCodecParameters has. > > Examples are width, height, bitrate, profile, sample_ra

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Hendrik Leppkes
On Tue, May 17, 2016 at 6:26 PM, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 11:18 AM, Michael Niedermayer < > mich...@niedermayer.cc> wrote: > >> AVCodecContext contains all the fields that AVCodecParameters has. >> Examples are width, height, bitrate, profile, sample_rate, channels

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Ronald S. Bultje
Hi, On Tue, May 17, 2016 at 11:18 AM, Michael Niedermayer < mich...@niedermayer.cc> wrote: > AVCodecContext contains all the fields that AVCodecParameters has. > Examples are width, height, bitrate, profile, sample_rate, channels > > In AVCodecContext these fields are accessible through AVOptions

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
On Tue, May 17, 2016 at 10:21:51AM -0400, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 10:04 AM, Michael Niedermayer < > mich...@niedermayer.cc> wrote: > > > On Tue, May 17, 2016 at 06:49:44AM -0400, Ronald S. Bultje wrote: > > > Hi, > > > > > > On Tue, May 17, 2016 at 6:07 AM, Micha

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Ronald S. Bultje
Hi, On Tue, May 17, 2016 at 10:04 AM, Michael Niedermayer < mich...@niedermayer.cc> wrote: > On Tue, May 17, 2016 at 06:49:44AM -0400, Ronald S. Bultje wrote: > > Hi, > > > > On Tue, May 17, 2016 at 6:07 AM, Michael Niedermayer > > > wrote: > > > > > Most of the major public structures contain a

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
On Tue, May 17, 2016 at 06:49:44AM -0400, Ronald S. Bultje wrote: > Hi, > > On Tue, May 17, 2016 at 6:07 AM, Michael Niedermayer > wrote: > > > Most of the major public structures contain an AVClass. > > > What are you hoping to accomplish with this struct that can currently not > be done beca

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Ronald S. Bultje
Hi, On Tue, May 17, 2016 at 6:07 AM, Michael Niedermayer wrote: > Most of the major public structures contain an AVClass. What are you hoping to accomplish with this struct that can currently not be done because it doesn't have an AVClass on top? I haven't seen this question answered anywhere

[FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
Most of the major public structures contain an AVClass. We can add the AVClass now as there has been no release with AVCodecParameters after the next release this change would require a major version bump TODO: bump minor version TODO: update APIChanges Signed-off-by: Michael Niedermayer --- li

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-17 Thread Michael Niedermayer
On Tue, May 10, 2016 at 10:40:50PM +0200, wm4 wrote: > On Tue, 10 May 2016 22:21:12 +0200 (CEST) > Marton Balint wrote: > > > On Tue, 10 May 2016, Michael Niedermayer wrote: > > > > > On Tue, May 10, 2016 at 03:53:31PM +0200, wm4 wrote: > > >> On Tue, 10 May 2016 14:35:02 +0200 > > >> Michael

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-15 Thread wm4
On Sat, 14 May 2016 23:34:19 +0200 Michael Niedermayer wrote: > I would not call AVOption crazy nor useless It has its uses, but using AVOption as generic accessor API inconsistently on top of a "native" C API is pretty crazy. ___ ffmpeg-devel mailing

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-14 Thread Michael Niedermayer
On Tue, May 10, 2016 at 10:40:50PM +0200, wm4 wrote: > On Tue, 10 May 2016 22:21:12 +0200 (CEST) > Marton Balint wrote: > > > On Tue, 10 May 2016, Michael Niedermayer wrote: > > > > > On Tue, May 10, 2016 at 03:53:31PM +0200, wm4 wrote: > > >> On Tue, 10 May 2016 14:35:02 +0200 > > >> Michael

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread wm4
On Tue, 10 May 2016 22:21:12 +0200 (CEST) Marton Balint wrote: > On Tue, 10 May 2016, Michael Niedermayer wrote: > > > On Tue, May 10, 2016 at 03:53:31PM +0200, wm4 wrote: > >> On Tue, 10 May 2016 14:35:02 +0200 > >> Michael Niedermayer wrote: > >> > >>> On Tue, May 10, 2016 at 02:02:52PM +

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Marton Balint
On Tue, 10 May 2016, Michael Niedermayer wrote: On Tue, May 10, 2016 at 03:53:31PM +0200, wm4 wrote: On Tue, 10 May 2016 14:35:02 +0200 Michael Niedermayer wrote: On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer wrote:

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread wm4
On Tue, 10 May 2016 14:59:18 +0100 Derek Buitenhuis wrote: > On 5/10/2016 2:53 PM, wm4 wrote: > > Indeed, av_opt calls on structs which don't support it compile without > > warning, but mysteriously crash at runtime. That's a violation of this > > principle. And no, it doesn't mean that every str

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Michael Niedermayer
On Tue, May 10, 2016 at 03:39:09PM +0200, Hendrik Leppkes wrote: > On Tue, May 10, 2016 at 2:35 PM, Michael Niedermayer > wrote: > > On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: > >> On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer > >> wrote: > >> > On Tue, May 10, 2016 a

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Michael Niedermayer
On Tue, May 10, 2016 at 03:53:31PM +0200, wm4 wrote: > On Tue, 10 May 2016 14:35:02 +0200 > Michael Niedermayer wrote: > > > On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: > > > On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer > > > wrote: > > > > On Tue, May 10, 2016 at

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Michael Niedermayer
On Tue, May 10, 2016 at 03:56:18PM +0200, Hendrik Leppkes wrote: > On Tue, May 10, 2016 at 2:10 PM, Michael Niedermayer > wrote: > > > > libavformat gathers information about streams in av_find_stream_info() > > and that is all information completely unneeded by decoders > > no decoder needs the w

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Derek Buitenhuis
On 5/10/2016 2:53 PM, wm4 wrote: > Indeed, av_opt calls on structs which don't support it compile without > warning, but mysteriously crash at runtime. That's a violation of this > principle. And no, it doesn't mean that every struct should have an > AVClass, because that would be insane. Is there

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Hendrik Leppkes
On Tue, May 10, 2016 at 2:10 PM, Michael Niedermayer wrote: > > libavformat gathers information about streams in av_find_stream_info() > and that is all information completely unneeded by decoders > no decoder needs the width and height from the parser run by > av_find_stream_info() or other field

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread wm4
On Tue, 10 May 2016 14:35:02 +0200 Michael Niedermayer wrote: > On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: > > On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer > > wrote: > > > On Tue, May 10, 2016 at 11:17:12AM +0100, Derek Buitenhuis wrote: > > >> On 5/10/2016 7:2

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Paul B Mahol
On 5/10/16, Hendrik Leppkes wrote: > On Tue, May 10, 2016 at 2:35 PM, Michael Niedermayer > wrote: >> On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: >>> On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer >>> wrote: >>> > On Tue, May 10, 2016 at 11:17:12AM +0100, Derek Buitenh

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Hendrik Leppkes
On Tue, May 10, 2016 at 2:35 PM, Michael Niedermayer wrote: > On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: >> On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer >> wrote: >> > On Tue, May 10, 2016 at 11:17:12AM +0100, Derek Buitenhuis wrote: >> >> On 5/10/2016 7:24 AM, Hendr

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Michael Niedermayer
On Tue, May 10, 2016 at 02:02:52PM +0200, Hendrik Leppkes wrote: > On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer > wrote: > > On Tue, May 10, 2016 at 11:17:12AM +0100, Derek Buitenhuis wrote: > >> On 5/10/2016 7:24 AM, Hendrik Leppkes wrote: > >> > I don't like this, the struct is pretty cl

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Carl Eugen Hoyos
Michael Niedermayer niedermayer.cc> writes: > libavformat gathers information about streams in av_find_stream_info() > and that is all information completely unneeded by decoders > no decoder needs the width and height from the parser run by > av_find_stream_info() or other fields. Didn't Hendri

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Michael Niedermayer
On Tue, May 10, 2016 at 08:24:35AM +0200, Hendrik Leppkes wrote: > On Tue, May 10, 2016 at 2:07 AM, Michael Niedermayer > wrote: > > Allow enumeration, read and write of fields without requiring #if on > > versions > > All other public structures can be accessed through AVOptions > > > > TODO: ad

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Derek Buitenhuis
On 5/10/2016 12:43 PM, Michael Niedermayer wrote: > This patch adds an AVClass field to AVCodecParameters like we use in > other public structures. > i fail to see how this patch is related to your reply I apologize. I thought it was the start of an attempt to address the "issue" from the other pa

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Hendrik Leppkes
On Tue, May 10, 2016 at 1:43 PM, Michael Niedermayer wrote: > On Tue, May 10, 2016 at 11:17:12AM +0100, Derek Buitenhuis wrote: >> On 5/10/2016 7:24 AM, Hendrik Leppkes wrote: >> > I don't like this, the struct is pretty cleanly defined and unlikely >> > to be extended much over time. >> > Most ot

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Michael Niedermayer
On Tue, May 10, 2016 at 11:17:12AM +0100, Derek Buitenhuis wrote: > On 5/10/2016 7:24 AM, Hendrik Leppkes wrote: > > I don't like this, the struct is pretty cleanly defined and unlikely > > to be extended much over time. > > Most other structs have AVOptions so the CLI can interact with it, but > >

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread wm4
On Tue, 10 May 2016 08:24:35 +0200 Hendrik Leppkes wrote: > On Tue, May 10, 2016 at 2:07 AM, Michael Niedermayer > wrote: > > Allow enumeration, read and write of fields without requiring #if on > > versions > > All other public structures can be accessed through AVOptions > > > > TODO: add all

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-10 Thread Derek Buitenhuis
On 5/10/2016 7:24 AM, Hendrik Leppkes wrote: > I don't like this, the struct is pretty cleanly defined and unlikely > to be extended much over time. > Most other structs have AVOptions so the CLI can interact with it, but > this struct is not meant to be modified by users, its just a direct > line

Re: [FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-09 Thread Hendrik Leppkes
On Tue, May 10, 2016 at 2:07 AM, Michael Niedermayer wrote: > Allow enumeration, read and write of fields without requiring #if on versions > All other public structures can be accessed through AVOptions > > TODO: add all fields to AVOption table > TODO: bump version > TODO: update APIChanges I

[FFmpeg-devel] [PATCH] avcodec: Add AVClass to AVCodecParameters

2016-05-09 Thread Michael Niedermayer
Allow enumeration, read and write of fields without requiring #if on versions All other public structures can be accessed through AVOptions TODO: add all fields to AVOption table TODO: bump version TODO: update APIChanges Signed-off-by: Michael Niedermayer --- libavcodec/avcodec.h | 12 ++