mirror of
https://github.com/ocornut/imgui.git
synced 2024-11-27 16:29:02 +08:00
ImDrawList: changed AddCircle(), AddCircleFilled() default num_segments from 12 to 0.
This commit is contained in:
parent
4be8155002
commit
e223bd8177
@ -37,7 +37,7 @@ HOW TO UPDATE?
|
||||
|
||||
Other Changes:
|
||||
|
||||
- Nav: Fixed clicking on void from not clearing focused window.
|
||||
- Nav: Fixed clicking on void (behind any windows) from not clearing the focused window.
|
||||
This would be problematic e.g. in situation where the application relies on io.WantCaptureKeyboard
|
||||
flag being cleared accordingly. (bug introduced in 1.77 WIP on 2020/06/16) (#3344, #2880)
|
||||
- InputText, ImDrawList: Fixed assert triggering when drawing single line of text with more
|
||||
@ -51,6 +51,9 @@ Other Changes:
|
||||
- Requires an extra bit of texture space (~64x64 by default), relies on GPU bilinear filtering.
|
||||
- Clear io.AntiAliasedLinesUseTex = false; to disable rendering using this method.
|
||||
- Clear ImFontAtlasFlags_NoBakedLines in ImFontAtlas::Flags to disable baking data in texture.
|
||||
- ImDrawList: changed AddCircle(), AddCircleFilled() default num_segments from 12 to 0, effectively
|
||||
enabling auto-tessellation by default. Tweak tessellation in Style Editor->Rendering section, or
|
||||
by modifying the 'style.CircleSegmentMaxError' value. [@ShironekoBen]
|
||||
- ImDrawList: Fixed minor bug introduced in 1.75 where AddCircle() with 12 segments would generate
|
||||
an extra vertex. (This bug was mistakenly marked as fixed in earlier 1.77 release). [@ShironekoBen]
|
||||
- Demo: Tweak "Child Windows" section.
|
||||
|
5
imgui.h
5
imgui.h
@ -2052,6 +2052,7 @@ struct ImDrawList
|
||||
// Primitives
|
||||
// - For rectangular primitives, "p_min" and "p_max" represent the upper-left and lower-right corners.
|
||||
// - For circle primitives, use "num_segments == 0" to automatically calculate tessellation (preferred).
|
||||
// In older versions (until Dear ImGui 1.77) the AddCircle functions defaulted to num_segments == 12.
|
||||
// In future versions we will use textures to provide cheaper and higher-quality circles.
|
||||
// Use AddNgon() and AddNgonFilled() functions if you need to guaranteed a specific number of sides.
|
||||
IMGUI_API void AddLine(const ImVec2& p1, const ImVec2& p2, ImU32 col, float thickness = 1.0f);
|
||||
@ -2062,8 +2063,8 @@ struct ImDrawList
|
||||
IMGUI_API void AddQuadFilled(const ImVec2& p1, const ImVec2& p2, const ImVec2& p3, const ImVec2& p4, ImU32 col);
|
||||
IMGUI_API void AddTriangle(const ImVec2& p1, const ImVec2& p2, const ImVec2& p3, ImU32 col, float thickness = 1.0f);
|
||||
IMGUI_API void AddTriangleFilled(const ImVec2& p1, const ImVec2& p2, const ImVec2& p3, ImU32 col);
|
||||
IMGUI_API void AddCircle(const ImVec2& center, float radius, ImU32 col, int num_segments = 12, float thickness = 1.0f);
|
||||
IMGUI_API void AddCircleFilled(const ImVec2& center, float radius, ImU32 col, int num_segments = 12);
|
||||
IMGUI_API void AddCircle(const ImVec2& center, float radius, ImU32 col, int num_segments = 0, float thickness = 1.0f);
|
||||
IMGUI_API void AddCircleFilled(const ImVec2& center, float radius, ImU32 col, int num_segments = 0);
|
||||
IMGUI_API void AddNgon(const ImVec2& center, float radius, ImU32 col, int num_segments, float thickness = 1.0f);
|
||||
IMGUI_API void AddNgonFilled(const ImVec2& center, float radius, ImU32 col, int num_segments);
|
||||
IMGUI_API void AddText(const ImVec2& pos, ImU32 col, const char* text_begin, const char* text_end = NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user