[XviD-devel] vlc_codes.h

Christoph Lampert chl at math.uni-bonn.de
Fri Feb 21 22:06:10 CET 2003


Hi,

Radeks patch created some problems with ffmpeg/mplayer because now 
some tables are exported that haven't been before and create naming
conflicts (e.g. cbpy_tab[] which is only needed in mbcoding.h )

Somehow we should find a real solution, by giving a unique name
like xvid_XXX to everything that is exported, and apart from that try not
to export anything that isn't really needed from outside!

gruel


On Sun, 16 Feb 2003, Radek Czyz wrote:

> Lo everyone,
> 
> I have a new subject for you ;)
> 
> Maybe you have noticed that after the _BITS stuff, our library got
> serveral tens of kilobytes larger. VfW dll was larger by at least
> 60kb.
> You might ask me what kind of code I write. I promise you this is not
> the size of _BITS functions.
> The problem is that I had to #include vlc_codes.h to motion
> estimation. This file contains all our hard-coded VLC tables, all
> declared static. As a result, every table which is used in motion
> estimation is incuded in motion estimation object file. All tables
> needed for MB coding are included in mbcoding object. All tables
> needed for intra block coding are included in mbprediction object.
> They are all static - invisible to other modules.
> 
> I wanted to do something about it and came up with an idea which
> works. I created a new object, vlc_codes.c . Here, all tables are
> defined, not as static. The old vlc_codes.h, which is #included in
> other modules, contains 'prototypes' (I don't know the correct
> word...) of the tables - just all the tables again, without the actual
> data and with 'extern' keyword.
> 
> This way, everything works correctly, but the VfW dll is smaller by
> 120kb ! Even if it doesn't have the real effect on performance (but
> what about mem bandwith and cpu cache), it still looks much better.
> 
> There probably are better ways - we could include the actual tables to
> some existing object - but I hope you agree that we should do
> _something_ like this.
> 
> Best regards,
> Radek
> 
> _______________________________________________
> XviD-devel mailing list
> XviD-devel at xvid.org
> http://list.xvid.org/mailman/listinfo/xvid-devel
> 



More information about the XviD-devel mailing list