How can I easily install a C++ plot library on a Mac?

In summary, the person is trying to install a plot library and is having trouble. They mention that some of the errors they are getting might be due to missing files. The person also has an Ubuntu machine and is wondering if they should switch to Xcode.
  • #1
KleZMeR
127
1
Hi All,

Not sure if this is the right place for this thread but it seemed like it was.

I have been trying for two whole days to get some plotting tools up and running that will work with my:
OSX 10.8.5, Xcode 5.1.

I have tried MathGL, Plplot, Gnuplot, Chplot, matplotpp, etc.

I get errors that I can't seem to fix when installing and/or running these. There's either missing files, linker errors, etc
I think my main issue is upon install when I am supposed to run 'make' in the active directory it does nothing on my machine. I have looked up all my errors, including the build errors, and tried valiantly to get just ONE of these working. I don't think it should be this hard?

Does anyone have any suggestions as to an easy install of a C++ plot library?

I also have an Ubuntu machine which I may just switch to, but I was really hoping to use Xcode being that my thesis work will be on a Mac/Xcode platform.

Thanks in advance, any help is appreciated.
 
Technology news on Phys.org
  • #2
OK, so, VTK seems to be installing... I got through the build and configure... fingers crossed
 
  • #3
And it errors out at 45% during install... If anyone can help I'd appreciate it, this is becoming frustrating
 
  • #4
One thing you might look at if you are having trouble running a make file is to see if your PATH declaration has all the directories in it that are required.
 
  • #5
I've noticed that some of these builds have a cMakeList.txt file and if I run: cmake . command it will carry out the list. I've gotten past this just now in VTK but the error and an internet search is telling me that I must "simply remove the -fobjc-gc flag from VTK_REQUIRED_OBJCXX_FLAGS" . I'm trying to do this now I guess.
 
  • #6
So I've tried to update my CMakeList.txt to fix this error but to no avail: still getting this: error: garbage collection is no longer supported. I was told to "
simply remove the -fobjc-gc flag from VTK_REQUIRED_OBJCXX_FLAGS." , which I did, and it does not fix the error
 
  • #7
When I did a data mining class the lecturer used GNUplot.

If your make command doesn't do anything you need to make sure the programming tools are setup in your distribution and your user account.

I would get the make issue fixed before anything else is done.
 

What is the purpose of plotting and graphics in C++?

The purpose of plotting and graphics in C++ is to visually represent data and information in a graphical format. This can make it easier for users to understand and analyze the data, as well as make the program more visually appealing.

What are some common libraries used for plotting and graphics in C++?

Some common libraries used for plotting and graphics in C++ include OpenGL, SDL, and Qt. These libraries provide a wide range of functions and tools for creating 2D and 3D graphics, as well as handling user input and interactions.

How do I plot a simple graph in C++?

To plot a simple graph in C++, you can use a library like GNU plot. First, you need to include the appropriate headers and set up your data points. Then, you can use the library's functions to create the graph and customize its appearance. Finally, you can save the graph to an image file or display it on the screen.

Can I create interactive graphics in C++?

Yes, you can create interactive graphics in C++ using libraries like OpenGL and SDL. These libraries allow you to handle user input, such as mouse clicks and keyboard presses, and use them to manipulate the graphics on the screen. This can be useful for creating games or other interactive programs.

Are there any limitations to plotting and graphics in C++?

There are some limitations to plotting and graphics in C++. For example, it may not be as efficient as other programming languages specifically designed for graphics, like Java or Python. Additionally, C++ may have a steeper learning curve for beginners compared to other languages. However, with the right libraries and knowledge, you can still create high-quality and visually appealing graphics in C++.

Similar threads

  • Programming and Computer Science
Replies
1
Views
3K
  • Programming and Computer Science
Replies
15
Views
5K
  • Programming and Computer Science
Replies
1
Views
274
  • Programming and Computer Science
Replies
13
Views
3K
  • Programming and Computer Science
Replies
2
Views
1K
  • Programming and Computer Science
Replies
4
Views
3K
  • Programming and Computer Science
Replies
2
Views
2K
Replies
4
Views
2K
  • Computing and Technology
Replies
5
Views
1K
  • Programming and Computer Science
Replies
15
Views
5K
Back
Top