[Ffmpeg-devel] Naming conventions
Tue Mar 6 14:56:47 CET 2007
On Tue, Mar 06, 2007 at 02:47:25PM +0100, Michael Niedermayer wrote:
> > > Regarding av_set_pts_info, this would suggest to me that the information being
> > > set pertains to pts and nothing more, that is, pts is the type and info is the
> > > property. I'm not sure this is what should be the case though. Similarly
> > > av_set_stream_timebase, the timebase is 'of' the stream, so the stream is the
> > > type and the timebase is the property of the thing of that type.
> > >
> > > My conclusion for av_set_pts_info is that if info is a subset of pts then it's
> > > correct, else it should probably be called av_set_info_pts.
> > >
> > > Also, I don't really like using 'type' in the above definition. At the risk of
> > > getting shot, I would be inclined to think of this as the following:
> > >
> > > av_<action>_<class hierarchy>_<property>
> > >
> > > But what do I know? :)
> > Very little, I'm afraid ;-)
> > I personally prefer a hierarchical naming scheme. It appears more consistent
> > to me, the "grammatical" style having more of an ad-hoc appearance.
> same hierachical ends with av_picture_size_get() not av_picture_get_size()
just try truncating an you will see which is more correct from a hierachical
av_picture_size vs av_picture_get
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I have often repented speaking, but never of holding my tongue.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the ffmpeg-devel