Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import gg.essential.elementa.font.data.Font
import gg.essential.elementa.font.data.Glyph
import gg.essential.universal.UGraphics
import gg.essential.universal.UMatrixStack
import gg.essential.universal.render.UGpuSampler
import gg.essential.universal.render.URenderPipeline
import gg.essential.universal.shader.BlendState
import gg.essential.universal.vertex.UBufferBuilder
Expand Down Expand Up @@ -153,7 +154,13 @@ class BasicFontRenderer(
val bufferBuilder = UBufferBuilder.create(UGraphics.DrawMode.QUADS, UGraphics.CommonVertexFormats.POSITION_TEXTURE_COLOR)
drawStringNow(bufferBuilder, matrixStack, string, color, x, y, originalPointSize)
bufferBuilder.build()?.drawAndClose(if (ElementaVersion.atLeastV10Active) PIPELINE2 else PIPELINE) {
texture(0, regularFont.getTexture().dynamicGlId)
texture(0, regularFont.getTexture().gpuTextureView, UGpuSampler(
UGpuSampler.AddressMode.CLAMP_TO_EDGE,
UGpuSampler.AddressMode.CLAMP_TO_EDGE,
UGpuSampler.FilterMode.NEAREST,
UGpuSampler.FilterMode.NEAREST,
false,
))
}
} else {
UGraphics.bindTexture(0, regularFont.getTexture().dynamicGlId)
Expand Down
Loading