the camera was pointed in front of the object. -10 would put the
camera 10 in front of the object. If you set the z to 200 it works
well. and a few other minor tweaks.
Scott
On Jul 10, 2006, at 11:32 AM, [EMAIL PROTECTED] wrote:
On Jul 10, 2006, at 14:26 UTC, Carl Adler wrote:
I am trying to learn how to work with 3d objects by experimenting.
That's kind of a tough way to go when it comes to 3D graphics,
since many errors will result in you seeing nothing at all -- the
camera might be pointed nowhere near your object, for example, or
you might have the object outside your Hither-Yon range, or the
camera might actually be inside the object, or you could be looking
at your object's (transparent) backside.
You might try starting with examples that are known to work,
instead. There are quite a few that come with RB (or are
downloadable from the RS web site), more that come with the RB3D
FAQ (http://www.strout.net/info/coding/rb), and some full 3D games
with source available at <http://www.codenautics.com/>. Oh, and
there have been quite a few articles on 3D in RB Developer, too.
I have the following code in "open" under Rb3dSpace
-------
dim nn as Object3d
nn = new object3d
nn.AddShapePicture splash2,2
nn.Pitch 3.14/2
This pitches the object 90 degrees down. You'd be looking at it
edge-on, and it's infinitely thin, so you wouldn't be able to see
it. Why are you doing this?
nn.Position.y=0
nn.Position.x=0
nn.Position.z=0
No need for these lines; that's where any new object starts anyway.
me.camera.position.z = -10.0
me.camera.position.x = 0
me.camera.position.y = 0
me.camera.yaw 3.1416
OK, this may be reasonable; you're moving the camera back 10 units
and then rotating it around 180 degrees. But your object is a lot
bigger than 10 units; you should consider moving it back more like
100. I'm not sure whether the rotation is right, either. Try it
with and without that.
Rb3DSpace1.objects.Append nn
Right.
Rb3DSpace1.update
Not necessary (but doesn't hurt either).
Add nn.RenderBackfaces = True too, so that you'll see your object
even if you're looking at it from behind.
HTH,
- Joe
--
Joe Strout -- [EMAIL PROTECTED]
Verified Express, LLC "Making the Internet a Better Place"
http://www.verex.com/
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>