Next phase ready
This commit is contained in:
@ -19,7 +19,7 @@ void UILabelNew::rebufferQuads(std::vector<struct UILabelText> texts) {
|
|||||||
auto oldTexts = this->texts;
|
auto oldTexts = this->texts;
|
||||||
|
|
||||||
textureMap.clear();
|
textureMap.clear();
|
||||||
glm::vec2 position(32, 32);
|
glm::vec2 position(0, 0);
|
||||||
struct FontShaderBufferData fontData;
|
struct FontShaderBufferData fontData;
|
||||||
int32_t quadIndex = 0;
|
int32_t quadIndex = 0;
|
||||||
int32_t partIndex = 0;
|
int32_t partIndex = 0;
|
||||||
@ -45,6 +45,9 @@ void UILabelNew::rebufferQuads(std::vector<struct UILabelText> texts) {
|
|||||||
assertTrue(nextTexture < FONT_SHADER_TEXTURE_MAX);
|
assertTrue(nextTexture < FONT_SHADER_TEXTURE_MAX);
|
||||||
textureMap[itText->texture] = nextTexture++;
|
textureMap[itText->texture] = nextTexture++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Set initial line height
|
||||||
|
position.y = mathMax<float_t>(itText->size, position.y);
|
||||||
|
|
||||||
++itText;
|
++itText;
|
||||||
}
|
}
|
||||||
@ -186,9 +189,8 @@ std::vector<struct ShaderPassItem> UILabelNew::getUIRenderPasses() {
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
break;
|
assertUnreachable();
|
||||||
}
|
}
|
||||||
assertTrue(param >= 0 && param < FONT_SHADER_TEXTURE_MAX);
|
|
||||||
item.textureValues[param] = it->second;
|
item.textureValues[param] = it->second;
|
||||||
++it;
|
++it;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user