|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
The ability to extract the elements from a declared transform.
F'rinstance:
#declare Place= transform {
scale <2,3,1>
rotate <45,-25,35>
translate <-3,0,3>
}
#local vX=<Place.m11,Place.m12,Place.m13>;
#local vY=<Place.m21,Place.m22,Place.m23>;
#local vZ=<Place.m31,Place.m32,Place.m33>;
#local vL=<Place.m41,Place.m42,Place.m43>;
I don't perceive this as being too difficult, and would give some of
the advanced users around here another tool.
--
ICQ: 46085459
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
In article <398DFCE9.9131A94C@erols.com>, John VanSickle
<van### [at] erolscom> wrote:
> The ability to extract the elements from a declared transform.
...snip...
> I don't perceive this as being too difficult, and would give some of
> the advanced users around here another tool.
It may not be too difficult...but how useful would it be? The only
things I can think of to do with a matrix in POV are transforming an
object, and transforming a vector. Since you already have a transform,
why not just use it directly in the object or in the vtransform()
function?
--
Christopher James Huff - Personal e-mail: chr### [at] maccom
TAG(Technical Assistance Group) e-mail: chr### [at] tagpovrayorg
Personal Web page: http://homepage.mac.com/chrishuff/
TAG Web page: http://tag.povray.org/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On Sun, 06 Aug 2000 20:03:53 -0400, John VanSickle wrote:
>The ability to extract the elements from a declared transform.
[...]
>I don't perceive this as being too difficult, and would give some of
>the advanced users around here another tool.
Can't you just make a macro that transforms the origin (for the translate
part) and the three basis vectors (don't forget to subract the translate)
to extract that info? You need vtransform, of course, but I'm guessing
you already have access to that.
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
John VanSickle <van### [at] erolscom> wrote:
: The ability to extract the elements from a declared transform.
If you are talking about the items inside the transformation matrix, then
you are right, it shouldn't be too difficult.
But as someone else said, how useful would it be to get individual values
of the matrix?
--
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
>
> John VanSickle <van### [at] erolscom> wrote:
> : The ability to extract the elements from a declared transform.
>
> If you are talking about the items inside the transformation matrix,
I am,
> then you are right, it shouldn't be too difficult.
> But as someone else said, how useful would it be to get individual
> values of the matrix?
The idea is that a macro could receive a declared transform and build
an object based on the contents of the macro; perhaps some of the
primitives in the object depend only on the translational component of
the transform, while others receive the full effect of the transform,
and perhaps the macro is supposed to remove any shearing from the
transform before building anything.
Granted, one could simply pass four vectors to the macro...
Regards,
John
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On 6 Aug 2000 22:27:03 -0400, Ron Parker wrote:
>On Sun, 06 Aug 2000 20:03:53 -0400, John VanSickle wrote:
>>The ability to extract the elements from a declared transform.
>
>[...]
>
>>I don't perceive this as being too difficult, and would give some of
>>the advanced users around here another tool.
>
>Can't you just make a macro that transforms the origin (for the translate
>part) and the three basis vectors (don't forget to subract the translate)
>to extract that info? You need vtransform, of course, but I'm guessing
>you already have access to that.
Here's what I'm talking about. I hope I didn't transpose the 3x3 part of
the matrix, but if I did you should be able to fix that easily enough:
#declare Place = transform {
scale <2,3,1>
rotate <45,-25,35>
translate <-3,0,3>
}
#declare vL=vtransform(0,Place);
#declare vXX=vtransform(x,Place)-vL;
#declare vYY=vtransform(y,Place)-vL;
#declare vZZ=vtransform(z,Place)-vL;
#declare vX=<vXX.x,vYY.x,vZZ.x>;
#declare vY=<vXX.y,vYY.y,vZZ.y>;
#declare vZ=<vXX.z,vYY.z,vZZ.z>;
#debug concat( "[ ", str(vX.x,3,3), ", ", str(vX.y,3,3), ", ",
str(vX.z,3,3), "] \n" )
#debug concat( "[ ", str(vY.x,3,3), ", ", str(vY.y,3,3), ", ",
str(vY.z,3,3), "] \n" )
#debug concat( "[ ", str(vZ.x,3,3), ", ", str(vZ.y,3,3), ", ",
str(vZ.z,3,3), "] \n" )
#debug concat( "[ ", str(vL.x,3,3), ", ", str(vL.y,3,3), ", ",
str(vL.z,3,3), "] \n" )
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
John VanSickle wrote:
>
> Warp wrote:
> >
> > John VanSickle <van### [at] erolscom> wrote:
> > : The ability to extract the elements from a declared transform.
> >
> > If you are talking about the items inside the transformation matrix,
>
> I am,
>
> > then you are right, it shouldn't be too difficult.
> > But as someone else said, how useful would it be to get individual
> > values of the matrix?
>
> The idea is that a macro could receive a declared transform and build
> an object based on the contents of the macro; perhaps some of the
> primitives in the object depend only on the translational component of
> the transform, while others receive the full effect of the transform,
> and perhaps the macro is supposed to remove any shearing from the
> transform before building anything.
>
> Granted, one could simply pass four vectors to the macro...
Or I could build a set of macros that replace declared transforms
with an array, and perform all of the standard transforms (as well
as shearing, inversion, etc.).
--
ICQ: 46085459
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On Mon, 07 Aug 2000 18:11:20 -0400, John VanSickle wrote:
>Or I could build a set of macros that replace declared transforms
>with an array, and perform all of the standard transforms (as well
>as shearing, inversion, etc.).
John, have you seen my posts on this subject, or have they gotten mislaid
somehow?
--
Ron Parker http://www2.fwi.com/~parkerr/traces.html
My opinions. Mine. Not anyone else's.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Ron Parker wrote:
>
> On Mon, 07 Aug 2000 18:11:20 -0400, John VanSickle wrote:
> >Or I could build a set of macros that replace declared transforms
> >with an array, and perform all of the standard transforms (as well
> >as shearing, inversion, etc.).
>
> John, have you seen my posts on this subject, or have they gotten
> mislaid somehow?
Oh yeah. I was just thinking aloud.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|