[Papervision3D] Accessing the movie frames in InteractiveMovieAssetMaterial?

Andy Zupko azupko at zupko.info
Thu Sep 6 14:11:30 PDT 2007


One problem you are probably having is that you are using the same material
for every plane.  Any change you make to the material will then be displayed
on every object using it.  The fix to create a new material for each object
(just put the material instatiation in the loop).

If you are having a problem still, call updateBitmap on the material after
you change the movie frame within it.  This will save you CPU over making
each material being animated (unless you want to animate it...).

Hth!

-andy

-----Original Message-----
From: papervision3d-bounces at osflash.org
[mailto:papervision3d-bounces at osflash.org] On Behalf Of Noah Aronsson-Brown
Sent: Thursday, September 06, 2007 3:20 PM
To: papervision3D at osflash.org
Subject: [Papervision3D] Accessing the movie frames in
InteractiveMovieAssetMaterial?


I want to tell a movieclip that i'm using as a material to gotoAndStop on a
different frame during a for loop, so i'm using the same system as the
InteractiveFLVMovieMaterial example.

here is the for loop:

	for(i = 0; i < num; i++ )
	{
		item = new Plane( material, 100, 100 );
		item.name = 'side'+i;
		scene.addChild( item );
		
		getMovie().gotoAndStop(i+1); //this is what is giving me
trouble
		trace(getMovie());
		
		item.x = boxXNums[i];
		item.y = boxYNums[i];
		item.z = boxZNums[i];

		//item.lookAt(camera);
		
	}

and here is the getMovie() function:

function getMovie():MovieClip
{
	return InteractiveMovieAssetMaterial(item.material).movie as
MovieClip;
}

I've been pulling my hair out trying to get it to work but I can't do it.
Can anyone smarter than I please give me a clue?

Thanks,

.noah

-- 
View this message in context:
http://www.nabble.com/Accessing-the-movie-frames-in-InteractiveMovieAssetMat
erial--tf4394173.html#a12529583
Sent from the Papervision3D mailing list archive at Nabble.com.


_______________________________________________
Papervision3D mailing list
Papervision3D at osflash.org
http://osflash.org/mailman/listinfo/papervision3d_osflash.org




More information about the Papervision3D mailing list