MCPcopy Create free account
hub / github.com/brenocq/implot3d / GetLineRenderProps

Function GetLineRenderProps

implot3d_items.cpp:82–93  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

80 } while (0)
81
82IMPLOT3D_INLINE void GetLineRenderProps(const ImDrawList3D& draw_list_3d, float& half_weight, ImVec2& tex_uv0, ImVec2& tex_uv1) {
83 const bool aa = ImPlot3D::ImHasFlag(draw_list_3d._Flags, ImDrawListFlags_AntiAliasedLines) &&
84 ImPlot3D::ImHasFlag(draw_list_3d._Flags, ImDrawListFlags_AntiAliasedLinesUseTex);
85 if (aa) {
86 ImVec4 tex_uvs = draw_list_3d._SharedData->TexUvLines[(int)(half_weight * 2)];
87 tex_uv0 = ImVec2(tex_uvs.x, tex_uvs.y);
88 tex_uv1 = ImVec2(tex_uvs.z, tex_uvs.w);
89 half_weight += 1;
90 } else {
91 tex_uv0 = tex_uv1 = draw_list_3d._SharedData->TexUvWhitePixel;
92 }
93}
94
95//-----------------------------------------------------------------------------
96// [SECTION] Template instantiation utility

Callers 4

InitMethod · 0.85
InitMethod · 0.85
InitMethod · 0.85
InitMethod · 0.85

Calls 1

ImHasFlagFunction · 0.85

Tested by

no test coverage detected