exporter .IGM material xml format

General News and accouncements regarding the Indigo render engine
User avatar
suvakas
3rd Place Winner
Posts: 2613
Joined: Mon Sep 04, 2006 11:08 pm
Location: Estonia
Contact:

Post by suvakas » Wed May 09, 2007 9:26 am

Well..I'm actually letting user to pick what UV set to export. (check out the screenshot)
There are 3 possible options: none, obj, and 3ds.
(none = -none-, obj = default and 3ds = albedo).

Here's the way i see it.
If users don't do their xml/igs editing manually and are using exporters, then uv_set can have whatever name... even "blah blah".
The material should get imported into host program (in case of maxigo it gets imported directly into Material Editor) and well.. no need for uv_set in material editor. Uv_set is used only while exporting the scene. Actually Maxigo totally ignores the <uv_set> tags while importing. Uv_set is for linking material to a model.
Anyway..correct me if i'm wrong.
zuegs wrote: [edit] Btw can maxigo handle multiple UV sets?
Yes, it should. I think there were 3 possible UV channels when exporting a mesh into XML format. Don't remember exactly. I wrote that part a long time ago.
Attachments
uv_set.jpg
uv_set.jpg (14.51 KiB) Viewed 5599 times

Wedge
Posts: 441
Joined: Sun Jan 14, 2007 11:33 am
Location: East Coast, USA

Post by Wedge » Wed May 09, 2007 11:12 am

Kram: I had another look and I cannot see how to read these materials from code. I tried doing something like in your screenshot and when I mix red and blue, purple is the result and the monkey preview turns purple. But no matter what I click on the "output" seems to only exist in the node window and it does not actually exist as a material or turn my material color sliders to purple they stay as red which was one of the mixed colors.

So I am thinking it cannot be done, but then again maybe it is hiding from me in the documentation or something.

Zuegs: In some Indigo test scenes, (not sure if they are newer or older) "albedo" and "bump" is used. I see I have not changed any of it in Blender and it reads "uv."

Is there any reason to change it? For multiple UV support or something?
Content contained in my posts is for informational purposes only and is used at your own risk.

zuegs
Posts: 380
Joined: Tue Jun 27, 2006 5:46 pm
Location: switzerland

Post by zuegs » Wed May 09, 2007 5:55 pm

@suvakas:
ok, if maxigo ignores the uv_set while import, i can write in what ever i want :roll: . So we can let this undefined and every exporter/importer has to reset/repair the uv_set himself.
@wedge:
It seems that the python interface of blender only provides on UV-set. In Blender itself you can create more than one UV set, but python only offers one IMO :? :cry: . So in this case it seems that we need to overwrite/ignore imported uv_set name from "igm".

Wedge
Posts: 441
Joined: Sun Jan 14, 2007 11:33 am
Location: East Coast, USA

Post by Wedge » Wed May 09, 2007 6:09 pm

I'll take a guess and say that there will be quite a few issues from igm materials that were saved from different 3d apps.

For a couple of reasons, one being that not all exporters support all of Indigo features. (well at least the one I update doesn't) And another being that 3d apps handle certain things differently which means the exporter handles them differently in order to get them out. (which means the exporter will handle them differently to load them in)

I think it is too early to do this kind of feature but I will write what I can. :)

I have the medium stuff done I'll put up a snapshot soon and see how it works.
Content contained in my posts is for informational purposes only and is used at your own risk.

zuegs
Posts: 380
Joined: Tue Jun 27, 2006 5:46 pm
Location: switzerland

Post by zuegs » Wed May 09, 2007 7:29 pm

