Re: A simple to use graphic library ?



On 17 Mar 2006 07:52:45 GMT, Dominique.Micollet@xxxxxxxxxxxxxxxxxxxx
staggered into the Black Sun and said:
I am looking for a simple graphics library which I can suggest to
students of mine who are not very experienced programmers. The aim is
to graph a curve from a set of (x(t),y(t)) data, along time (e.g. one
point each second). Therefore I cannot use gnuplot :-)

OK, this makes it sound like you want to make a 3D graph (X and Y
graphed according to T). This will be a bit more complicated than a 2D
graph because display devices are almost all 2D. Lessee... I've used
POVRay to do a few things in 3D--that's not really a graphics
library, but a scene description language and an interpreter that
generates graphics from that language. You can do something like:

/* begin example.pov */
#include "colors.inc"
camera{
location <0,0,5> /* X 0 Y 0 Z 5 */
look_at <0,0,0>
} /* camera is at 0,0,5 looking at the origin */
light_source{ <0,0,6> color White }
/* light source is at 0,0,6 */

sphere{ <0,0.5,0> 0.1 pigment {Yellow} }
sphere{ <-0.1,0.4,1> 0.1 pigment {Yellow} }
sphere{ <-0.2,0.3,2> 0.1 pigment {Yellow} }

sphere{ <0,-0.5,0> 0.1 pigment {Blue} }
sphere{ <0.1,-0.4,1> 0.1 pigment {Blue} }
sphere{ <0.2,-0.3,2> 0.1 pigment {Blue} }

sphere{ <0.5,0,0> 0.1 pigment {Red} }

sphere{ <-0.5,0,0> 0.1 pigment {Green} }

/* povray +Iexample.pov +Oexample.png +H480 +W640 +P */
/* end example.pov */

....OK, this sort of requires an external program, and it may slow down
unacceptably if there are tons and tons of data points. It's also
impossible to pan around in real time. However, writing individual
points (spheres, whatever) to a .pov file isn't difficult at all. The
trick for this will be choosing appropriate positions for the camera and
light source(s).

I am looking for something such as the Borland Graphics library, which
was very simple to use. Any suggestion ?

No idea. I'm not sure what sort of Mathematica-like 3D plotting
libraries exist for Linux, although a search on freshmeat.net for "3D
plot" may uncover something.

--
Matt G|There is no Darkness in Eternity/But only Light too dim for us to see
Brainbench MVP for Linux Admin / mail: TRAP + SPAN don't belong
http://www.brainbench.com / "He is a rhythmic movement of the
-----------------------------/ penguins, is Tux." --MegaHAL
.



Relevant Pages

  • A simple to use graphic library ?
    ... students of mine who are not very experienced programmers. ... The aim is to graph a curve from a set of,y) data, along time ...
    (comp.os.linux.x)
  • Re: A simple to use graphic library ?
    ... students of mine who are not very experienced programmers. ... The aim is to graph a curve from a set of,y) data, along time ...
    (comp.os.linux.x)
  • Creating a Graph in Excel
    ... I'm work in a company with a production line that runs in different ... I would like to create a graph that has the "date" on the x- ... This graph should only include tons ... to zero and then bounce back when you switch over to that mode. ...
    (microsoft.public.excel)
  • Chart - Tons Per Hour & Efficiency (Up Time)
    ... I'm trying to generate a chart with Tons Per Hour on the Y - axis and ... I would also like to graph the Efficiency on the y-axis as ... maybe opposite to the Tons Per Hour. ...
    (microsoft.public.excel.misc)