[FFmpeg-devel] [RFC] *put_bits_* functions renamings

Stefano Sabatini stefano.sabatini-lala
Sat Apr 11 16:53:21 CEST 2009


On date Saturday 2009-04-11 01:04:28 +0200, Michael Niedermayer encoded:
> On Sat, Apr 11, 2009 at 12:52:35AM +0200, Stefano Sabatini wrote:
> > On date Friday 2009-04-10 18:53:22 +0100, M?ns Rullg?rd encoded:
> > > Michael Niedermayer <michaelni at gmx.at> writes:
> > > 
> > > > On Fri, Apr 10, 2009 at 05:22:23PM +0200, Stefano Sabatini wrote:
> > > >> Hi all,
> > > >> 
> > > >> the new name is consistent with the name for which a function should
> > > >> be prefixed (rather than suffixed) by a prefix telling the namespace
> > > >> to which it applyies, it is also consistent with all the other
> > > >> put_bits_* functions and more grep-friendly.
> > > >
> > > > iam rather used to flush_put_bits() so iam mildly against the rename
> > > > that is unless several other devels want the rename
> > > 
> > > All the other functions are put_bits_*, and we have get_bits_*.  I'm
> > > in favour of renaming it to keep things consistent.
> > 
> > Actually this is my complete evil plan for the *put_bits* functions:
> > 
> > init_put_bits            ->  put_bits_init
> > put_bits_count           ->  put_bits_count
> > flush_put_bits           ->  put_bits_flush
> > align_put_bits           ->  put_bits_align
> > ff_put_string            ->  put_bits_string (put_bits_put_string?)
> > ff_copy_bits             ->  put_bits_copy
> > put_bits                 ->  put_bits
> > pbBufPtr                 ->  put_bits_get_buf_ptr (put_bits_buf_ptr?)
> > skip_put_bits            ->  put_bits_skip
> > skip_put_bytes           ->  put_bits_skip_bytes
> > set_put_bits_buffer_size ->  put_bits_set_buffer_size
> > put_sbits                ->  put_bits_signed? (I still have to read the function...)
> > 
> > So the idea basically is to prefix all the functions with "put_bits",
> > and try to follow consistent naming rules, with eventual variations
> > with respect to the above table to accomodate devels
> > preferences/suggestions.
> > 
> > Also I don't think it would make sense to rename just few functions,
> > since the idea was to provide a consistent functions set.
> 
> i prefer to keep the functions named as they are.

Other opinions?
-- 
FFmpeg = Fast Foolish Merciful Pitiless Evanescent Game



More information about the ffmpeg-devel mailing list