Topic: Blender to .mod scripts are there any working?  (Read 32581 times)

0 Members and 1 Guest are viewing this topic.

Offline Tus-XC

  • Capt
  • XenoCorp® Member
  • Commander
  • *
  • Posts: 2782
  • Gender: Male
Re: Blender to .mod scripts are there any working?
« Reply #80 on: March 14, 2010, 01:48:12 pm »
actually bonk, thats just a limit on the UI i think.   to prove this just add cubes to your scene and for each one link a material to it. by doing so, it appears it applies a unique material name to each one (material.024 for example).

Of course i could be completely off, but i think this is right.
Rob

"Elige Sortem Tuam"

Offline Tus-XC

  • Capt
  • XenoCorp® Member
  • Commander
  • *
  • Posts: 2782
  • Gender: Male
Re: Blender to .mod scripts are there any working?
« Reply #81 on: March 14, 2010, 01:51:24 pm »
btw, your screenie shows 18 mats in scene
Rob

"Elige Sortem Tuam"

Offline FoaS_XC

  • Photorps, Sammiches, woot woot.
  • Global Moderator
  • Commander
  • *
  • Posts: 4571
  • Gender: Male
    • Robinomicon
Re: Blender to .mod scripts are there any working?
« Reply #82 on: March 14, 2010, 02:49:57 pm »
as i understand it its not a matter of limiting how many materials you can have in scene, but rather how many materials a single object can have.
Robinomicon
"When I was 5 years old, my mom always told me that happiness was the key to life. When I went to school, they asked me what I wanted to be when I grew up. I wrote down “happy.” They told me I didn’t understand the assignment and I told them they didn’t understand life."

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #83 on: March 14, 2010, 02:56:30 pm »
yes its mats per obj.

Lol, I'm watching blender tutorials on youtube - being schooled by kids! They all sound like 12 man!  :-[

I'm working on a test model, I've got 24 textures on it, and no materials. Now I'm going to add on materials in various ways and see what I get.

I'm a little confused between uv wrapped images and material texture images at this point. Which renders when? Do UV wrapped images render at all?  :huh:

I have a little ways to go to contribute productively here I guess.

edit: this guy is not a kid and has some good tuts: http://www.youtube.com/user/irakrakow#p/u

http://en.wikibooks.org/wiki/Blender_3D:_Noob_to_Pro
« Last Edit: March 14, 2010, 03:27:13 pm by Bonk »

Offline marstone

  • Because I can
  • Commander
  • *
  • Posts: 3014
  • Gender: Male
  • G.E.C.K. - The best kit to have
    • Ramblings on the Q3, blog
Re: Blender to .mod scripts are there any working?
« Reply #84 on: March 14, 2010, 03:16:54 pm »
now you got me confused, I thought in order to put a texture on an object you had to have the texture on a material.  How are you putting textures on but no materials?

This is where not being a graphics guy, and having just alittle knowledge seems to hurt.
The smell of printer ink in the morning,
Tis the smell of programming.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #85 on: March 14, 2010, 03:19:44 pm »
Opps, Sorry! Hopefully one of the modellers will set us straight, if not, I'll let you know what I make of it all once I work my way through this Ira fellow's tutorials.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #86 on: March 14, 2010, 03:55:43 pm »
Ya, it seems to get it to render the textures I've assigned to each face I need to add a material and set some properties.

