Replies: 1 comment
-
Yes. It's missing lots of features. It has always been experimental and never left this state. The idea is that gnuplot and opengl would be two of many backends. Other backends could be the console, QT, ImGUI, etc... The real problem is I never had the time to work on that outside my day job. I never found anyone to work on that either. If I were doing that today (I probably won't have the time any time soon), I think I would refactor the backend interface to fix problems we have identified along the way. In the end, this would mean matplot++ v2.0.0.
This is kind of similar to the python matplotlib backend interface, although types make it more complex. These changes mean gnuplot would be discontinued unless we create a gnuplot backend that can draw things in terms of primitive values (which would also make it gnuplot kind of useless in any way that's not for backward compatibility). The first backends I would implement in this new model would be SDL and console, although there's room to discuss alternatives. |
Beta Was this translation helpful? Give feedback.
-
Hi I am doing a simple compare between the GnuPlot backend and the OpenGL backend. I was looking into making a contour plot or a 3D plot but before all of that I was trying to see what is missing between a simple 2D plot
The following code
int main() {
using namespace matplot;
std::vector x = linspace(0, 2 * pi);
std::vector y = transform(x, [](auto x) { return sin(x); });
}
produces the following plot
gnuplot output
Now for the OpenGL backend I have changed the code to the following
using namespace matplot;
which produces the following
I am not sure if the above code is missing anything but I wrote based on the test example for the OpenGL backend.
Looking at the plots, the OpenGL backend is lacking the following:
I assume for the above that OpenGL is still very early and likely 3D and contour plots are not supported. Is this correct ?
I understand the difficulty of providing the capability but I was wondering if there is a timeline OpenGL backend would have additional feature support.
Appreciate the great effort put into this work.
Beta Was this translation helpful? Give feedback.
All reactions