by date
Plan for Joe Sulewski
Plan for Joe Sulewski
| Name: | Joe Sulewski | |
|---|---|---|
| Date Posted: | Jun 14, 2004 | |
| Rating: | 3.5 out of 5 | |
| Public: | YES | |
| Comments: | YES | |
| RSS Feed: | or Subscribe with . | |
| Profile Page: | View profile page for Joe Sulewski |
Blog post
Blender to .map exporter
Sample .map
I am currently working on an exporter for Blender to generate .map files. I'm on a Mac and I have no access to a PC or a modern Linux box. Which means that if I'm going to work with Torque and see my ideas visualize then I must get this exporter working. So yes, my motivation is high. I'm working on this with Scott Coursey and he's working on tools and lighting. I'm working on the map format itself for brushes.
It's coming along quite nicely if not slowly. I'm very new to all this especially Torque and to be honest haven't done much other than run through some tutorials. I have map2dif compiled and running under OS/X from the April head.
I didn't want to write this plan until I had some more features working but I have unfortunately hit some road blocks. So I'm hoping someone who understands how interiors are handled can help with some questions. Being new to the product I'm sure the questions are such that an expert can handle these questions quickly enough. I could troll through the code or ask but I'm taking the easy way and asking, if no one responds I'll go through the code. It's been a long time since I've worked with C++ and 3D so that path may take awhile. :)
Here's what's working and I'll post some screen captures as soon as I figure out how to do that and embed them into this document. Currently, you can build structures with blocks, tubes and cones and export them to a .map file easily. You can even apply textures to each face. If you rotate a brush the texture will rotate as well so that it matches what you see in Blender. You can even rotate the texture in the UV editor and it shows up correctly in Torque. Again, once I figure out how to do screen captures this will be easier to describe.
There are two major areas that are breaking many other things. The simple problem is on the topic of scaling. Why is it that when 1 1 are used for scaling the texture doesn't fill the entire face? To get a texture to do this I have to figure out the hight and width of the face and divide that by the image size. The value of this calculation causes the texture to size correctly. Although in some instances this does not work so I'm sure this is an incorrect answer.
So here's question 1. How do you get the texture to map directly onto the face without repeating? I would expect 1 1 to do this but this isn't the case.
The second problem is offsets. For brushes that are centered around 0,0,0 in object space, not world space but object space, texture position, scaling (as described above) and rotation work perfectly. But once an object is moved the texture map is adjusted. I figured that the offset needs to be set to the upper left corner of the face but this only works for textures that are not rotated or scaled. Once you rotate or try to scale a texture for a brush who's not based around 0,0,0 things get messed up. In fact I even have an instance were the texture is rotated and I'm not adding any rotation to the texture, the texture vector is 0 0 1 0 and has a scale of 1 1.
When you offset the texture in the UV editor in Blender you get a normalized value from 0->1. My guess was to take the value and multiply it by the texture size and add that value to the offset for objects not based around 0,0,0.
So here's question 2. How do the texture offsets work?
My big issue seems to be with offsets. It seems that scaling is effected depending on where the object is placed in object space.
If this sounds like nonsensical dribble please let me know and I will try to describe this again. Only with pictures! If you have any information that can help or know of someone I can contact please let me know.
I figured out how to add screen captures
The first image shows how I'm able to add objects to the world and apply different textures to the objects. The big white object with numbers is centered around 0,0,0 in object space. Each face has a scale of 1 1, notice how the images are tiled and not scaled to fit to the face. Also notice how the smaller cube with the black and white checkerboard has a small area of black and white at the top. That means the texture isn't starting at the upper left corner of the face like the faces in the big block. See what I mean, depending on where the brushes are the offsets are messed up.
Also notice the small ramps that bridge the two blocks. Notice how the texture is rotated to look right on the brush. That is perfect.

The next image shows how my objects have the textures scaled to fit to the face. but once again the top of the checkered texture isn't right.

Rotating the texture intentionally in the Blender UV editor yields this image.
Notice once again the offset in the small block.

Finally, here is an odd one. Contrast this with the first image where the scaling is set to 1 1 and you can see four number 2's. Now I rotate it and you can see 9 number 2's which means the image is scaled as the object is rotated.

It seems that the textures are applied differently depending on where in object space each brush lies and scaled depending on the brushes rotation.
Any ideas? Thoughts? Comments? Please?
I am currently working on an exporter for Blender to generate .map files. I'm on a Mac and I have no access to a PC or a modern Linux box. Which means that if I'm going to work with Torque and see my ideas visualize then I must get this exporter working. So yes, my motivation is high. I'm working on this with Scott Coursey and he's working on tools and lighting. I'm working on the map format itself for brushes.
It's coming along quite nicely if not slowly. I'm very new to all this especially Torque and to be honest haven't done much other than run through some tutorials. I have map2dif compiled and running under OS/X from the April head.
I didn't want to write this plan until I had some more features working but I have unfortunately hit some road blocks. So I'm hoping someone who understands how interiors are handled can help with some questions. Being new to the product I'm sure the questions are such that an expert can handle these questions quickly enough. I could troll through the code or ask but I'm taking the easy way and asking, if no one responds I'll go through the code. It's been a long time since I've worked with C++ and 3D so that path may take awhile. :)
Here's what's working and I'll post some screen captures as soon as I figure out how to do that and embed them into this document. Currently, you can build structures with blocks, tubes and cones and export them to a .map file easily. You can even apply textures to each face. If you rotate a brush the texture will rotate as well so that it matches what you see in Blender. You can even rotate the texture in the UV editor and it shows up correctly in Torque. Again, once I figure out how to do screen captures this will be easier to describe.
There are two major areas that are breaking many other things. The simple problem is on the topic of scaling. Why is it that when 1 1 are used for scaling the texture doesn't fill the entire face? To get a texture to do this I have to figure out the hight and width of the face and divide that by the image size. The value of this calculation causes the texture to size correctly. Although in some instances this does not work so I'm sure this is an incorrect answer.
So here's question 1. How do you get the texture to map directly onto the face without repeating? I would expect 1 1 to do this but this isn't the case.
The second problem is offsets. For brushes that are centered around 0,0,0 in object space, not world space but object space, texture position, scaling (as described above) and rotation work perfectly. But once an object is moved the texture map is adjusted. I figured that the offset needs to be set to the upper left corner of the face but this only works for textures that are not rotated or scaled. Once you rotate or try to scale a texture for a brush who's not based around 0,0,0 things get messed up. In fact I even have an instance were the texture is rotated and I'm not adding any rotation to the texture, the texture vector is 0 0 1 0 and has a scale of 1 1.
When you offset the texture in the UV editor in Blender you get a normalized value from 0->1. My guess was to take the value and multiply it by the texture size and add that value to the offset for objects not based around 0,0,0.
So here's question 2. How do the texture offsets work?
My big issue seems to be with offsets. It seems that scaling is effected depending on where the object is placed in object space.
If this sounds like nonsensical dribble please let me know and I will try to describe this again. Only with pictures! If you have any information that can help or know of someone I can contact please let me know.
I figured out how to add screen captures
The first image shows how I'm able to add objects to the world and apply different textures to the objects. The big white object with numbers is centered around 0,0,0 in object space. Each face has a scale of 1 1, notice how the images are tiled and not scaled to fit to the face. Also notice how the smaller cube with the black and white checkerboard has a small area of black and white at the top. That means the texture isn't starting at the upper left corner of the face like the faces in the big block. See what I mean, depending on where the brushes are the offsets are messed up.
Also notice the small ramps that bridge the two blocks. Notice how the texture is rotated to look right on the brush. That is perfect.

