Questions tagged [mathgl]

MathGL is a library for making high-quality scientific graphics under Linux and Windows

MathGL is a a library for making high-quality scientific graphics under Linux and Windows, for the fast data plotting and data processing of large data arrays, for working in window and console modes and for embedding into other programs and a library with large and growing set of graphics. See http://mathgl.sourceforge.net/

40 questions
3
votes
1 answer

Compiling mathgl C-Example

I'm trying to compile the first example of the MathGL library in C: http://mathgl.sourceforge.net/doc_en/Examples.html #include int main() { HMGL gr = mgl_create_graph(600,400); mgl_fplot(gr,"sin(pi*x)","",""); …
Stein
  • 3,179
  • 5
  • 27
  • 51
3
votes
4 answers

MathGL and Cmake

I'm trying to run mathgl with cmake and I'm having some problems. The code for the file test001.cpp is as follows: #include #include int sample(mglGraph *gr) { gr->Rotate(60,40); gr->Box(); return 0; } int main(int…
silgon
  • 6,890
  • 7
  • 46
  • 67
3
votes
1 answer

LNK2019 / LNK2001 errors: Why would a library provide a .cpp file with unimplemented functions? (How do they get implemented?)

I think I understand the gist of LNK2019 errors from reading SO and this MSDN article. I have one Why question and one How question (both asked in the title already). Why would a library provide a .cpp file with unimplemented functions? I'm guessing…
Andrew Cheong
  • 29,362
  • 15
  • 90
  • 145
3
votes
1 answer

Why does mglData cause a BAD ACCESS exception?

I have successfully managed to install MathGL on Mac OS and managed to get the mglGraph to generate me the sample graphs. Yet when I try to use mglData to handle my data, it crashes with an "EXC_BAD_ACCESS" error. Why? Is there anything I need to do…
Max Z.
  • 801
  • 1
  • 9
  • 25
2
votes
2 answers

Use of QMathGL to paint realtime data?

Got really stuck, need some advise or real examples. 1) I have boost::thread vector producer thread (data arrives fast ~ 100 samples per second) 2) I want QMathGL to paint data as it arrives 3) I don't want my Qt gui freeze I tried to move…
Maquefel
  • 480
  • 4
  • 16
2
votes
1 answer

How to show graphs on the screen using MathGL

I am learning MathGL, a C++ library, but I find myself cannot draw a graph on the screen even using the "example code" they provided, although I can successfully draw a graph to file. The "sample codes" on their official website is as…
Mark Z.
  • 655
  • 2
  • 9
  • 12
1
vote
1 answer

How to completely complie and install mathGL on Mac?

Please let me know if there is anyway I can get MathGL working on my computer. If there's any mistake in the following tests, pls kindly let me know. Thank you. Ok, I've been struggling this issue for quite a long time. Here's what happens when I…
Tippsie
  • 39
  • 6
1
vote
1 answer

Basic MathGL example in c does not compile

Here is the basic c example from the documentation: #include int sample(HMGL gr, void *) { mgl_rotate(gr,60,40,0); mgl_box(gr); } int main(int argc,char **argv) { HMGL gr; gr = mgl_create_graph_qt(sample,"MathGL…
m4r35n357
  • 111
  • 8
1
vote
0 answers

How to look-up for function/class definitions locally, before looking up the attached libraries? (Linker C++)

My observation: C++ Linker(Visual Studio specifically) takes __declspec(dllimport) too seriously, the linker looks up for definitions of any class/function declared with this directive, in the attached libraries ONLY. (Ignoring the definitions…
1
vote
2 answers

mathGl / MinGW undefined reference Netbeans IDE

I'm trying to compile the below code : #include #define HAVE_STRUCT_TIMESPEC #include using namespace std; int main() { mglGraph gr; gr.FPlot("sin(pi*x)"); gr.WriteFrame("test.png"); return 0; } I'm using…
Sholi
  • 11
  • 5
1
vote
1 answer

C++/MathGL: Missunderstanding of vector fields

I’m using MathGL 2.3.5.1 (http://mathgl.sourceforge.net/doc_en/Main.html) under Windows 10 with Qt 4.8.7. I have problems to use the vector field of MathGL. There is a documentation of MathGL with the file name mathgl-2.3.5.eng.pdf…
ThomasL.
  • 83
  • 1
  • 9
1
vote
0 answers

How to Embed MathGL Plots & Graphics in a win32 Application Window

I'd like to create and embed some simple plots into a GUI I've created in a Visual C++ win32 application. I could do something as simple as drawing rectangles and lines when handling a WM_PAINT message, but it'd probably be better in the long run if…
aquirdturtle
  • 2,038
  • 26
  • 20
1
vote
0 answers

CMake cannot find MathGL's dependency PNG

I'm trying to generate Visual Studio 2013 projects files for MathGL 2.3.3 with CMake. For some reason cmake does not understand my PNG_PNG_INCLUDE_DIR statement. cmake "-DZLIB_INCLUDE_DIR=c:\users\chenning\projects\zlib-1.2.8\"…
chhenning
  • 2,017
  • 3
  • 26
  • 44
1
vote
2 answers

Compile the first mathgl sample error

a test file named ml.cc, I have already installed the mathgl headers to /usr/local/include and libmgl.a to /usr/local/lib #include int main() { mglGraph gr; gr.FPlot("sin(pi*x)"); gr.WriteFrame("test.png"); return…
imotai
  • 2,006
  • 1
  • 12
  • 9
1
vote
0 answers

Running Programs in MathGL

I'm trying to run one of the examples using FLTK in Mathgl. While basic programs will compile without error, I seem to be getting a linker error when compiling FLTK_MathGL examples. This is the error portion I get from my build log.…
domonica
  • 526
  • 7
  • 14
1
2 3