Skip to content

Commit f081bd0

Browse files
authored
Texture re render (#228)
* Add missing bundle and missing configuration * Cache texture before re-rendering
1 parent eec2617 commit f081bd0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Runtime/Model/Database/BacktraceDatabaseAttachmentManager.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,8 @@ private string GetScreenshotPath(string dataPrefix)
121121
// Create a render texture to render into
122122
RenderTexture rt = RenderTexture.GetTemporary(targetWidth, targetHeight);
123123

124+
RenderTexture previousActiveRT = RenderTexture.active;
125+
124126
if (SystemInfo.graphicsUVStartsAtTop)
125127
{
126128
Graphics.Blit(screenTexture, rt, new Vector2(1.0f, -1.0f), new Vector2(0.0f, 1.0f));
@@ -130,7 +132,6 @@ private string GetScreenshotPath(string dataPrefix)
130132
Graphics.Blit(screenTexture, rt);
131133
}
132134

133-
RenderTexture previousActiveRT = RenderTexture.active;
134135
RenderTexture.active = rt;
135136

136137
// Create a texture & read data from the active RenderTexture

0 commit comments

Comments
 (0)