mirror of https://github.com/aap/librw.git
Merge pull request #62 from HaydnTrigg/master
D3DDevice recreateVidmemRasters and IDirect3DDevice::CreateTexture undefined behavior
This commit is contained in:
commit
373f8399cd
|
@ -1129,7 +1129,7 @@ recreateVidmemRasters(void)
|
||||||
switch(raster->type){
|
switch(raster->type){
|
||||||
case Raster::CAMERATEXTURE: {
|
case Raster::CAMERATEXTURE: {
|
||||||
int32 levels = Raster::calculateNumLevels(raster->width, raster->height);
|
int32 levels = Raster::calculateNumLevels(raster->width, raster->height);
|
||||||
IDirect3DTexture9 *tex;
|
IDirect3DTexture9 *tex = nil;
|
||||||
d3ddevice->CreateTexture(raster->width, raster->height,
|
d3ddevice->CreateTexture(raster->width, raster->height,
|
||||||
raster->format & Raster::MIPMAP ? levels : 1,
|
raster->format & Raster::MIPMAP ? levels : 1,
|
||||||
D3DUSAGE_RENDERTARGET,
|
D3DUSAGE_RENDERTARGET,
|
||||||
|
|
Loading…
Reference in New Issue