Main Menu
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - judohin

#1
Support / Add Texture to Cylinder
February 17, 2012, 11:43:26 AM
I am developing a android with a panorama function.
So I add a Cylinder to the app like this.

cube = Primitives.getCylinder(2.0f);
cube.calcTextureWrapSpherical();
cube.setTexture("texture");
cube.invert();
cube.strip();
cube.build();

I use the calcTextureWrapSpherical() function, and the Texture duplicate like pic01 below.
And if i use calcTextureWrap() function, the texture become single color like pic02.
I have find a function recreateTextureCoords() in jPCT seem can fix this problem but it not exist in jPCT-AE.

Pic01
http://hkgetbonus.com/test/pic01.png

Pic02
http://hkgetbonus.com/test/pic02.png

Thank you!