[5/8] d3dx9: Add DDS support in D3DXCreateTextureFromFile functions.

Józef Kucia joseph.kucia at gmail.com
Thu May 10 10:46:47 CDT 2012


On Thu, May 10, 2012 at 4:29 PM, Matteo Bruni <matteo.mystral at gmail.com> wrote:
> 2012/5/9 Józef Kucia <joseph.kucia at gmail.com>:
>> ---
>> +HRESULT load_texture_from_dds(IDirect3DTexture9 *texture, const void *src_data, UINT srd_data_size,
>> +    const PALETTEENTRY *palette, DWORD filter, D3DCOLOR color_key, const D3DXIMAGE_INFO *src_info) DECLSPEC_HIDDEN;
> ...
>> +HRESULT load_texture_from_dds(IDirect3DTexture9 *texture, const void *src_data, UINT srd_data_size,
>> +    const PALETTEENTRY *palette, DWORD filter, D3DCOLOR color_key, const D3DXIMAGE_INFO *src_info)
>
> I guess that was meant to be called "src_data_size". More to the
> point, anyway, you're not using that value right now, you should
> probably add a check against it or remove the parameter altogether.

It should be removed. The size of data is checked in
D3DXGetImageInfoFromFileInMemory, and at this point it can be assumed
that data is long enough.



More information about the wine-devel mailing list