WIP fix rendering of drawCache's texture
This commit is contained in:
parent
2919be2aff
commit
df4e2bf029
1 changed files with 12 additions and 1 deletions
|
@ -293,7 +293,18 @@ void Tri::State::draw() {
|
||||||
// draw cache initialized
|
// draw cache initialized
|
||||||
check_draw_cache();
|
check_draw_cache();
|
||||||
BeginDrawing();
|
BeginDrawing();
|
||||||
DrawTexture(drawCache.texture, 0, 0, WHITE);
|
// hack to flip in the y direction, since RenderTexture2D's texture
|
||||||
|
// is flipped
|
||||||
|
DrawTextureRec(
|
||||||
|
drawCache.texture,
|
||||||
|
{
|
||||||
|
0.0f,
|
||||||
|
0.0f,
|
||||||
|
(float)drawCache.texture.width,
|
||||||
|
(float)-drawCache.texture.height
|
||||||
|
},
|
||||||
|
{0.0f, 0.0f},
|
||||||
|
WHITE);
|
||||||
} else {
|
} else {
|
||||||
BeginDrawing();
|
BeginDrawing();
|
||||||
draw_to_target(nullptr);
|
draw_to_target(nullptr);
|
||||||
|
|
Loading…
Reference in a new issue