POV-Ray : Newsgroups : povray.advanced-users : POVRay referencing object rotation values Server Time
29 Apr 2024 14:23:07 EDT (-0400)
  POVRay referencing object rotation values (Message 1 to 4 of 4)  
From: bublible
Subject: POVRay referencing object rotation values
Date: 16 Mar 2015 10:50:00
Message: <web.5506ec6e7660ce39b91df8500@news.povray.org>
How can I reference an object in POVRay? I mean I want to rotate another object
on axis X by another object's rotation value of its Z axis.

I am thinking about something like this (this of course does not work, just to
show you what I mean):

// lets say before I #declared two objects named ObjA & ObjB
Object {
    ObjA
    rotate <ObjB.rotation.z, 0, 0>
}

Any suggestions, please?


Post a reply to this message

From: Le Forgeron
Subject: Re: POVRay referencing object rotation values
Date: 16 Mar 2015 12:24:29
Message: <550703bd$1@news.povray.org>
Le 16/03/2015 15:45, bublible a écrit :
> How can I reference an object in POVRay? I mean I want to rotate another object
> on axis X by another object's rotation value of its Z axis.
> 
> I am thinking about something like this (this of course does not work, just to
> show you what I mean):
> 
> // lets say before I #declared two objects named ObjA & ObjB
> Object {
>     ObjA
>     rotate <ObjB.rotation.z, 0, 0>
> }
> 
> Any suggestions, please?
> 
> 
You can't, as you intended at least. Access to object's property is not
possible in read mode so far.

When declaring ObjB, you could also declare a variable to hold the
rotation around Z used on B, and use that variable later on A.


Post a reply to this message

From: bublible
Subject: Re: POVRay referencing object rotation values
Date: 16 Mar 2015 12:50:01
Message: <web.550707dc9ab52d1b91df8500@news.povray.org>
Le_Forgeron <jgr### [at] freefr> wrote:
> Le 16/03/2015 15:45, bublible a écrit :
> > How can I reference an object in POVRay? I mean I want to rotate another object
> > on axis X by another object's rotation value of its Z axis.
> >
> > I am thinking about something like this (this of course does not work, just to
> > show you what I mean):
> >
> > // lets say before I #declared two objects named ObjA & ObjB
> > Object {
> >     ObjA
> >     rotate <ObjB.rotation.z, 0, 0>
> > }
> >
> > Any suggestions, please?
> >
> >
> You can't, as you intended at least. Access to object's property is not
> possible in read mode so far.
>
> When declaring ObjB, you could also declare a variable to hold the
> rotation around Z used on B, and use that variable later on A.

Unfortunately I can not because ObjB's and its rotation values are set somewhere
else (or not in "classic" rotation values for x,y,z), not by me (although just
for this example I said "I declared both
objects"), that is the primary reason why I am in big need for that value: I
created Polygon that should always automatically rotate to proper angle to
always face camera from the front according to rotating of the ObjB that was
deffined by another script and software (LDD-to-Povray) and I do not know where.
It is I know ObjB's name but that's it... :(


Post a reply to this message

From: clipka
Subject: Re: POVRay referencing object rotation values
Date: 16 Mar 2015 15:14:49
Message: <55072ba9$1@news.povray.org>
Am 16.03.2015 um 17:46 schrieb bublible:

>> When declaring ObjB, you could also declare a variable to hold the
>> rotation around Z used on B, and use that variable later on A.
>
> Unfortunately I can not because ObjB's and its rotation values are set somewhere
> else (or not in "classic" rotation values for x,y,z), not by me (although just
> for this example I said "I declared both
> objects"), that is the primary reason why I am in big need for that value: I
> created Polygon that should always automatically rotate to proper angle to
> always face camera from the front according to rotating of the ObjB that was
> deffined by another script and software (LDD-to-Povray) and I do not know where.
> It is I know ObjB's name but that's it... :(

Then unfortunately you are out of luck.

BTW, LDD-to-Povray sucks big time in terms of playing nice with other tools.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.