Пример #1
0
void ButtonRendering::RenderButtonIcon(const glm::mat4& transform, glm::vec2 position, ButtonIcon* buttonIcon, bool disabled)
{
	if (buttonIcon != nullptr)
	{
		bounds2f b = bounds2f(position).grow(buttonIcon->size * buttonIcon->scale / 2.0f);
		RenderTextureRect(transform, buttonIcon->_texture, b, buttonIcon->bounds, disabled ? 0.5 : 1);
	}
}
Пример #2
0
void ButtonRendering::RenderHighlight(const glm::mat4& transform, bounds2f bounds)
{
	RenderTextureRect(transform, _textureButtonHighlight, bounds, bounds2f(0, 0, 1, 1));
}
Пример #3
0
void ButtonRendering::RenderHighlight(bounds2f viewport, bounds2f bounds)
{
	RenderTextureRect(viewport, _textureButtonHighlight, bounds, bounds2f(0, 0, 1, 1));
	//RenderCornerButton(viewport, _texture_highlight, bounds.grow(10), 32);
}