Am Dienstag 26 September 2006 18:03 schrieb H. Verbeet: > On 26/09/06, Stefan Dösinger <[EMAIL PROTECTED]> wrote: > > I think we should switch to NP2 repacking by default(and fix it if it is > > broken), with that we can offer the correct pitch without the NPOT > > extension too. > > Hmm. Personally I consider repacking a hack for broken games. I'm not > sure if those exact sizes are in any way guaranteed by d3d either... > to me it would appear as something that might be different between > drivers. At least for the test case I think we should just check the > alignment. It is really easy to do, and I think just repacking is less a hack than offering 2 methods. To get proper performance with repacking we can just count how often a surface is locked and stop releasing the copy in local memory if the app locks it too often, simmilar to converted surfaces.
Related to the driver dependence: That is why I am testing system memory surfaces. I don't think they depend on the driver, and if they do the test case will catch that on windows and it is interesting to get notified about it. One other thing I suspect is that there are some corner cases, like 1x1 surfaces in ddraw. I noticed that Anarchy Online goes crazy if I report a pitch of 4 on a 1x1 D3DFMT_A4R4G4B4 surface. It seems it overwrites loads of memory, even if I allocate 256 bytes for the surface it overflows.
pgpbPCLTlCT3J.pgp
Description: PGP signature