[Papervision3D] adding copyTransform to Matrix3D and getting back a pure array
Adam Robertson
oldskool73 at gmail.com
Thu Feb 8 16:01:13 EST 2007
I'm no expert on the PV or R5 code, so am just playing Devils advocate here,
but could that functionality be part of your Red5 connection class instead?
E.g.
starSystemConn.updateShipRotation(red5ID, currentRotationObj);
...then the 'R5 PV3D Connection' class (a subclass of a normal R5 connection
class I guess) knows how to convert a Matrix3D to an array or whatever it
needs to work with?
Keeps PV3D code clean, and creates a specific specialised Red5<->PV3D
connection class where all the logic takes place.
Just a thought :)
Adam
On 2/8/07, John Grden <neoriley at gmail.com> wrote:
>
> [ i'm posting this to the list for other comments ]
>
> Hey Carlos, do you think we can add this method to Matrix3D or do you
> think I should just create my own subclass and add this method?
>
> for passing the transform data over RTMP, I needed to create a basic
> array, and then on the receiving end, I pass that array to a new Matrix3D
> object etc. What do you think?
>
> *// my call looks like this:*
> starSystemConn.updateShip(red5ID, copyTransform(
> currentRotationObj.transform));
>
> public function copyTransform( m:Matrix3D ):Array
> {
> var ary:Array = new Array(
> m.n11, m.n12, m.n13, m.n14,
> m.n21, m.n22, m.n23, m.n24,
> m.n31, m.n32, m.n33, m.n34 ,
> m.n41, m.n42, m.n43, m.n44
> );
>
> return ary;
> }
> *I'd like it have it like this:*
> starSystemConn.updateShip(red5ID, currentRotationObj.copyTransform());
>
> --
> [ JPG ]
>
> _______________________________________________
> Papervision3D mailing list
> Papervision3D at osflash.org
> http://osflash.org/mailman/listinfo/papervision3d_osflash.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://osflash.org/pipermail/papervision3d_osflash.org/attachments/20070208/5a3ee1cf/attachment.htm
More information about the Papervision3D
mailing list