Hey everyone!
How to draw alpha on UTextureRenderTarget2D without (anti-aliasing), now I’m doing it with this code
RenderTargets[i] = UKismetRenderingLibrary::CreateRenderTarget2D(GetWorld(), Mask[i]->GetSurfaceWidth(), Mask[i]->GetSurfaceHeight());
UCanvas* Canvas;
FVector2D Size;
FDrawToRenderTargetContext Ctx;
UKismetRenderingLibrary::BeginDrawCanvasToRenderTarget(GetWorld(), RenderTargets[i], Canvas, Size, Ctx);
UKismetRenderingLibrary::ClearRenderTarget2D(GetWorld(), RenderTargets[i], FLinearColor::Transparent);
Canvas->K2_DrawTexture(Mask[i], FVector2D::ZeroVector, Size, FVector2D::ZeroVector, FVector2D::UnitVector, FLinearColor::White, BLEND_AlphaComposite);
UKismetRenderingLibrary::EndDrawCanvasToRenderTarget(GetWorld(), Ctx);
in PC everything is fine
but when i run it on oculus quest, it looks like this
I have exported the resulting of render target and as I see the alpha channel is blurred.
How it must look like:
All I want to do is draw a texture in runtime
P.S. i am not sure that was anti-aliasing problem