| 1562 | } |
| 1563 | |
| 1564 | void Demo_CustomScale() { |
| 1565 | IMGUI_DEMO_MARKER("Axes/Custom Scale"); |
| 1566 | static float v[100]; |
| 1567 | for (int i = 0; i < 100; ++i) { |
| 1568 | v[i] = i*0.01f; |
| 1569 | } |
| 1570 | if (ImPlot::BeginPlot("Sqrt")) { |
| 1571 | ImPlot::SetupAxis(ImAxis_X1, "Linear"); |
| 1572 | ImPlot::SetupAxis(ImAxis_Y1, "Sqrt"); |
| 1573 | ImPlot::SetupAxisScale(ImAxis_Y1, TransformForward_Sqrt, TransformInverse_Sqrt); |
| 1574 | ImPlot::SetupAxisLimitsConstraints(ImAxis_Y1, 0, INFINITY); |
| 1575 | ImPlot::PlotLine("##data",v,v,100); |
| 1576 | ImPlot::EndPlot(); |
| 1577 | } |
| 1578 | } |
| 1579 | |
| 1580 | //----------------------------------------------------------------------------- |
| 1581 |
nothing calls this directly
no test coverage detected