fix seam with ui zoom
This commit is contained in:
@@ -1068,10 +1068,10 @@ void Node::clear_context()
|
||||
void Node::update(float width, float height, float zoom)
|
||||
{
|
||||
m_zoom = zoom;
|
||||
YGNodeStyleSetWidth(y_node, ceilf(width / zoom));
|
||||
YGNodeStyleSetHeight(y_node, ceilf(height / zoom));
|
||||
YGNodeStyleSetWidth(y_node, (width / zoom));
|
||||
YGNodeStyleSetHeight(y_node, (height / zoom));
|
||||
YGNodeCalculateLayout(y_node, YGUndefined, YGUndefined, YGDirectionLTR);
|
||||
m_proj = glm::ortho(0.f, ceilf(width / zoom), ceilf(height / zoom), 0.f, -1.f, 1.f);
|
||||
m_proj = glm::ortho(0.f, (width / zoom), (height / zoom), 0.f, -1.f, 1.f);
|
||||
update_internal({ 0, 0 }, m_proj, zoom);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user