Replies: 1 comment
-
The API calls you are using are not correct. basePos := imgui.MainViewport().Pos()
imgui.SetNextWindowPosV(imgui.NewVec2(basePos.X+400, basePos.Y+60), imgui.CondOnce, imgui.NewVec2(0, 0))
imgui.SetNextWindowSizeV(imgui.NewVec2(500, 300), imgui.CondOnce)
imgui.Begin("Plot window")
if implot.BeginPlotV("Plot", imgui.NewVec2(-1, -1), 0) {
implot.PlotScatterFloatPtrFloatPtr("what", utils.SliceToPtr(xt), utils.SliceToPtr(yt), int32(len(xt)))
implot.EndPlot()
}
imgui.End() |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm attempting to create a scatter plot, but anytime I try to plot more than ~2900 points, the points turn in to lines. I suspect it's something with the backend, because if I zoom in on a large dataset far enough, it will display properly. I've tried setting the backend flag regarding the number of vertices, but I'm unsure of what else to look at. I'm a really new Go programmer, and a new programmer in general. Here's the code, with the result below:
Thanks for any help.
https://i.imgur.com/BBJrdsn.jpg
Beta Was this translation helpful? Give feedback.
All reactions