mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-15 01:17:00 +00:00
ImDrawList: asserting on incorrect value for CurveTessellationTol (#5713)
This commit is contained in:
parent
04316bd223
commit
56c3eaed20
@ -1295,6 +1295,7 @@ void ImDrawList::PathBezierCubicCurveTo(const ImVec2& p2, const ImVec2& p3, cons
|
|||||||
ImVec2 p1 = _Path.back();
|
ImVec2 p1 = _Path.back();
|
||||||
if (num_segments == 0)
|
if (num_segments == 0)
|
||||||
{
|
{
|
||||||
|
IM_ASSERT(_Data->CurveTessellationTol > 0.0f);
|
||||||
PathBezierCubicCurveToCasteljau(&_Path, p1.x, p1.y, p2.x, p2.y, p3.x, p3.y, p4.x, p4.y, _Data->CurveTessellationTol, 0); // Auto-tessellated
|
PathBezierCubicCurveToCasteljau(&_Path, p1.x, p1.y, p2.x, p2.y, p3.x, p3.y, p4.x, p4.y, _Data->CurveTessellationTol, 0); // Auto-tessellated
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -1310,6 +1311,7 @@ void ImDrawList::PathBezierQuadraticCurveTo(const ImVec2& p2, const ImVec2& p3,
|
|||||||
ImVec2 p1 = _Path.back();
|
ImVec2 p1 = _Path.back();
|
||||||
if (num_segments == 0)
|
if (num_segments == 0)
|
||||||
{
|
{
|
||||||
|
IM_ASSERT(_Data->CurveTessellationTol > 0.0f);
|
||||||
PathBezierQuadraticCurveToCasteljau(&_Path, p1.x, p1.y, p2.x, p2.y, p3.x, p3.y, _Data->CurveTessellationTol, 0);// Auto-tessellated
|
PathBezierQuadraticCurveToCasteljau(&_Path, p1.x, p1.y, p2.x, p2.y, p3.x, p3.y, _Data->CurveTessellationTol, 0);// Auto-tessellated
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user