From: Burkhard P. <pl...@ip...> - 2004-09-16 14:11:42
|
> Fortunately for the plugins I've seen so far there is > not a problem because the red/blue channels can be swapped without > problem, so they can support both RGB and BGR. Maybe the plugins might still look "cool" when B and R are swapped, but the plugin authors won't like this. Adjusting the colors for a visualization can involve many hours of fine-tuning. There need to be a bullet-proof definition of RGB and BGR, so that all plugins are displayed with the right colors on all architectures. You should also take care, that there is no "standard" about RGB and BGR, especially for 15/16 bpp. The same format might be called differently in different software packages. Colorspace issues can become really complicated. I wrote a library (gavl), which handles all these. The main header is here: http://cvs.sourceforge.net/viewcvs.py/gmerlin/gavl/include/gavl/gavl.h?view=markup The libavcodec source (ffmpeg.org) also gives an idea how to handle pixel formats properly. -- _____________________________ Dr.-Ing. Burkhard Plaum Institut fuer Plasmaforschung Pfaffenwaldring 31 70569 Stuttgart Tel.: +49 711 685-2187 Fax.: -3102 |