The next image shows how my objects have the textures scaled to fit to the face. but once again the top of the checkered texture isn't right.

Rotating the texture intentionally in the Blender UV editor yields this image.
Notice once again the offset in the small block.

Finally, here is an odd one. Contrast this with the first image where the scaling is set to 1 1 and you can see four number 2's. Now I rotate it and you can see 9 number 2's which means the image is scaled as the object is rotated.

It seems that the textures are applied differently depending on where in object space each brush lies and scaled depending on the brushes rotation.
Any ideas? Thoughts? Comments? Please?
Submit your own resources!| wingman (Jun 14, 2004 at 19:23 GMT) |
| Joe Sulewski (Jun 14, 2004 at 19:36 GMT) |
Joe
| wingman (Jun 14, 2004 at 19:55 GMT) |
www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=5852
Edited on Jun 14, 2004 19:56 GMT
| Josh Williams (Jun 15, 2004 at 16:02 GMT) |
| Joe Sulewski (Jun 15, 2004 at 16:11 GMT) |
| Shadowdragon (Jun 19, 2004 at 01:31 GMT) |
| Rick Kelley (Jun 21, 2004 at 04:37 GMT) |
| Joe Sulewski (Jun 21, 2004 at 12:49 GMT) |
| Joe Sulewski (Jun 21, 2004 at 12:58 GMT) |
If your willing to help me test I will make sure to send you updates as soon as I think it's testable.
| EddieRay (Jun 25, 2004 at 20:03 GMT) Resource Rating: 4 |
Deep in the Interiors code, you can see where the MAP-style texture coordinates are converted back to UVs at render time. The equations it uses to compute the UVs are essentially:
U = Sx * x + Sy * y + Sz * z + Sw
V = Tx * x + Ty * y + Tz * z + Tw
where S and T are the MAP-style texture vectors (with x,y,z,w components), and x,y,z are the coordinates of each vertex in the triangle.
If you dig through the MAX2MAP code, there is a section that is devoted to solving the reverse problem - if I have UVs, what are the corresponding S-T vectors? Take a look at it. It essentially boils down to solving the above equations for S and T, and creating a system of equations that uses the 3 points of the triangle, the known UV values for each point, and a fourth equation that describes how the S and T vectors lie in the plane of the triangle (IIRC).
I've played with the code, and gotten pretty close to getting it to work, but it's not exactly correct. One problem is that it appears you must normalize the S and T vectors after performing the calculations. Even then, I still don't get the correct mappings, so I'm still missing something.
Another idea I've been thinking about is to make it possible in the Interior rendering code to use straight UV coords that are stored in the normal S and T vectors, but using some "hack" to let the Interior rendering code know whether we're actually specifiying UVs or just the normal S-T vectors (possibly, we could set Sw or Tw to something other than 0 - IIRC Sw and Tw are always 0). Of course, I'd only want to do it if it could be down without modifying the data structures. Also, it would be necessary to make sure MAP2DIF will work with UVs (i.e. pass them through unscathed).
One problem with using UVs instead of S-T vectors is that we'd need to specify all 3 UVs for each triangle - by cramming them into a single S-T pair, since there is only one S-T pair for each triangle, but there just happens to be 8 floats available, and we only need 6. ;-)
Anyway, you probably know some/all of this, but I hope this helps...
Ed
Edited on Nov 30, 2004 17:36 GMT
| Rick Kelley (Jul 04, 2004 at 03:11 GMT) |
| EddieRay (Jul 06, 2004 at 15:06 GMT) Resource Rating: 4 |
If you look in main.cc at line 437, you'll find the beginning of a "for" loop that goes through every triangle of a mesh and does the calculations I describe above to create a "surface" for an Interior, and as part of that process, computes the S and T vectors (which are referred to as "gens") for each triangle. At line 494, there are some initializations, and then the meat of the calculations are performed for a single triangle, down to line 533 where the new MAP-style surface is added to the "mix".
By the way, I'm referring to the 1.2.2 TGE source.
Hope this helps...
Edited on Jul 06, 2004 15:09 GMT
| Joe Sulewski (Jul 06, 2004 at 15:09 GMT) |
Thanks a lot for the tip, perhaps it will help me figure how to deal with the offsets.
Joe
| EddieRay (Jul 06, 2004 at 15:17 GMT) Resource Rating: 4 |
It really would be nice to have a way to store UV coords in the S-T vectors and have the Interiors renderer convert from S-T or just reassemble the UVs automatically on the fly... ;-)
| Joe Sulewski (Jul 06, 2004 at 23:43 GMT) |
Thanks for the reply and you confirmed my belief that I had to convert the coordinates from UV space to ST space. But I thought the conversion was a simple matter of finding the correct vertex for the face. As an example, if the user didn't want to shift the texture (0,0 for UV coordinates) then the ST coordinate is a simple matter of using the lower left vertex of the face. But obviously I think I'm wrong since it doesn't work. :) Can you shed any light on this?
Thanks again,
Joe
| Rick Kelley (Jul 07, 2004 at 01:39 GMT) |
Edited on Jul 07, 2004 01:41 GMT
| Joe Sulewski (Jul 07, 2004 at 02:50 GMT) |
Does that mean that in Milkshape you can't have faces that are quads? All faces must have three points? In Blender I have quads or triangles so this makes life easy.
Back to your issue, if the two triangles create one face that exists on the same plane then the UV coordinates should be the same. Can you get the points of your mesh with no rotation, translation or scaling applied to the points? If so, then calculate your UV coordinates from that data. Then any faces that exist on the same plane as others will have the same UV coordinates. Once we figure out offsets (uv to st conversion) the textures should line up. Unless of course the two triangles that are used to create a face both have uv coordinates of 0,0. But they shouldn't they should have different UV coordinates. Applying the offset to the UV -> ST conversion should make everything match.
Of course I could be insane.
Joe
| EddieRay (Jul 07, 2004 at 03:10 GMT) Resource Rating: 4 |
In your example, to get a solution which yields values of U=0 and V=0 at one of the vertices, there are an infinite number of choices for the S and T vector components that will satisy the equations. However, when you take into account all 3 sets of UV values (one for each vertex), you start to narrow down the number of possible solutions, but it's still infinite. The basic assuptions are that the UVs are distinct (no duplicate UVs) and the vertices don't overlap (no triangles that are really a line or a point). So one way to narrow it down to a single solution for the S and T components is to pick values for Sw and Tw - I think the MAX2MAP code chooses 0 for both. Then you have 3 equations and 3 unknowns - and it's a matter of some straightforward (but a bit complex) math to solve the 3 equations (the gaussjInverse function is used to solve this problem in the MAX2MAP code - there are probably better ways but it's been a long time since I did this kind of linear algebra "simultaneous equations" stuff... ;-)
The trivial solution of setting S to [0,0,0,U] and T to [0,0,0,V] to yield the U=V=0 case doesn't work in general because it yields the same UV coords for each vertex regardless of x,y,z. So, the rest of the components really to need to be worked out too to provide a solution for all the S and T vectors that work for all 3 vertices.
Let's say we have a triangle with vertices:
P0 = [0,0,0]
U0 = 0, V0 = 0
P1 = [1,0,0]
U1 = 1, V1 = 0
P2 = [1,1,0]
U2 = 1, V2 = 1
By inspection, we can choose S = [1,0,0,0] and T = [0,1,0,0] to satisfy the equations. Now, it's easy to look at those S and T vectors and think, well S is really just "the U direction vector" and T is really just "the V direction vector". For simple mappings, like a cubic projection type of mapping, that might work. When there is translation involved, we could just use the "w" component of S and T to set the offset we need in each direction. But, when there is rotation involved, it gets a bit trickier. Also, you might notice that I picked simple x,y,z values that work very simply in the equations, but normally the x,y,z values for the verticies will be widely varied, and will not necessarily form a "right triangle" (which happens to have sides that line up nicely with coordinate axes), so you end up having to compute S and T components that take the size of the texture, the number of repeats and the world x,y,z distance between vertices into account.
Without rotation, you might be able to use equations like:
Sx = (Umax - Umin) / (Xmax - Xmin)
Sy = 0
Sz = 0
Sw = -Xmin * (Umax - Umin) / (Xmax - Xmin)
Tx = 0
Ty = (Vmax - Vmin) / (Ymax - Ymin)
Tz = 0
Tw = -Ymin * (Vmax - Vmin) / (Ymax - Ymin)
... or similar (my brain might be on the fritz). But, these equations assume that the face is oriented in a general direction, i.e., in this case, the face's normal is in the z direction. I've seen sections of code in various programs where they try to figure out which direction the face is generally pointing (up, down, left, right, front, back) and then choose an appropriate set of equations similar to the ones above to compute S and T components. However, in general, these equations don't produce any arbitrary mapping... only a "cubic projection" type of mapping, kinda like 6 projectors from up/down/left/right/top/bottom all aiming towards the origin (but not exactly like that).
Well, I'm starting to get bleary-eyed and I'm probably confusing the issue more than helping, but I hope you can gather some kind of insight from this... ;-)
Ed
Edited on Jul 07, 2004 04:22 GMT
| EddieRay (Jul 07, 2004 at 03:15 GMT) Resource Rating: 4 |
The part to worry about is making sure you feed it a set of polys that *do* actually describe a set of convex solids... i.e., use convex solids in the modeller before trying to convert the geometry for .MAP format.
Edited on Jul 07, 2004 04:25 GMT
| Rick Kelley (Jul 07, 2004 at 15:29 GMT) |
As for not worry about the polygon soup aspect, I would like to forget about it, but as in the past, your going to have users of the product doing unusal things with the modeler, so I am attempting to put some kind of sense to account for the odd cases. I have thought of just using the Valve brute force method that I have shared with Joe, where they have a look up table to referenced from the normals and crossproducts to set the plane worked upon to 1 of six choices of tuplets, then take this and use some math on these standards to figure in the scale and perhaps added rotational values.
Joe: as for how milkshape works, it works at the triangle level. Its one of the reasons its great for low polygon modeling, as there is no suprises with polygon levels being high like that of MAX and other high end modelers. Beside all of this, most game engines expect to have the player types of models in a tris manner or triangular data.
If you havent figured this out already, I am very unfamilar with texture coordinate space math, and I am a modeler and an artist first :D But I am a determined cuss, and I take an old motto by an old teacher of the russian language I had: "If I find I dont like a language, or understand how it works that will give me all the more reason to learn it!" I like to apply this to things like math and coding :D
Thanks once again.
Edited on Jul 07, 2004 17:01 GMT
| Rick Kelley (Jul 07, 2004 at 22:58 GMT) |
Well here are the forwards formulas:
W = 1 / TextureWidth
H = 1 / TextureHeight
U = (Dot(Vertex, UAxis) * W * (1 / UScale)) + (UShift * W))
V = (Dot(Vertex, VAxis) * H * (1 / VScale)) + (VShift * H))
I honestly have no idea how you can reverse them and I'm not sure that you
even can. You'd have to fill in what you know then solve for the unknowns
for each vertex of each face and hope all the solutions from each vertex
match. If they don't, I doubt there is a solution for that face. (And to
be honest, knowing how MilkShape creates its UV coordinates, I'd be
surprised if there is a face solution most of the time. Averaging the
vertex solutions might make for a somewhat accurate face solution.)
I believe that they always used the same style of UV generation; they just
didn't use the U and V axis values (they were hard coded). The original
Quake MAP format was just offset, scale and rotation and Valve made the U
and V axis dynamic (due to orientation problems).
You might find this interesting:
typedef struct tagBSPTEXTUREINFO
{
FLOAT U[3];
FLOAT UOffset;
FLOAT V[3];
FLOAT VOffset;
INT MipTextureIndex;
INT Flags;
} BSPTEXTUREINFO, *LPBSPTEXTUREINFO;
That is a structure form the HL BSP format. Each face does not store its
texture coordinates, just the axes and offsets (the scale and rotation are
calculated into each axis). HL uses that information to calculate BSP UV
coordinates.
Ryan Gregg
Edited on Jul 07, 2004 22:59 GMT
| Joe Sulewski (Jul 08, 2004 at 02:22 GMT) |
I looked at that code in max2map finally. It's been over 10 years since I've done anything resembling the gaussian inverse. I remember talking about it in class and wondering if I'd ever use it. :) But I can follow the code so perhaps I will try to port it python and see how that goes. I can't find a good reference on the algorithm of converting UV to ST on the net. I thought it would be easy to find. Your example above is great but I need to consider rotation, scaling and translation.
Thanks again, that pointer should help a lot. Now I'm onto trying to understand how to solve the three simultaneous equations. I did keep my books from college. Once I figure that out, applying what you described should help me a lot.
Thanks again,
Joe
ps I just looked at my linear algebra book and it's coming back. I think I understand the steps in the max2map code. I don't understand why were performing the steps (that would require understanding the UV -> ST transformation), but I think I'm starting to have the haze lift.
Edited on Jul 08, 2004 02:44 GMT
| Joe Sulewski (Jul 08, 2004 at 02:47 GMT) |
Edited on Jul 08, 2004 02:47 GMT
| Rick Kelley (Jul 08, 2004 at 20:58 GMT) |
| Heath Rezabek (Nov 30, 2004 at 03:20 GMT) |
if the offset error is consistent, one thing to try might be to deliberately plan for the offset error in the conversion. in other words, if a texture scaled to 1 shows up in Torque with 10% of its surface clipped, then why not scale the textures in Blender to .9? in theory, when the conversion takes place, they will scale up to the proper size, even though that size is technically in error. does this make sense? i ask about this [i'm sure you've tried or considered it already] because it is used a bit where i'm from converting color maps from Myth II to Myth III, which uses a different scale. so long as one remembers to scale to the proper 'incorrect' size, the converted colormap comes out alright.
anyway, please do carry on; we're counting on you! ;) :)
- aqaraza
| Joe Sulewski (Nov 30, 2004 at 13:22 GMT) |
I have the exporter so that it exports just a texture and the objects. In regards to the accuracy of the mapping you can rotate the textures but you can't scale or shift them. I didn't read your paragraph closely but my long turn solution is to bring JQT up to spec. JQT is an old java based map editor. There are some things that it needs to be really useful but I think it will work better then blender.
| Rick Kelley (Nov 30, 2004 at 15:52 GMT) |
After all this rage and ranting :D where can you find this JQT you talk about Joe? It might inspire me to improve my plugin.
| Joe Sulewski (Nov 30, 2004 at 16:11 GMT) |
Yeah I hate IP cloaking. I understand if people want to keep it secret to make money I just wish they would tell me. Be honest, "I'd like to tell you but this is what's making me money so I'd rather not share it" is all they have to say.
In any case, here is the url. I have it compiled and running but it requires a wad file for textures and it's in AWT which is a terrible GUI.
Here is what I want to do.
1. Add a layer system. This would allow you to add parts to different layers that you can turn on and off to reduce the visual complexity of the scene. Allows you to work on interiors in small chunks.
2. Remove the requirement for WAD files. It would be better to just pick the texture from a GUI tree that displays the contents of a directory.
3. Make it support three panes rather than just one at a time. This way you can see top, bottom and side all at once.
In the long term I would like to make is use jogl for speed but that's down the road.
http://www.aegidian.org/gqt/jqt/
| EddieRay (Nov 30, 2004 at 16:21 GMT) Resource Rating: 4 |
| Heath Rezabek (Nov 30, 2004 at 16:21 GMT) |
| Joe Sulewski (Nov 30, 2004 at 16:27 GMT) |
I tried the code from the maxtomap exporter as you suggested. But it didn't seem to work. It could be that I'm really new to Python and I don't have great tools for debugging or that the code is wrong. I ran through the code I ported pretty well and I'm of the opinion it doesn't work. If someone can verify that the max2map code works then I will re open the approach.
Another problem to consider is that when creating maps you really want your brushes to align perfectly with no overlap. I found this difficult to do in blender even with snap to grid on. There are errors in the editor I believe that show overlap when it doesn't exist and so you end up breaking things because you think it's wrong. Another problem is that there doesn't seem to be an easy way to deal with lights and other entities as Scott Coursey found out. I guess we could right a map parser for the entities but that seems like too much work. I think it would be better to follow the jqt route.
Any opinions would be greatly appreciated. Now if only I knew how to get in touch with the author of JQT to make sure he doesn't mind.
Edited on Nov 30, 2004 16:28 GMT
| Heath Rezabek (Nov 30, 2004 at 21:44 GMT) |
you know, to play devil's advocate for Blender just one last time... the flexibility and openness of this app really does impress me, and i guess i sure wish there were a way to make it work. i presume you have tried discussing the issues yr having over on the open Blender forums? because they have a voracious and helpful user community, and it wld seem to be that many of them wld jump at the chance to help out in building just such a map editor with you, or answering yr questions. since many Mac users are going to be using Blender as their main 3d editor [i know i am; i sure can't afford Maya etc], it'd be an absolute coup to see a map editor truly integrated using it. it even occurs to me that some of the LogicBricks might be able to be ported as map objects with special properties [door triggers, etc]!
i wld at least try out your questions on the forum; you may be surprised...?
http://www.elysiun.com/forum/index.php
http://www.elysiun.com/forum/viewforum.php?f=5
^^^ the Blender & Python sub-forum...
now that i've made my pitch for not giving up on Blender, i'll step aside and wait; eventually at least i look fwd to using JQT someday, if not Blender. thanks for all you do! :)
- heath
| Heath Rezabek (Nov 30, 2004 at 21:56 GMT) |
| Joe Sulewski (Nov 30, 2004 at 21:59 GMT) |
Your right about Blender being a fantastic product. I really like it and it's my first choice. I've asked some questions on the forums and never got a response. It's easy to get responses to how to do things artistically or simple programming questions. But I can't find anyone able to tell me how to convert UV coordinates to ST coordinates. Perhaps it's not a programming thing, perhaps it's a matter of doing textures differently. The problem I'm running into is how to map textures not to the object coordinates but to the world coordinates.
Imagine plopping two floors down but with a gap between them. If you can tell me how to map the same texture on the floors in such a manner that the gap looks like a missing piece where if it were filled in the texture would be seamless then there is no issue with textures. Tell me how you do it and I'll figure out how to extract the info.
You can't use the logic bricks for some reason. Scott Coursey tried that path and ran into problems. He also posted to the forums about being able to apply attributes to objects without using the game portion and there was resistant response if I remember correctly. But I don't want to quote Scott so take what I say with a grain of salt.
In regards to JQT you don't need Classic mode. It's a java app it runs natively. It's an old web site so ignore the stuff about mrj.
Let me know if that paragraph about mapping makes sense to you I'm sure I'm explaining it terribly. I'm hungry and my family is waiting for me for dinner. :)
| Joe Sulewski (Nov 30, 2004 at 22:00 GMT) |
| Heath Rezabek (Dec 01, 2004 at 01:36 GMT) |
also, perhaps if it were turned into a Torque community barnraising, things might come of it too. you might scan through those users who were enthused in their responses to the exporter scripts being made;
http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=4662
and perhaps start a 'base of operations' thread on the Torque forums, to corral more hands and eyes. that'd save the load on your .plan page too... :)
i will ponder the textures. is there a way to get ahold of the Blender / Torque tool as it currently stands? glad you like my enthusiasm; sometimes it's almost all i have to offer... :( ;)
- heath
| Heath Rezabek (Dec 01, 2004 at 02:02 GMT) |
http://www.elysiun.com/forum/viewtopic.php?p=324731#324731
elYsiun.com Forum Index -> Blender Game Engine -> TORQUE!
- heath
| Joe Sulewski (Dec 01, 2004 at 02:11 GMT) |
| Richard (Dec 21, 2004 at 20:05 GMT) |
Now I'm enthusiastic once again ! Looking forward to this development !

