Board index » delphi » Problem showing an AVI on a 256 color screen

Problem showing an AVI on a 256 color screen

I have an application which shows a video on the screen. The video is
made with "millions of colors" but the screen is set to 256 colors. The
result is that the video looks as though it was shot with a thermal
imaging camera.
I have seen software which "does some windows magic" to allow the video
to show correctly (ie with "natural colors") and would like to replicate

this in my D4 application.
Has anyone got any pointers to what needs to be done?

Thanks in advance

 

Re:Problem showing an AVI on a 256 color screen


I wish I had a better reply, unless there is a "MAGIC" call to do, I think
what you might NEED to do is to DIThER EACH FRAM before displaying them.
Pick a STATIC color table that would be constructed as the best of all
colors. This would be your palette. Then for each frame to display, DITHER
the 24 bit image onto a 256 color bitmap and then display the 256 bitmap. :)

Davie

Quote
Ian Davidson wrote:
> I have an application which shows a video on the screen. The video is
> made with "millions of colors" but the screen is set to 256 colors. The
> result is that the video looks as though it was shot with a thermal
> imaging camera.
> I have seen software which "does some windows magic" to allow the video
> to show correctly (ie with "natural colors") and would like to replicate

> this in my D4 application.
> Has anyone got any pointers to what needs to be done?

> Thanks in advance

Other Threads