Vector3 <-> Vertex3

View: New views
2 Messages — Rating Filter:   Alert me  

Vector3 <-> Vertex3

by jamin1001 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello,

I am trying to use the GLU function unProject, which
returns a Vertex3, but I want a Vector3.  How do I
convert Vertex3, or get at the coordinate values?

Jamin
 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com 
_______________________________________________
HOpenGL mailing list
HOpenGL@...
http://www.haskell.org/mailman/listinfo/hopengl

Re: Vector3 <-> Vertex3

by jamin1001 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Never mind, the following can be done w/ pattern matching:


vertexToVector :: Vertex3 a -> Vector3 a
vertexToVector (Vertex3 x y z) = Vector3 x y z




jamin1001 wrote:
Hello,

I am trying to use the GLU function unProject, which
returns a Vertex3, but I want a Vector3.  How do I
convert Vertex3, or get at the coordinate values?

Jamin
 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com 
_______________________________________________
HOpenGL mailing list
HOpenGL@haskell.org
http://www.haskell.org/mailman/listinfo/hopengl
LightInTheBox - Buy quality products at wholesale price