[XviD-devel] XVID dithering in YV12-to-RGB555

Michael Militzer michael at xvid.org
Wed Jun 30 14:09:49 CEST 2010


Hi,

the YV12->RGB colorspace conversion is not part of the actual decoding
process. So you can implement it basically any way you like. There is no
need to stick to exactly the same algorithm than in the C implementation.

You should however care about the quality of the conversion. RGB565 images
typically don't look too great anyway - now if in addition your dithering
approach is very rough the result can be quite disappointing...

Regards,
Michael


Quoting Frederik Lotter <Frederik.Lotter at arm.com>:

> Hi,
>
> I am optimizing the colorspace conversion using the ARM NEON SIMD   
> instruction set.
>
> The current dithering approach does not scale well using SIMD. The   
> current approach adds the least 3 significant bits of a r,g,b pixel   
> value to the next pixel in the row below, and then add this pixel's   
> least significant bits to the next pixel in the row above. Etc....
>
> |/|/|/|/|/| ....
>
> However the sequential inheritance manner of this makes it   
> inefficient for SIMD.
>
> Is there a specification which requires specific dithering patterns   
> when decoding?
>
> Is there any patterns used in other architectures SIMD architectures  
>  what you can suggest? Currently my SIMD Colorspace conversion   
> process 32 pixels in a single iteration over two lines:
>
> [xxxxxxxxxxxxxxxx] 16 pixels
> [xxxxxxxxxxxxxxxx] 16 pixels
>
> Dithering ideally should be contained to the current processed   
> pixels otherwise large amounts if pixel data must be temporarily   
> saved on the stack - which I want to avoid at all costs.
>
> The sequential manner of the zigzag pattern above cannot be done   
> quickly on SIMD registers containing the r,g,b values.
>
> -- -- --
> /  /  /
> -- -- --
>
> I was wondering if I could simplify the dithering to groups of 4 pixels.
>
> Regards,
> Fred
>
>
> -- IMPORTANT NOTICE: The contents of this email and any attachments   
> are confidential and may also be privileged. If you are not the   
> intended recipient, please notify the sender immediately and do not   
> disclose the contents to any other person, use it for any purpose,   
> or store or copy the information in any medium.  Thank you.
> _______________________________________________
> 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