Texture repeat

Software: Away3D 4.x

Avatar
Apprentice, Jr. Member
Posted: 16 August 2011 09:04 AM   Total Posts: 45

Texture repeat by setting the ‘repeat’ property on a material to true (material.repeat = true) appears to have no effect. I’ve tried the example UVAnimationTest in the Away3D examples where repeat is also set to true. I only see one set of eyes (I’m guessing multiple should be seen). When I set it to false there is no visual difference.
But in the WaterTest example setting the repeat property to true or false it does have a visual difference.
Has any one else had trouble with texture repeat? It worked fine for me in the past.

—Apprentice

   

Avatar
theMightyAtom, Sr. Member
Posted: 16 August 2011 10:35 AM   Total Posts: 669   [ # 1 ]

There’s another example here:
http://videometry.net/broomstick/TextureBroomstick.html

If you post some code it’s easier for us to see where it goes wrong wink
At a guess, you’re expecting your material to start tiling automatically by setting repeat to true, but it will only repeat if the UV’s suggest it should.

Good Luck!

   

John Brookes, Moderator
Posted: 16 August 2011 10:41 AM   Total Posts: 732   [ # 2 ]

yourMaterial.repeat = true;
yourMaterial.animateUVs=true;

yourMesh.subMeshes[0].scaleU=20;
yourMesh.subMeshes[0].scaleV=6;

   

Avatar
Apprentice, Jr. Member
Posted: 16 August 2011 12:11 PM   Total Posts: 45   [ # 3 ]

Hmm, well if you guys are not having trouble with it then there must be something wrong on my end. Just a bit puzzled as the same model worked fine 2 months ago in Away3D4. I’ll have to do some small tests when our artist returns in 2 days (I’m not very skilled in 3ds Max) and then I’ll get back to this thread.
Thanks for the replies.

—Apprentice

   

Richard Olsson, Administrator
Posted: 18 August 2011 06:47 AM   Total Posts: 1192   [ # 4 ]

Have you, like John suggests, made sure that the animateUVs property is set to true, and that the UVs are scaled.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X