Open gucio321 opened 4 months ago
Is this likely to be addressed anytime soon? It would be really useful to plot using multiple axis.
ok, let me take a look
cimgui-go ref:
// original name: ImAxis_
type PlotAxisEnum int32
const (
AxisX1 PlotAxisEnum = 0
AxisX2 PlotAxisEnum = 1
AxisX3 PlotAxisEnum = 2
AxisY1 PlotAxisEnum = 3
AxisY2 PlotAxisEnum = 4
AxisY3 PlotAxisEnum = 5
AxisCOUNT PlotAxisEnum = 6
)
(cimplot_enums.go
)
func PlotSetAxes(x_axis PlotAxisEnum, y_axis PlotAxisEnum) {
C.ImPlot_SetAxes(C.ImAxis(x_axis), C.ImAxis(y_axis))
}
(cimplot_funcs.go
)
// Select which axis/axes will be used for subsequent plot elements.
IMPLOT_API void SetAxis(ImAxis axis);
IMPLOT_API void SetAxes(ImAxis x_axis, ImAxis y_axis);
ok @runrc I opened https://github.com/AllenDang/giu/pull/805
As I said, I don't have much free time at the moment as I'm in the middle of my examination session :smile:, but I added some stuff that involves cimgui-go experience. What needs to be done now is improving giu api. Feel free to finish my work and open PR ;-)
"2nd and 3rd axis":
old code was:
now it doesn't work because PlotFlagsYAxis2 doesn't exist, in flags.go it is commented out:
I have no idea how to activate second/third axis
Originally posted by @francmarx in https://github.com/AllenDang/giu/issues/632#issuecomment-1953693256