yup, will have a serie of console messages while import telling "feature XY not supported" :wink: :lol:
I quite finished my XML parser that i will also use internaly for storing materials inside the blender scene file. So my material GUI will have to work directly with a "igm" like XML structure :roll: . This will be much work to reprogram GUI :( . But then it will be much easier to add new material features in the future :D

User avatar
suvakas
3rd Place Winner
Posts: 2613
Joined: Mon Sep 04, 2006 11:08 pm
Location: Estonia
Contact:

Post by suvakas » Wed May 09, 2007 8:34 pm

Can someone explain me why do you need an UV_set when importing igm material to Blender?

zuegs
Posts: 380
Joined: Tue Jun 27, 2006 5:46 pm
Location: switzerland

Post by zuegs » Wed May 09, 2007 9:34 pm

no we don't need "uv_set" for import as maxigo also ignores it. So i will do the same for blendigo. Every importer should care himself to map UV maps after import. For me this is a good way do go if everyone is OK :wink:
The other question was if it's possible to handle multiple uv-sets in blender, because it seems that blender supports this, but the python script api do not :cry: . So this is perhaps something for future only then :roll: .
Thx to everybody :D

zuegs
Posts: 380
Joined: Tue Jun 27, 2006 5:46 pm
Location: switzerland

Post by zuegs » Wed May 09, 2007 9:38 pm

@sovakas: small other questions? when exporting materials with textures, do you copy all texture files to the same directory as the igm file or do you directly create a zip file with all inside ???

User avatar
suvakas
3rd Place Winner
Posts: 2613
Joined: Mon Sep 04, 2006 11:08 pm
Location: Estonia
Contact:

Post by suvakas » Wed May 09, 2007 9:44 pm

I just copy them to directory. I'm not even sure if i can create a zip file using script in max.
The example zip was done manually after exporting.

User avatar
Whaat
Developer
Posts: 1827
Joined: Fri Dec 22, 2006 6:15 am
Location: Canada
Contact:

Post by Whaat » Mon Jun 11, 2007 4:26 pm

suvakas:

Well, I got around to implementing nested blends import and export. Now that I can import and export your crazy materials, I thought I'd add my own touch by changing the yellow material to a bump mapped nkdata material and adding a clip map that uses the same checkered texture but a different UV set. I also changed the red glass material to be the striped glass material that you posted.
http://www2.indigorenderer.com/joomla/f ... 3770#23770
Then, I tried blending this material with a blended textured diffuse transmitter material. I don't think Indigo liked that very much because the screen turned black after a few seconds.... :( :D
Now let's see some more crazy IGM files!!!!

Whaat

User avatar
suvakas
3rd Place Winner
Posts: 2613
Joined: Mon Sep 04, 2006 11:08 pm
Location: Estonia
Contact:

Post by suvakas » Mon Jun 11, 2007 11:04 pm

Cool ! 8)
Finally i can make some tests using igm from another app.
Maxigo doesn't import different UV sets at the moment (an easy thing to add though).

[edit]
Ok. Maxigo gives an error when importing your igm.
It can't find Ag.nk from the Crazy Blend directory. I think we discussed it at some point. For me it seems logical to also include nk files the same way as textures. That way everything needed is there. Maybe i've changed my nk's in Indigo folder? Maybe i have deleted or moved the NK folder completely? Maybe i have made a new nk file that nobody has in their Indigo/nkdata folder? (there was some kind of nk customisation tool available)

What do you think?

[edit2]
Also.. It's quite hard to test the material with multiple uv channels cause i don't have the model with the same uv coorinates as you had. Can you do one igm without the multiple uv's? Thanks.

Otherwise great stuff!! I can't wait until the igm will be more popular.

User avatar
Whaat
Developer
Posts: 1827
Joined: Fri Dec 22, 2006 6:15 am
Location: Canada
Contact:

Post by Whaat » Tue Jun 12, 2007 6:33 am

suvakas wrote: For me it seems logical to also include nk files the same way as textures. That way everything needed is there.
What do you think?
I see your point. Right now, SkIndigo only supports the more common nkdata materials. There is no option to load a specific nkdata file. I suppose it wouldn't be hard to add this.
Exporting the nkdata file along with the textures should be easy but I might not get to it for awhile. In the meantime, I will post some materials that don't use nkdata.

Whaat

Post Reply
42 posts

Who is online

Users browsing this forum: No registered users and 24 guests