Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Bug Reports / Object In Screen w/ scaled objects doesn't work [7.6]

Author
Message
nhx
15
Years of Service
User Offline
Joined: 15th Apr 2009
Location:
Posted: 2nd Apr 2011 00:49
When objects are loaded and scaled down, object in screen() fails to report on them accuretly even though calculate object bounds() seems to be doing its job (see code below). They don't exactly behave as if they were at their original scale, but they don't act right either.

I can't duplicate this with built-in primitives, so provide your own meshes or download the attachment. I have tried it with five or so objects, none of which work correctly. Not just my own files but 'official' ones from TGC as well, although I didn't provide those in the upload in case that would ruffle feathers. It also seems broken w/ .x files the same way as .dbos.

If I'm not making some obvious mistake (which is totally possible) and this is in fact a bug, I really hope it can get solved soon. I have no good way of handling all sorts of occlusion-based things until this gets fixed.

I know there's a 7.7RC out but there is nothing in its changelog regarding this issue, so I assume it's not fixed & would rather not break my working code by upgrading until it's released.

Code follows, then screenshots, in case others can't duplicate the issue.






Attachments

Login to view attachments
Admiral MH
13
Years of Service
User Offline
Joined: 10th Feb 2011
Location: TX, USA
Posted: 5th Apr 2011 21:48 Edited at: 5th Apr 2011 21:49
Its working perfectly. When you export a model, you can choose where the "root" coordinate for object placement. That can be anywhere. Depending on preference and model design, most people either do the center of the object or at the bottom of the object for the root coordinate.

I have attached a example of 2 objects I made to show what I am talking about.

Attachments

Login to view attachments
KISTech
16
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 6th Apr 2011 18:18
I was having similar problems with a model that I had offset it's limb for attachment to another object, and I think it was IanM that told me the solution.

SET OBJECT FRAME Obj, 0.0, 3

Sets the object's animation frame to 0.0 and recalculates bounds for all frames. (even if the object has no animation)

Hope that helps.

Login to post a reply

Server time is: 2024-04-25 14:16:13
Your offset time is: 2024-04-25 14:16:13