跳转至

Renderer2D 绑定相机常量缓冲

    void Renderer2D::BeginScene(const OrthographicCamera& camera)
    {
        CD_PROFILE_FUNCTION();
        s_Data.CameraBuffer.ViewProjection = camera.GetViewProjectionMatrix();
        s_Data.CameraUniformBuffer->SetData(&s_Data.CameraBuffer, sizeof(Renderer2DData::CameraData));

        StartBatch();
    }

修复TexIndex在纹理中插值的问题

删去Texubdex

struct VertexOutput
{
    vec4 Color;
    vec2 TexCoord;
    float TilingFactor;
};

加在后面

layout(location = 0) out VertexOutput Output;
layout(location = 3) out flat float v_TexIndex;
layout(location = 4) out flat int v_EntityID;