Il 26 aprile 2012 11:47, Józef Kucia <joseph.ku...@gmail.com> ha scritto: > static D3DFORMAT dds_pixel_format_to_d3dformat(const struct dds_pixel_format > *pixel_format) > { > - FIXME("Pixel format conversion not implemented.\n"); > + if (pixel_format->flags & DDS_PF_FOURCC) > + return dds_fourcc_to_d3dformat(pixel_format->fourcc); > + else if (pixel_format->flags & DDS_PF_RGB) > + return dds_rgb_to_d3dformat(pixel_format); > + else if (pixel_format->flags & DDS_PF_LUMINANCE) > + return dds_luminance_to_d3dformat(pixel_format); > + else if (pixel_format->flags & DDS_PF_ALPHA_ONLY) > + return dds_alpha_to_d3dformat(pixel_format);
You don't need all those 'else's, the 'return's imply that you get there only when the 'if' condition isn't true. The same applies in other areas of this patch. I don't mind much, but since you have to resend the series anyway...