Oxygen Basic
Programming => Example Code => Graphics => Topic started by: Charles Pegge on May 17, 2013, 04:54:08 PM
-
A suggestion of shadow, Simple to implement.
The shadows operate on the same principle as smoke and cloud, only using shades of transparent black.
X
-
the "material.inc" file is missing there and "hemisphere" function should rename as "hemisphiric()" function, I cannot run this example. the example looks however good ;)
best regards, frank
-
Hi Frank,
Here is the complete examples/opengl folder. Everything should be in sync now, I hope.
X
-
Adding simple Ball bouncing physics, with MIDI percussion
'BOUNCING BALL
glPushMatrix
static single va=10000,yp=4.00,yv=.00, ya=.004
yv-=ya 'acceleration
yp+=yv
if yp<0
yv=-yv*.9 'bounce with energy loss
if yv<ya
yv=0 'limit rebound
else
va*=.9
ding sqr(va),35 'vol 10..127 : percussion 35..81
end if
yp=0
end if
glTranslatef 2.5,-1.5+yp,-6.0
glScalef .5,.5,.5
glCallList sphere
glPopMatrix
X
-
thanks charles, the new tiles example is finally working here :-)
I changed some materials for a test too. see added picture. more questions about materials and colors will come next time.
frank
X
-
here's a simple test for bouncing cubes and sphere with little ears :-) all three cubes have different velocities, masses and rotation modi. the cloud animatino I have started earlier and took/add a second rendering cloud.
demo exe + oxygen.dll you find in zip folder.
charles, for me that could be a really interesting (simple) starting point for a "physical engine", isn't it? ;)
best regards, frank
X