Re: [AD] Windowed drivers color conversion

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> We could start with a C only version first though, then maybe
> add an asm one later.

I agree.

> Ok, this is good for me. But then we'd need a separated C file with this
> function and all the C conversion functions in it; should we put this into
> src/ or src/misc ? I vote for the first one.

I'm ok with your src/colconv.c initial proposition.

> Also, you should move update.s to src/i386 after the modifications...

Done. I've called it icolconv.s and I've also put in colconv.c some shift
table initialization code needed by the non MMX asm code.
Tested the whole thing under Windows (but MMX untested).

About the asm code: as I already said it, it doesn't read the destination
rectangle dimensions. Moreover, the width must be 4-aligned. The code is
optimized for memory aligned rectangles (src and dest), the performance
penalty for single misalignment can reach 50% I think.
I haven't added the two 15-bit routines yet.

Patch attached. You will have to manually delete src/win/update.s though.

--
Eric Botcazou
ebotcazou@xxxxxxxxxx

Attachment: colconv.zip
Description: Zip compressed data



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/