From: Osmany Guirola Cruz (osmany.guirola_at_cigb.edu.cu)
Date: Wed May 26 2004 - 07:36:13 CDT

Thanks for the code Axel
 i have a little experience with OpenGL and whit it i can assign diferent
colors to vertex and draw lines AND Ngon with a gradient of colors. Can i
use these properti of OpenGL in VMD. an another question i normally use
draw color red green etc etc , but can i use something like glcolor3f(R,G,B)
to draw a line whit a "specifiv color".
Thanks
Osmany
  

On Wednesday 26 May 2004 02:01 am, Axel Kohlmeyer wrote:
> On Tue, 25 May 2004, Osmany Guirola Cruz wrote:
>
> OG> Hi people
> OG> How can i read a set of coords. from a file and draw lines whit these
> OG> for example :
> OG> i have a lines file:
> OG>
> OG> 1 2 3
> OG> 4 5 6
> OG> 7 8 9
> OG>
> OG> and i want do
> OG>
> OG> draw line "1 2 3" "4 5 6"
> OG> draw line "4 5 6" "7 8 9"
>
> hi,
>
> how about the following code?
>
> ===================================
>
> set fp [open "lines.dat" r]
> set dat1 ""
> set dat2 ""
> while { ![eof $fp] } {
> set dat2 $dat1
> set dat1 [gets $fp]
> if { ("$dat1" != "") && ("$dat2" != "") } {
> draw line $dat1 $dat2
> }
> }
> unset dat1
> unset dat2
> close $fp
> unset fp
>
> ====================================
>
> axel.
>
>
> OG>
> OG> i need these to draw lines in my scene trougth certain residues
> OG>
> OG>