First off- I just want to say this is my first post here, and I am new to Away3D… I’ve always been intimidated to jump into 3D.. Even though I’ve used a little 3dsMAX and stuff for video projects, it always seemed scary to do it from the programming side.
A few hours with Away3D, and I’ve got it up and running even with some interactivity. No doubt you guys are doing all the heavy lifting under the hood, and I can’t thank you enough for the hard work so I can get right into the content without breaking my head too much. My favorite thing about coding in Flash is that you can get to the fun stuff quickly. This is how it should be for 3D too… so thanks!
Ok, now my first question
I load in a material and create a cylinder like this:
poleMaterial = new TextureMaterial(new BitmapTexture(preExistingBitmapData),true, true);
poleMaterial.repeat = true;
poleMaterial.animateUVs = true;
var cG:CylinderGeometry = new CylinderGeometry(10, 10, 400);
var mesh:Mesh = new Mesh(cG, poleMaterial);
cG.topClosed = true;
cG.scaleUV(1, 2);
addChild(mesh);
the .scaleUV part and .animateUVs are just a guess to try and fix the problem…
which is that the bitmap is not tiling, though I want it to.
Any idea how to make the bitmap tile? When I leave out the scaleUV, it shows it once. when I put in the scaleUV(1,2) it does sort of tile, but at half the height and with gaps in between.
I just want it to tile smoothly. I can recreate the texture if necessary (right now it’s 64x64, but that’s arbitrary)
It also needs to tile smoothly even if the cylinderGeometry will change in height (this can happen as part of the game)
Thanks!