2D Graphics Library
I have written a program that gathers information on nodes on an IP network. Information such as
2) Open ports
3) IP hops to node
4) Delay on the hops
I have also grouped the nodes together according to their subnets and have also written a piece of code which determines which nodes are most likely switches/routers/gateways etc. All of this is still far from perfect and plenty of holes, but this is not what my question is a bout, and was just trying to add some context.
I would like to now produce a 2D representation of this information. A sort of network map with additional information (link delays, open ports etc). I would also like to export the image into a graphics format such as gif/png etc.
What library can you guys recommend me to make use of ?
I have very little experience with graphics, but given the right library that can do what i need it to do i am sure i can figure it out.
All help is appreciated !
Free Graphics Libraries - freeprogrammingresources.com seems to have a bunch of 2d graphic libraries for c++. I've never done graphics, so that is about as much help as I can offer. Good luck
You might want to try allegro, I've been using it for a long time, and it's managed to do everything that I want out of it as far as 2D graphics goes.
well let's see...
to display the data you might need nice GUI...
are you using microsoft product with it's MFC... check on codeproject.com.. there are plenty of nice graphic library based on this MFC....
if you are not using microsoft product, let's say Linux with Qt or wxWidgets environment, I think they have their own graphic library bundled together... this wxWidgets is very nice, i have tried...
I am programming in windows using .NET but i have not written it in MFC so i believe i would have LOTS of issues with trying to port it over to a Form class.
Quicly read thru the wxWidgets link and look like a nice way to generate my user interface, but does it help me "draw" my network image?
I was thinking at first "drawing" my network map and then later using a GUI library to just load that image.
Will look thru the above links later today.
I would recommend Qt, it has awesome painting engine AND easy way to paint.
It easier than wxWidgets, GTK, or other 2D graphics library because of its instaneous installer -- just install and use, no complicated cofiguration, compilation and integration.
It also support printing and saving graphics context (anything drawn on the screen) feature which likely you need.
I merged my code to work now with the .NET interface and can make use of the forms class.
So now looking for a 2 library to "paint" my network topolgy.
Gonna look now at that link of auralius.
Any more ideas would be great!
good... making some progress...
just find with keyword: c#.net chart
may be u can ask in .net forum...
c++ programmer is a bit sensitiv with this .net technology since sometimes we can not find a reason why we should use it...
I looked at that link and by the looks of that its just for creating graphs which is not want i want.
Ideally i would like to draw a map of my network topology. Place icons (or even just squares) that i can then link up with lines accordingly. Then if i could label the host and links would be great.
i also recommend this
Originally Posted by audinue
Have a look at Graphviz and "dot" files. It's a very simple system for describing relationships between objects and outputting professional looking charts. There may also be libraries for doing this internally in your C++ program. You basically just specify the types of nodes, and in what style they should be displayed, and then you name all the nodes and the links between them (which is what you have). I use it at work to automatically generate UML diagrams all the time.
Thanks Sean ! This looks like it will work for me ! :D