Skip to content

Commit

Permalink
Merge pull request #62 from HaydnTrigg/master
Browse files Browse the repository at this point in the history
D3DDevice recreateVidmemRasters and IDirect3DDevice::CreateTexture undefined behavior
  • Loading branch information
aap authored Feb 21, 2021
2 parents bb7fb68 + 266a09b commit 373f839
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/d3d/d3ddevice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1129,7 +1129,7 @@ recreateVidmemRasters(void)
switch(raster->type){
case Raster::CAMERATEXTURE: {
int32 levels = Raster::calculateNumLevels(raster->width, raster->height);
IDirect3DTexture9 *tex;
IDirect3DTexture9 *tex = nil;
d3ddevice->CreateTexture(raster->width, raster->height,
raster->format & Raster::MIPMAP ? levels : 1,
D3DUSAGE_RENDERTARGET,
Expand Down

0 comments on commit 373f839

Please sign in to comment.