>  
> +static uint32_t make_filler(int bpp, uint32_t color)
> +{
> +    if (bpp < 24) {
> +        color |= color << 16;
> +        if (bpp < 15) {
> +            color |= color << 8;
> +        }
> +    }
> +    return color;
> +}
> +

Does this assume that the upper bits of color are zeroed when bpp < 24? Is that
a safe assumption or could those bits be garbage?

Reply via email to