| Marcel Vijfwinkel (Feb 05, 2005 at 20:03 GMT) |
//
// Calculate Texture vectors
// Thanks to DarthPingu on The Chaosengine!
//
// Express 3 positions as 2 vectors from the 1st point
vector $v1 = <<$XPosition[1], $YPosition[1], $ZPosition[1]>> - <<$XPosition[0], $YPosition[0], $ZPosition[0]>>;
vector $v2 = <<$XPosition[2], $YPosition[2], $ZPosition[2]>> - <<$XPosition[0], $YPosition[0], $ZPosition[0]>>;
// Express 3 texcoords as 2 vectors from the 1st texcoord
vector $tex1 = <<$UCoord[1], $VCoord[1], 0>> - <<$UCoord[0], $VCoord[0], 0>>;
vector $tex2 = <<$UCoord[2], $VCoord[2], 0>> - <<$UCoord[0], $VCoord[0], 0>>;
// Initialise tangent & bitangent vectors
vector $edge1 = <<0,0,0>>;
vector $edge2 = <<0,0,0>>;
vector $normal = <<0,0,0>>;
float $tx,$ty,$tz,$btx,$bty,$btz;
// Find the tangent & bitangent x components
$edge1 = << $v1.x, $tex1.x, $tex1.y >>;
$edge2 = << $v2.x, $tex2.x, $tex2.y >>;
$normal = cross($edge1, $edge2);
if(abs($normal.x) > 1e-7)
{
$tx = -$normal.y / $normal.x;
$btx = -$normal.z / $normal.x;
}
// Find the tangent & bitangent y components
$edge1 = << $v1.y, $tex1.x, $tex1.y >>;
$edge2 = << $v2.y, $tex2.x, $tex2.y >>;
$normal = cross($edge1, $edge2);
if(abs($normal.x) > 1e-7)
{
$ty = -$normal.y / $normal.x;
$bty = -$normal.z / $normal.x;
}
// Find the tangent & bitangent z components
$edge1 = << $v1.z, $tex1.x, $tex1.y >>;
$edge2 = << $v2.z, $tex2.x, $tex2.y >>;
$normal = cross($edge1, $edge2);
if(abs($normal.x) > 1e-7)
{
$tz = -$normal.y / $normal.x;
$btz = -$normal.z / $normal.x;
}
// Load results in vectors
vector $texturevectorU = <<$tx,$ty,$tz>>;
vector $texturevectorV = <<$btx,$bty,$btz>>;
//
// Scale
//
// Calculate the lengths of the texture vectors
float $ul = sqrt( dot($texturevectorU, $texturevectorU) );
float $vl = sqrt( dot($texturevectorV, $texturevectorV) );
// calculate scales (textureUSize and textureVSize are the size of the texture in pixels)
float $uscale = (($ul / $textureUSize) * $globalscalefactor );
float $vscale = (($vl / $textureVSize) * $globalscalefactor );
//
// Offset
//
// normalize texture vectors
$texturevectorU = `unit $texturevectorU`;
$texturevectorV = `unit $texturevectorV`;
// calculate the offset
float $offsetu = $UCoord[0] - (dot( $texturevectorU, <<$XPosition[0], $YPosition[0], $ZPosition[0]>>)/$ul);
float $offsetv = $VCoord[0] - (dot( $texturevectorV, <<$XPosition[0], $YPosition[0], $ZPosition[0]>>)/$vl);
$offsetu = $offsetu * $textureUSize;
$offsetv = $offsetv * $textureVSize;
// Wrap the texture offset
int $tt = ($offsetu / $textureUSize);
int $ss = ($offsetv / $textureVSize);
// substract the repeating part
$offsetu = $offsetu - ($tt * $textureUSize);
$offsetv = $offsetv - ($ss * $textureVSize);
//
// Rotation (Not sure if this is correct, it's just a UI thing in Hammer and has no influence on the texture placement)
//
// vector v1 is the vector of two points in the plane
// texturevectorU has the rotation applied
float $rotangleU = angle($v1, $texturevectorU);
float $rot = $rotangleU * (180 / 3.14159265);
Hope it helps!
Marcel Vijfwinkel
| Benoit Touchette (Feb 06, 2005 at 13:13 GMT) |
| Marcel Vijfwinkel (Feb 06, 2005 at 20:03 GMT) |
| Benoit Touchette (Feb 06, 2005 at 20:34 GMT) |
| Benoit Touchette (Feb 08, 2005 at 19:30 GMT) |
Edited on Feb 09, 2005 02:28 GMT
| Benoit Touchette (Feb 09, 2005 at 02:27 GMT) |
Edited on Feb 09, 2005 02:29 GMT
| Marcel Vijfwinkel (Feb 09, 2005 at 13:26 GMT) |
Did you check if the rotation value is correct? I'm still not sure about it...
| Benoit Touchette (Feb 10, 2005 at 00:34 GMT) |
Sure for the credits go where they are due.
As for the rotation not yet, since it has no inherent value for now. Once thing i did notice last night was those darn floating points, i need to see where i can clamp down on them a bit.
At any rate you can follow my progress at www.draekko.org
| Matthew Langley (Feb 11, 2005 at 22:04 GMT) |
| Rick Kelley (Feb 21, 2005 at 18:13 GMT) |
I succefully coded my old Generic MAP exporter for Milkshape 3D to work on rotations for the texture by carefully looking over the maya exporter code by Marcel Vijfwinkel and the use of the code of DarthPingu. Of course MEL script and the information of how Maya works had to be transelated, got me to rework my code that was mostly working, but not quite right from the Valve SDK and Zoners Half Life compile tools. It helped to fill in the gaps! I have some more testing on other shapes, but I think it will go well and soon be ready for release. Thanks bunches guys for posting your work!
Here is a screen shot with the top in Milkshape 3D and the bottom in the Hammer edition of the Valve bsp editor:
http://www.drawcad.com/3d/ms3dMAPtest.jpg
Edited on Feb 21, 2005 18:18 GMT
| Marcel Vijfwinkel (Feb 22, 2005 at 11:52 GMT) |
You can easily check if a face is planar mapped by calculating the angle between the two texture vectors, if they are not (within a small margin of ) 90 degrees then the mapping is non-planar.
| EddieRay (Feb 22, 2005 at 16:34 GMT) Resource Rating: 4 |
Edited on Feb 22, 2005 16:34 GMT
| EddieRay (Feb 22, 2005 at 16:37 GMT) Resource Rating: 4 |
| Benoit Touchette (Feb 22, 2005 at 21:06 GMT) |
| Rick Kelley (Feb 25, 2005 at 16:41 GMT) |
| Rick Kelley (Feb 25, 2005 at 16:53 GMT) |
http://www.drawcad.com/3d/non-ortho.jpg
Edited on Feb 25, 2005 17:08 GMT
| EddieRay (Feb 25, 2005 at 19:06 GMT) Resource Rating: 4 |
| EddieRay (Feb 25, 2005 at 19:11 GMT) Resource Rating: 4 |
| Joe Sulewski (Feb 25, 2005 at 19:18 GMT) |
This is a key thing for me to get working. Again, I apologize for not replying to any of this. I should be able to add more next week.
| Joe Sulewski (Feb 25, 2005 at 19:22 GMT) |
| EddieRay (Feb 25, 2005 at 20:04 GMT) Resource Rating: 4 |
| Rick Kelley (Feb 26, 2005 at 06:03 GMT) |
http://www.drawcad.com/3d/ms3d-map.jpg
I have even scaled other 256x256 image corectly on other objects, but whenever the shape is not
a rectangle in some form, then problems start happening.
| EddieRay (Feb 26, 2005 at 18:04 GMT) Resource Rating: 4 |
| Rick Kelley (Mar 09, 2005 at 16:43 GMT) |
My code that I reworked from zoners will determine the area the texture axis needs to point, but not how the axis should be rotated. The code provided from the Maya script, will determine how the axis should be rotated, and point if the brush is cubical. or form a rectangular shape with the texture applied being a stretched onto the rectangle. If you try to offset or scale this texture, (which by the way up until now I have used a 256 x 256 texture), or rotate it in the modeler known as MS3D, will screw the living heck out of it and will not work. This is apparent in my images that I have links for in this plan above.
So from the rantings above, the maya export code seems to get screwed because it is not correctly getting the texture axis direction, which could be because of common vector errors of not compensating for opposites. (Your going to have to pull out books on this one). This is why Half Life came up with the best_texture_axis bit of code:
static const vec3_t s_baseaxis[18] = {
{0, 0, 1}, {1, 0, 0}, {0, -1, 0}, // floor
{0, 0, -1}, {1, 0, 0}, {0, -1, 0}, // ceiling
{1, 0, 0}, {0, 1, 0}, {0, 0, -1}, // west wall
{-1, 0, 0}, {0, 1, 0}, {0, 0, -1}, // east wall
{0, 1, 0}, {1, 0, 0}, {0, 0, -1}, // south wall
{0, -1, 0}, {1, 0, 0}, {0, 0, -1}, // north wall
};
// =====================================================================================
// TextureAxisFromPlane
// =====================================================================================
void TextureAxisFromPlane(plane_t* pln, vec3_t xv, vec3_t yv)
{
int bestaxis;
vec_t dot, best;
int i;
best = 0;
bestaxis = 0;
for (i = 0; i < 6; i++)
{
dot = DotProduct(pln->normal, s_baseaxis[i * 3]);
if (dot > best)
{
best = dot;
bestaxis = i;
}
}
VectorCopy(s_baseaxis[bestaxis * 3 + 1], xv);
VectorCopy(s_baseaxis[bestaxis * 3 + 2], yv);
}
The problem here is to figure out how to use this information and to tweak it after it has figured out the actual direction and to futher massage it to apply correct normals for the tuplets that lie between -1 to +1.
This is where I am at right now/
| Joe Sulewski (Mar 09, 2005 at 18:19 GMT) |
http://www.garagegames.com/news/7317
Edited on Mar 09, 2005 18:20 GMT
| EddieRay (Apr 26, 2005 at 21:55 GMT) Resource Rating: 4 |
That said, Benoit... if you're still watching this thread, I'd be happy to test your Blender->.MAP exporter if you're still looking for testers. I'm a little off my game with Blender at the moment, but I'll struggle through. I'd also like to get familiar with how to right an exporter for Blender anyway...
| Richard (Apr 28, 2005 at 20:34 GMT) |
.. if you're still here-abouts, I agree with EddieRay; the thought of abandoning the project on the premise that another group is doing something similar .. well, it just doesn't sit right with me.
The aim from here should then include making a superior end product that is not only open-source, but will out-play, out perform ... Hey ( ! ) wait a min .. this sounds familiar :o)
..you get the drift.
| Joe Sulewski (Apr 28, 2005 at 20:51 GMT) |
I'm still here and I've been meaning to respond but I've been busy with work, sorry about that. Working on it right now is not a priority for me as I can use Radiant on the Mac (I'm not ready for commercial production yet so the license doesn't bother me). However, when I am ready to make something commercial then the need for a less restrictive map making tool will become important.
In regards to the exporter I came very close to getting it to work but the stupid offsets killed me. Then Benoit stepped in and tried going at it from a different direction and I think he ended at the same spot, not quite sure you'll have to ask him.
Anyway, I know nothing about Torque Constructor so it's too early for me to assume that it will be like Quark and the others. Hopefully it will have the ability to be extended through torque script. I would suggest finding out more about constructor before we rack our brains on a blender exporter.
What do you think?
Joe
| EddieRay (Apr 28, 2005 at 20:53 GMT) Resource Rating: 4 |
@Rick: I thought I had already commented on your code... but evidentally not. I've seen similar code before somewhere... maybe in the CShop .MAP exporter code.
The trick is to take the 3 component's that of the "best axes" and use that as the 3 components of S and T... pretty straightforward... except for what to set Sw and Tw to... I think they get set to either 1.0 or 0.0. You end up with a .MAP file that has lots of 1.0s and 0.0s in the S/T components. This has the effect of "projecting" the textures onto surfaces in one of the normal X/Y/Z axis directions.
But this avoids the whole converting-UVs-to-ST-vectors problem altogether, and a map-editor program will typically just work completely using ST style mapping, and convert to UVs only for it's display code.
Using the "best axis" method provides a pretty basic mapping capability. It doesn't suit complex mesh shapes very well though... for that, you need to compute ST vectors that aren't parallel to the world X/Y/Z axes, but are actually aligned to the face that's being mapped, or even rotated "out of the plane" of the face being mapped, to give stretched/squashed mappings. Then, there's nothing to say the S and T vectors need to be orthogonal (at 90 degrees to each other and in the same plane)...
Anyway... I'm out of time right now, but let's get this conversation fired up again... :-)
| EddieRay (Apr 28, 2005 at 21:17 GMT) Resource Rating: 4 |
Personally, I think the Blender .MAP exporter would be a great learning experience to continue on with. If for nothing else than to see a real effort fully documented with all our findings. If it were easy, there would already be scads of documentation out there on the texture mapping issues we've been discussing at length so far. There are really only two "big" issues AFAICT in making a decent .MAP exporter:
1) Either converting straight UVs to ST-style mapping using the exporter code, or making the editor (Blender) support ST-style mapping. It would at least be possible to just *define* what kinds of UV mappings are easily converted to ST mappings and then figure out ways to adhere to them while using Blender so that the export process will work as expected.
2) Convex geometry. Should an attempt be made to convert concave meshes into convex pieces automatically?
It'd be nice to be able to support entities for light placement, etc. And it'd be nice to have the exporter automatically run Map2Dif for you, gather up the output, and display it to the user, etc.
Ed
| Joe Sulewski (Apr 29, 2005 at 17:56 GMT) |
I responded to this yesterday, I wonder what happened to the post?
In regards to 1 Blender does, I believe, support ST mapping. You can setup textures to map to world coordinates. The bad part is that the settings are not available to Python. So close, yet so far. :(
In regards to number 2, slicing and dicing is tricky and may yield results the artist doesn't want. I would rather just highlight the offending objects.
Finally, it's possible that the new map2dif will work with UV's. That would make it easier as well.
Here is an interesting link. This guy is working on a blender import/exporter for quake bsp.
http://67.22.114.230:8082/programming/blender/
Edited on Apr 29, 2005 17:56 GMT
| EddieRay (Apr 29, 2005 at 18:59 GMT) Resource Rating: 4 |
Quote:
I responded to this yesterday, I wonder what happened to the post?
Yeah... sometimes I click "Post Comment" and my post just disappears into the bit bucket... not sure what's happening with that. It's frustrating for posts I spent an hour typing and thinking about. I've started copying to the clipboard before clicking that dreaded button... ;-)
Quote:
Blender does, I believe, support ST mapping.
Hmmmm... didn't know that. How do I access that feature?
Quote:
slicing and dicing is tricky and may yield results the artist doesn't want
I agree. But I do believe it's unnecessary to require only convex geometry. I think the best solution is to have the exporter automatically slice and dice things and report when it can't do it with existing vertices. For example, a box object that has a smaller box extruding out one face - the exporter can easily slice that geometry without causing any problems because the big face is planar with the vertices of the smaller face (and vice-versa). Little "allowances" like this can be a big win IMO...
Quote:
it's possible that the new map2dif will work with UV's
Really? I hadn't heard that. I *have* considered hacking the small portion of the Interior rendering code to allow UVs to be used, but I haven't actually tried to do it yet. I was thinking that the Sw or Tw value could be used as a flag to the rendering code to say "S and T are really a set of 3 UVs for the face - just use them instead of computing UVs". Might be interesting to try. I noticed from looking at the rendering code that the lightmaps generated by map2dif actually use UV coords (no ST stuff at all). It seems like the ST mapping is really just there for historical reasons... and since STs are easily converted to UVs, but not the other way around, the mapping tool should be where STs are used, and the rest of the pipeline should just use UVs...
Edited on Apr 29, 2005 19:00 GMT
| EddieRay (Apr 29, 2005 at 19:06 GMT) Resource Rating: 4 |
| Joe Sulewski (Apr 29, 2005 at 19:16 GMT) |
The feature for Mapping to world coordinates is in the "map to" button in the material editor. You don't use the UV stuff at all. You create a texture then assign it to each face and use the mapto buttons in the material editor. The texture editor (located as a tab in the material editor) has buttons for repeat and offset. It sucks because I can see the solution but it's out of reach. I feel like the town drunk in jail in a western movie. I can see the keys to the jail cell on the wall but I can't quite reach it.
You bring up a good point about the slicing and dicing. In fact it may fix a problem that blender can't easily fix. Aligning objects up so that they butt perfectly isn't easily accomplished. But then again, doesn't map2dif slice and dice?
I believe that the map2dif compiler converts the ST's to UV's and the system uses UV's from then on in. I think ST's are used to make it easier for mappers because you don't have to worry about making the floor/wall/ceiling textures seem together.
| Joe Sulewski (Apr 29, 2005 at 19:17 GMT) |
| Joe Sulewski (Apr 29, 2005 at 19:19 GMT) |
| EddieRay (Apr 29, 2005 at 19:40 GMT) Resource Rating: 4 |
STs in Blender: Okay... I'll have to try that. I'm a bit fuzzy on materials and texture mapping in Blender still... ;-) So you can't get at those ST variables with Python? Hmmmm... seems like it should just be one of the many material properties. I'll have to try it out to see how it works...
map2dif slicing for you: I don't think so... but I haven't tried it... hmmmm...
map2dif using UVs: From the Interior rendering code, it is converting the STs to UVs at the very last moment as it fills the vertex buffers before passing them to be rendered in OpenGL. I'm pretty sure the STs are all that is used (except for the lightmaps as I mentioned) in the code up to that point, and in map2dif.
floor/wall/ceiling mapping: Sure... that's handy. But it's not really necessary to use STs to do that sort of thing... and while it's good for floor/wall/ceiling mapping... it's pretty yucky for other things like cylinders or things that need to be "wrapped" with texture... ;-)
| Rick Kelley (May 05, 2005 at 20:06 GMT) |
| EddieRay (May 05, 2005 at 20:57 GMT) Resource Rating: 4 |
One problem withe "best axis" solution is that cylinders don't get mapped as you would like, i.e., with the texture-map "wrapped around" the round surface of the cylinder.
I guess I'm gonna have to come up with a test program to play with ST mapping and the conversion to UV mapping side by side... not sure when I'll get the time tho'.
| Joe Sulewski (May 05, 2005 at 21:02 GMT) |
What do you think? It's easier then the math. :)
| Rick Kelley (May 06, 2005 at 02:54 GMT) |
file format description, algorithms, and code." In the paper, he describes using the zoners half life code. But the paper goes on to describe the reverse of what we are trying to do., recreate the MAP file to polygon soup. If you want to look at this paper, I have it in PDF file format. Rodirego Hernandez seems to have grasped the contents to get it to working. He did post some code in the forum and said that it mostly work to figure out best axis and what follows is his original posting to the forum:
if((fabsf(Normal.x)>fabsf(Normal.y))&&
(fabsf(Normal.x)>fabsf(Normal.z)))
{
vUNormal.x=0;
vUNormal.y=1;
vUNormal.z=0;
vVNormal.x=0;
vVNormal.y=0;
vVNormal.z=-1;
}
else if((fabsf(Normal.y)>fabsf(Normal.x))&&
(fabsf(Normal.y)>fabsf(Normal.z)))
{
vUNormal.x=1;
vUNormal.y=0;
vUNormal.z=0;
vVNormal.x=0;
vVNormal.y=0;
vVNormal.z=-1;
}
else
{
vUNormal.x=1;
vUNormal.y=0;
vUNormal.z=0;
vVNormal.x=0;
vVNormal.y=-1;
vVNormal.z=0;
}
Where Normal is a Vector class (or struct) variable that contains the plane normal, vUNormal is the texture U normal and vVNormal is the V Normal.
Even though this is ok to get the initial (default) values I would still be interested on calculating the actual values given that I have a fully texture mapped cube, I am codding so the user gets to set the values by hand
/////////////////////////////////////////////////////////////////////////////////
After he posted the above code, someone replied to him about fixing it up more in this way:
Maybe this helps. You said they use 5
texture values. OK. You're fully right with the plane stuff. So
take a polygon. Let's say the polygon has four vertices. Now
it's your task to give each vertex a texture coordinate.
In ideal case this would be:
v1(0|0) ^ v2(1|0) ^ v3(1|1) ^ v4(0|1)
These are the texture coordinates for your
polygon. So, now you could rotate them
around you polygon middle. Or you could
scale them in a direction of your choice.
| Benoit Touchette (May 06, 2005 at 13:02 GMT) |
| EddieRay (May 06, 2005 at 15:46 GMT) Resource Rating: 4 |
| EddieRay (May 06, 2005 at 16:22 GMT) Resource Rating: 4 |
Ideally, I think the solution is to figure out how to compute the S and T vectors to best simulate the UV mapping. AFAICT, it a matter of solving the following two equations correctly for Sx,y,z,w and Tx,y,z,w:
U = Sx * x + Sy * y + Sz * z + Sw
V = Tx * x + Ty * y + Tz * z + Tw
So that's 6 equations right there, since we have 3 vertices that all use the same S and T vectors:
U1 = Sx * x1 + Sy * y1 + Sz * z1 + Sw
V1 = Tx * x1 + Ty * y1 + Tz * z1 + Tw
U1 = Sx * x2 + ...
V2 = Tx * x2 + ...
U3 = Sx * x3 + ...
V3 = Tx * x3 + ...
... we need 2 more equations. In max2map, the code around line 513 in main.cc appears (although I'm not completely sure) to compute the face normal (based on the vertex locations) and incorporate it into the matrix that will be inverted to find the solution. That's the "fuzzy" part to figure out... which I still haven't done yet. ;-)
| Rick Kelley (May 06, 2005 at 20:28 GMT) |
msVertex_GetTexCoords (pVertex, uv);
so for what its worth, I dont have to compute the S and T. My problem lies with the correct computation of the
tuplet pairs in the range of -1 to +1 which looks a lot like a normal vector + some scaling information. This is where Joe has had his problems as well.
| EddieRay (May 06, 2005 at 20:47 GMT) Resource Rating: 4 |
Eventually, if you want to make a .MAP file, you have to compute the S and T vectors (the "texture coordinates" or "texgens" that are needed with every "brush" you put in the .MAP file to describe the texture-mapping for each face). Either the map-editor/modeller supports texture-mapping via S-T vectors, or via UV mapping. If it uses UV mapping, you have to use some method to convert the UV coords for a face into S and T vectors for the face, because when your object gets rendered in TGE, the above two equations are used to map convert S and T vectors back into UV coordinates. It seems kinda silly to have to use S and T at all, if you really just need UVs for rendering the final results, but that's the whole issue... the mapping tools use S and T vectors and the MAP format only supports S and T vectors.
| Tom (Sep 12, 2005 at 20:32 GMT) |
i was just wondering if it would be possible for me to get that blender to map exporter script.
i enjoy blender (and already use it for the dts and dqs files) and it would be great if i could also use it to create the ,map and .dif files for torque.
| Markus Karlsson (Jan 10, 2006 at 12:23 GMT) |
You must be a member and be logged in to either append comments or rate this resource.


3.5 out of 5


