On Jul 10, 2006, at 13:00, [EMAIL PROTECTED]
wrote:
Subject: Re: Problem with AddShapePicture
From: [EMAIL PROTECTED]
Date: Mon, 10 Jul 2006 10:32:08 -0600
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.
That is what I am trying to learn. I am recovering from surgery and
have plenty of time to "waste" (so to speak). Also I have found in
physics the best way to learn is to do.
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 looked at the examples and they are a help. I also subscribe to
RBdeveloper.
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?
Actually I tried all sorts of angles. This is the one I last used.
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.
OK. That is probably it. I will give it a try.
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.
OK Thanks for everything.
Carl
HTH,
- Joe
--
While sailing, anything that does not kill you is by definition fun.
_______________________________________________
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>