Blender Loader – texCoord2 support [REQUEST]

Hi!



I would like to ask texCoord2 support for blender models. At present, it’s possible to get only texCoord1, but LightMaps require texCoord2 support.



I tested Blender’s meshes for TexCoord2, but it makes NULL Exception:

[java]

System.out.println(geom_sc.getMesh().getBuffer(VertexBuffer.Type.TexCoord2).toString() + " texCoord2"); // NULL Exception

[/java]



So, I would like to ask Core Devs and @Kaelthas for texCoord2 support. It’s really vital in many cases. By the way, Ogre.xml supports up to texCoord8 and blender only texCoord1. :frowning:



Here is my screenshot of explanation:

http://i.imgur.com/uoFu6.jpg





LightMap looks like:

https://rise-of-mutants.googlecode.com/hg-history/38532fbeae5e03d51373a0d523db5f3457f5ee93/dev/trunk/TechDemo/assets/Scenes/levels/level_01/textures/level_01_oa.png





Thanks.

I agree all tex coord should be imported.

Me too :|.

Me three. I use this a lot, plus it good to see Lighting has been updated to support this also (not sure when that slipped in, no doubt ages ago :wink: )

Yeah!! we need to get it from blender.



I tried my scene with Lightmaps and Ogre importer. Very nice result. I hope blender will be able to make it too.





OGRE MODELS:



http://i.imgur.com/KIuBg.jpg



http://i.imgur.com/feEDz.jpg



http://i.imgur.com/Kkiep.jpg

1 Like

@Kaelthas sorry to bump this, but could you please look into it?
I tried to look in the blender loader code, but I dug way down to the MeshBuilder and got stuck when reading the data from the blend file structure.

Also I noticed something in MeshHelper that could be a problem.
Line 226 to 238 you use the same texCoord VertexBuffer for several meshes. That can be an issue, , you would create one different buffer for each mesh.