[Jprogramming] opengl
schott.brian at gmail.com
schott.brian at gmail.com
Mon Feb 6 22:26:20 HKT 2006
Chris,
Thanks for cleaning up my dead simple example. I
think your use of LRotate is key to getting this right.
On my computer, your example does not seem to work
though. I took the liberty of changing the magnitue of your
command as follows to see if there was some movement that I
just could not see, but there was no movement.
+ glrotate 2 3 5 NB. your original
glrotate 20 30 50 NB. my enlargement
I can only see a box in original position, no
rotation. From the excerpt below you can also see that
executing "go''" alone, produces an error, too. Does that
happen on your Box, too (pun on the work Box)?
load '/Users/brian/j504/addons/turtle/chris.ijs'
ROTXYZ NB. but Box is NOT rotated on the graphic
20 30 50
(9!:12;9!:14)''
+-+---------------------+
|5|j504/2005-03-30/13:35|
+-+---------------------+
go''
|domain error: glNewList
| startlist LRotate
On Mon, 6 Feb 2006, Chris Burke wrote:
+ schott.brian at gmail.com wrote:
+
+ > Below I have produced a pretty dead simple script,
+ >but I can't even get one go'' to work. I'll continue to
+ >work on it to see if I can get that to work, but I thought
+ >it would give you or somebody something to start with.
+ >
+ >
+ require 'opengl'
+ coinsert 'jgl3 jzopengl'
+
+ AMBIENT=: 0.15
+ DIFFUSE=: 0.7
+ SPECULAR=: 0.7
+ ROTXYZ=: 40 50 0
+
+ go=: 3 : 0
+ glrotate 2 3 5
+ startlist LRotate
+ stdrotate''
+ endlist''
+ stdpaint''
+ )
+
+ A=: 0 : 0
+ pc a closeok;
+ xywh 0 0 200 200;
+ cc g isigraph ws_clipchildren ws_clipsiblings rightmove bottommove;
+ pas 0 0;pshow;ptop;
+ rem form end;
+ )
+
+ a_g_paint=: stdpaint
+ a_g_size=: stdsizeaspect
+
+ sys_timer_z_=: 3 : 0
+ try. go '' catch. wd 'timer 0' end.
+ )
+
+ wd A
+ glreset''
+ glaRC''
+ LISTS=: NURBS=: QUADS=: ''
+ glEnable GL_DEPTH_TEST
+ glclearcolor CLEARCOLOR
+ glcolor COLOR
+ stdlistlight''
+ genlist 'Box'
+ drawcube makelist Box 0 0 1
+ a_g_size''
+ wd 'pshow'
+ wd 'timer 15'
+
+
+ ----------------------------------------------------------------------
+ For information about J forums see http://www.jsoftware.com/forums.htm
+
(B=) <----------my "sig"
Brian Schott
Atlanta, GA, USA
schott DOT bee are eye eh en AT gee em ae eye el DOT com
http://www.cpu-net.com/host/bschott/
More information about the Programming
mailing list