Re: d3dx9: Implement converting and copying surface data in D3DXLoadSurfaceFromMemory (review please)

2009-08-31 Thread Philip Nilsson
On Sun, Aug 30, 2009 at 12:56:26PM +0200, Tony Wasserka wrote: > > I think it would be better to store this in surface.c since I can't > > think of anything else that would need this. > > > D3DXCheckTextureRequirements in texture.c will make use of the format > table, since it also needs informa

Re: d3dx9: Implement converting and copying surface data in D3DXLoadSurfaceFromMemory (review please)

2009-08-26 Thread Philip Nilsson
On Wed, Aug 26, 2009 at 12:10:36PM +0200, Tony Wasserka wrote: > +BYTE abits, rbits, gbits, bbits; > +BYTE ashift, rshift, gshift, bshift; > +DWORD amask, rmask, gmask, bmask; If you make those into arrays you will be able to cut down on the code size, and the compiler might like it be

Re: [PATCH 6/7] d3dx9/tests: Test D3DXCheckTextureRequirements.

2008-09-19 Thread Philip Nilsson
On Fri, Sep 19, 2008 at 07:07:18PM +0200, Henri Verbeet wrote: > 2008/9/19 Philip Nilsson <[EMAIL PROTECTED]>: > > This one could use some more work, but I think the tests will pass in > > most cases (except in strange environments without support for common > > forma

Re: [PATCH 7/7] d3dx9/tests: Test D3DXCreateTexture.

2008-09-19 Thread Philip Nilsson
On Fri, Sep 19, 2008 at 07:10:29PM +0200, Henri Verbeet wrote: > I think it would be a good idea to test the parameters (format, width, > height, miplevels) of the created texture. I used to do that, but most of the things you can check are just duplicates of the checks in D3DCheckTextureRequireme

Re: [PATCH 3/7] d3dx9: Implement D3DXCheckTextureRequirements.

2008-09-19 Thread Philip Nilsson
Hi! On Fri, Sep 19, 2008 at 07:04:04PM +0200, Henri Verbeet wrote: > 2008/9/19 Philip Nilsson <[EMAIL PROTECTED]>: > > > +hr = IDirect3DDevice9_GetDirect3D(device, &d3d9); > > +if (hr != D3D_OK || !device) > > +

Re: wined3d: universal surface convertor function for unsigned integer color formats(5th attempt)

2008-07-27 Thread Philip Nilsson
On Thu, Jul 24, 2008 at 08:14:40PM +0400, Victor Eremin wrote: > Supports conversion between most of "unsigned color" argb/xrgb > surface formats (D3DFMT_A8R8G8B8, D3DFMT_A8R3G3B2, etc), and > "luminosity" color formats (D3DFMT_L8, etc), > excluding D3DFMT_A16R16G16B16, D3DFMT_A8P8, D3DFMT_P8 and D

Re: wined3d: universal surface convertor function for unsigned integer color formats

2008-07-14 Thread Philip Nilsson
On Mon, Jul 14, 2008 at 02:51:42AM +0400, Victor Eremin wrote: > > Converter function supports conversion between most of > "unsigned color" argb/xrgb surface formats (like D3DFMT_A8R8G8B8, > D3DFMT_A8R3G3B2, and so on), and between "luminosity" color formats > (D3DFMT_L8, etc), excluding D3DFMT_

Re: Review request: real async for GetAsyncKeyState (bug #5623)

2008-05-08 Thread Philip Nilsson
d this was due to something that didn't recompile, but I made the tree clean and reconfigured it, and compiled again. No change. I will investigate a bit further as this patch might be useful for an application I have some problems with (I think it uses GetAsyncKeyState for modifiers). -- Philip Nilsson

Re: d3dx9: Texturing functions

2008-04-21 Thread Philip Nilsson
file, read contents into memory) LoadSurfaceFromResource (open resource, read contents into memory) LoadSurfaceFromSurface (read image data from a surface) This would mean two huge chunks of code: One which parses image formats (LoadSurfaceFromFileInMemory), and one which handles all the resizing, conversion, filtering and stuff (LoadSurfaceFromMemory). -- Philip Nilsson

Re: d3dx9_36: Add stubs and implementations for D3DXCreateTexturexx

2008-04-15 Thread Philip Nilsson
l time. I pretty much abandoned the first two, because there's got to be a whole lot of code somewhere in the tree already. It does work in some cases, however. Attached in case it might be helpful. -- Philip Nilsson struct d3dformat { unsigned int id; unsigned int amask; u

Re: wined3d: Initialize maxAttribs in case it isn't changed by glGetIntegerv.

2008-03-22 Thread Philip Nilsson
On Sat, Mar 22, 2008 at 08:04:52PM +0100, Stefan Dösinger wrote: > Am Samstag, 22. März 2008 18:28:52 schrieb Philip Nilsson: > > glGetIntegerv > I've seen this behavior very old drivers(87.xx), but I am kinda puzzled why > it > happens with the new drivers. The pat