This video was instructive (though i've not really implemented it yet):


So this is a single material with 24 textures (attached). I shall try assigning a material to each face now.

All of this is a very inefficient way to texture a cube of course, but it is a learning tool for me.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #87 on: March 14, 2010, 04:29:51 pm »
16 traditional materials assigned manually to 16 faces, the remaining 8 faces default to the first material index.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #88 on: March 14, 2010, 05:07:34 pm »
Ah, Blender 2.5 Alpha 2 does not seem to have exactly the same limitation, it seems to be much easier to add and assign multiple materials beyond 16 without using nodes. One assigned to each face in this case. (four faces per side of cube for a total of 24)

Textures not assigned to materials but uv wrapped 1:1 on each face.... There will be several ways to do this.

Edit: I'm getting handier with blender 2.5. I like the changes. Time to move to a ship model soon.
« Last Edit: March 14, 2010, 07:59:48 pm by Bonk »

Offline Tus-XC

  • Capt
  • XenoCorp® Member
  • Commander
  • *
  • Posts: 2782
  • Gender: Male
Re: Blender to .mod scripts are there any working?
« Reply #89 on: March 15, 2010, 01:08:05 am »
basically the material controlls what properties are applied to mesh, whether that be mutliple textures with different ids, or effects and blending.  For me, it is easier to assign each material a set of textures (aka diffuse, light, spec maps) for one particular area - i find it less confusing.  However it is possible to use one mat, and then add multple textures to it each with a different id and then 'assign' them to certain parts of a mesh via selection.  This has the advantage of having one mat to deal with for say one part of a scene versus haveing 24 for just one model.
Rob

"Elige Sortem Tuam"

Offline Kreeargh

  • Retired.
  • Lt. Commander
  • *
  • Posts: 1476
  • Gender: Male
  • Life is as is worth only what you learn from it!
Re: Blender to .mod scripts are there any working?
« Reply #90 on: March 15, 2010, 11:11:59 pm »
The road to hell... when will I ever learn.  :(

* Bonk shakes head

Reading up on mats in blender there now marstone.

You did me some good , got me thinking how stupid i can be  :thumbsup:  Take a hammer to the vista machine and revert back to what i know somewhat. Hell i dont even know how to shut off antivurus in vista crap.
Time for life!

Offline Rod ONeal

  • D.Net Beta Tester
  • Commander
  • *
  • Posts: 3592
  • Gender: Male
Re: Blender to .mod scripts are there any working?
« Reply #91 on: March 16, 2010, 02:08:26 am »
If they didn't refuse to keep Dx up to date in XP nobody would change over. LOL
If Romulans aren't cowards, then why do they taste like chicken?

Offline marstone

  • Because I can
  • Commander
  • *
  • Posts: 3014
  • Gender: Male
  • G.E.C.K. - The best kit to have
    • Ramblings on the Q3, blog
Re: Blender to .mod scripts are there any working?
« Reply #92 on: March 17, 2010, 01:55:37 am »
 :crazy2: was starting to work through some tutorials to learn alittle more about blender, was working on the textures (of course), and for some reason my version doesn't seem to have the UV stuff shown in the video. 

So, going to ask if someone (FoaS) could put up a link to a image (cube or whatever) that has one texture on it.  Maybe saved in .mod .3ds  so I can compare them.  Thanks in advance.
maybe one that also has a illum map on it also.

Figure after i can get it to show at least one texture, then I will worry about getting the loads of them ready (however they need to be done so I can show as many textures as are on a model)

I know this is going to end up being easy peasy but at the moment i can't wrap my brain around how to load it.
The smell of printer ink in the morning,
Tis the smell of programming.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #93 on: March 17, 2010, 05:32:40 am »
If you've got blender you've got the UV editing stuff. One of blender's main strong points. Split the window by right clicking at near the lower margin and then set the right window the UV/image editor view by clicking the icon at the lower left corner of the window. I'll post screenshots when I get home (for 2.49 right?)

Offline marstone

  • Because I can
  • Commander
  • *
  • Posts: 3014
  • Gender: Male
  • G.E.C.K. - The best kit to have
    • Ramblings on the Q3, blog
Re: Blender to .mod scripts are there any working?
« Reply #94 on: March 17, 2010, 06:43:35 am »
I got that far, but then the video was showing to change my object mode to a UV something, and that isn't in the list that comes up when I click on the menu.  going to run through more of the training videos now that I am back home and have my two screens to work with (one for the training video, the other for Blender).  I love dual monitors.
The smell of printer ink in the morning,
Tis the smell of programming.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #95 on: March 17, 2010, 03:25:28 pm »
I believe what you want is "edit mode" instead of "object mode" this will change the menus. Once in edit mode Press "a" a few times to select the whole mesh, then on the "mesh" menu select "UV unwrap" (maps whole mesh to single texture). One could also select parts of the mesh and UV unwrap them separately to put particular textures on particular faces or regions. At least I think that is how it works.

Anybody know what UV stands for in this context? Would be nice to know...

Ah, U and V are arbitrary labels for the ordinate and abscissa of the 2D mapping of the 3D surface.

http://en.wikipedia.org/wiki/UV_mapping

Projections... takes me back to grade school!
« Last Edit: March 17, 2010, 03:58:51 pm by Bonk »

Offline FoaS_XC

  • Photorps, Sammiches, woot woot.
  • Global Moderator
  • Commander
  • *
  • Posts: 4571
  • Gender: Male
    • Robinomicon
Re: Blender to .mod scripts are there any working?
« Reply #96 on: March 17, 2010, 09:16:01 pm »
Actually the full term is UVW, because the texture coordinates can exist in three dimensions, even if most systems only use two of them. 3D textures use all three, but those are in-program things usually, not anything that a game engine can use as of yet.
Robinomicon
"When I was 5 years old, my mom always told me that happiness was the key to life. When I went to school, they asked me what I wanted to be when I grew up. I wrote down “happy.” They told me I didn’t understand the assignment and I told them they didn’t understand life."

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #97 on: November 06, 2010, 04:47:25 pm »
I'm going to take another stab at this right now. Downloading blender 2.5. The motivation is to get the dang mod format worked out in me head and then move on to rendering it on the canvas or writing conversion/display/manipulation scripts in python/php/js.

Step one (I think - will be the import script... though it may be easier to do the export first...)

edit: ... wow... 2.5 is different...

some good blender docs here: http://en.wikibooks.org/wiki/Blender_3D:_Noob_to_Pro

OK... I'm past "hello world" and object browsing in blender 2.5 again, now to prompt for a filename, load .mod binary data and sort it out. Easy right?  ;D

making progress, basing it on the 2.5 LWO import script. have the filename aand import menu hooks all set, now to chunking up the binary data and see if I can get it into blender objects.
« Last Edit: November 06, 2010, 05:59:16 pm by Bonk »

Offline marstone

  • Because I can
  • Commander
  • *
  • Posts: 3014
  • Gender: Male
  • G.E.C.K. - The best kit to have
    • Ramblings on the Q3, blog
Re: Blender to .mod scripts are there any working?
« Reply #98 on: November 06, 2010, 05:55:50 pm »
Import is easier then export. Is there a copy of the script I was working on in this thread?   When I get back from hunting I'll upload the file (if I can find it) for you to play with.  The .mod is not very complicated.
The smell of printer ink in the morning,
Tis the smell of programming.

Offline Bonk

  • Commodore
  • *
  • Posts: 13298
  • You don't have to live like a refugee.
Re: Blender to .mod scripts are there any working?
« Reply #99 on: November 06, 2010, 06:00:26 pm »
I figured, so working on import. Ya, the format looks pretty simple. How far along were you? (dont wanna re-invent here...)