Skip to content

Commit bb4ec86

Browse files
bghgaryCopilot
andcommitted
Fix test ordering: finish frame before destroying native texture
Move DestroyTestTexture after FinishRenderingCurrentFrame so bgfx::frame() processes the texture creation command before the native resource is released. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent e103f3e commit bb4ec86

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Apps/UnitTests/Source/Tests.ExternalTexture.D3D11.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ TEST(ExternalTexture, CreateForJavaScriptWithTextureArray)
5151
// Wait for CreateForJavaScript to complete.
5252
done.get_future().wait();
5353

54-
DestroyTestTexture(nativeTexture);
55-
5654
update.Finish();
5755
device.FinishRenderingCurrentFrame();
56+
57+
DestroyTestTexture(nativeTexture);
5858
#endif
5959
}

0 commit comments

Comments
 (0)