Jump to content
Sign in to follow this  
Swobbly Minogue

Importing textures in the .dae

You are about to reply to a thread that has been inactive for 3111 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hi, I have been trying to import a basic textured mesh cube. Im using Max 2010 with the 2011.3 FBX plugin as recommend on the wiki for my version of Max. I'll take you through my process in case I am missing something obvious

So I have created a multi/sub-object material containing 6 materials, one for each side of the cube. I've UV maped the cube using the basic box mapping and can see that each faced has been assigned an ID number and that ID number corosponds to the ID in the Material editor. This is all fine.

So I go to export the model to a .dae file. i don't change anything in the FBX export window, I can;t see anything there relating to materials or textures anyway.  Just click OK. 

So into the SL viewer, I import the model, ticking the checkbox for textures in the import window. No textures arrive. The mesh is fine. I can select all 6 individual faces. So no big deal I thought, I can just export my multi/sub-object texture from max and manually texture the mesh in SL.

This is where I got stuck completely I cant work out how to get the texture out off Max and into SL. I've tried Rendering/Render to texture but cant seem to get the texture to render without lighting effects, despite the fact there are no lights. 

i could UVW unwrap the cube and Render a UVW Template load it into photo shop and put the texture together but that seems like a lot of work for something that should be simple. 

So can anyone tell me how to upload the textures directly with .dae

Failing that can anyone tell me how to export my multi/sub-object material into a single texture so I can manually apply it to the cube.

 

Sorry for the lengthy post, just thought it best to cover what I have done in case I am missing something obvious.

Thanks!

Share this post


Link to post
Share on other sites


Swobbly Minogue wrote:

 

So can anyone tell me how to upload the textures directly with .dae

With the exporter you are using you can't. I dont know of any exporter for 3ds max that does.


Failing that can anyone tell me how to export my multi/sub-object material into a single texture so I can manually apply it to the cube.

The whole idea of a multi/sub is that it has multiple materials, not a single one. you should be able to turn the multi/sub into one material, but that's not what you are asking. A multi/sub has different UV maps, you can merge those into one. Maybe you can clarify a bit.

You can get rid of the lighting and other effects by only including "diffuse" when you render to texture.

To bake all 6 materials into 1, make two UVs, one for the source, containing the seperate materials, one for the destination, which will be one texture. You can select the channel when rendering to texture.

Share this post


Link to post
Share on other sites

Thanks for answering, it's appreciated. I'll try and clarify but I think it's my lack of understanding that is the problem despite reading/watching numerous tutorials.

I assume a Multi/sub-object material is basically a way to combine multiple tetures into one texture. I know you can select polygons, apply a material modifier and assign a sub-material to that selection, then UV map that selection. Once that has been done for every sub material, This is where i get stuck. I assumed I could just merge the sub materials into one texture that I could export. Then just apply that texture to the mesh that had previously been UV maped in max. I assume I can just drag and drop that finished merged texture onto each face of the mesh in SL. I've not got that far yet so this is all theory on my part.

Re. using Rendert to texture, I did only select "diffuse" as I assumed that would just render the BITMAPS without any other effects. I will go back and play around again with the Render to texture options


Kwakkelde Kwak wrote:

To bake all 6 materials into 1, make two UVs, one for the source, containing the seperate materials, one for the destination, which will be one texture. You can select the channel when rendering to texture.

This just went over my head i'm afraid.. What is the source? there are multiple sources arn't there in a multi sub material. Also what is the channel, i've not encountered that. thanks

Share this post


Link to post
Share on other sites

A multi/sub is simply a collection or group of materials.

I still don't understand what you are after:)

Do you want one texture to texture your entire box, or do you want six different textures on your box, so you can seperately edit them in SL?

Share this post


Link to post
Share on other sites


Kwakkelde Kwak wrote:

A multi/sub is simply a collection or group of materials.

Yep. I assumed you use multi/sub to bring together a selection of materials so they can be merged together into one materail. Otherwise what is the point of it. You may as well just use seperate materials and avoid sub object all together. See what I mean? lack of understanding :matte-motes-big-grin-squint:


Kwakkelde Kwak wrote:

I still don't understand what you are after:)

For the purposes of this test I wanted to make a cube that had selectable faces in SL. I then wanted to create a texture using multi/sub that combined 6 different textures, 1 for each face of the cube. But I wanted to merge the six textures into one, export the texture to SL then drop it on each face of the cube. I was hopeing each part of the texture would appear onthe correct face of the cube, seeing as I had UV mapped it in max. Failed lol


Kwakkelde Kwak wrote:

Do you want one texture to texture your entire box, or do you want six different textures on your box, so you can seperately edit them in SL?

I want 1 texture for the whole box. But I then want to be able to select the faces in SL and edit colour, shine etc.

Just a little test I set myself.

 

 

Share this post


Link to post
Share on other sites


Swobbly Minogue wrote:

 

i could UVW unwrap the cube and Render a UVW Template load it into photo shop and put the texture together but that seems like a lot of work for something that should be simple. 


That is how I do it. Then upload the texture separate.

Applying textures to a not unwrapped UVW has never worked for me in SL. You just get some sort of blurry color....

Share this post


Link to post
Share on other sites

Ok, here is what you can do.

Make sure all materials are set to 100 illuminated (self illumination)

texture your box with a multi/sub with the 6 textures

apply a UVW unwrap modifier

select edit in the parameters rollout

make the selection mode in that new window "face sub-object mode" and select all faces

click mapping on top of the window and select unfold

close the window again

hit 0 to bake the texture (render to texture)

click "add" and select diffuse

hit render

now make a new multi/submaterial, again 6 materials (all duplicates with the baked texture) and apply it to your box

now export the box as dae

in SL upload both the dae and the one baked texture

that should be it...

The UV map is not at all optimised...so you should do the mapping differently, but these are the basics. Maybe there's an easier way.... My brain is a bit fried atm:) time for bed

edit... personally I'd do it completely different. I would use 6 seperate materials for the different faces. (6 unique textures in SL) A box doesn't UV map very well with 6 sides so you will either have distortion or unused texture space.

Share this post


Link to post
Share on other sites


Kwakkelde Kwak wrote:

With the exporter you are using you can't. I dont know of any exporter for 3ds max that does.

I have the same issue. Assumed I had the wrong version of the plugin or something. Is there any workaround for this? Such as exporting to another program and importing the DAE from there with textures included?

 

Share this post


Link to post
Share on other sites

I assume exporting to blender would work as 3ds or maybe fbx (not sure what kind of files blender supports), then exporting from there again as dae, but that sounds more timeconsuming than simply uploading the textures seperately.

Share this post


Link to post
Share on other sites

i kinda have the same problem but im using blender, on my desktop i edited a model and decided to try to export the textures with the dae file and it works fine no problem, however i left home for a little while and took my laptop with me with the same version of blender and everything but for some reason the textures will not export and when i go to upload the model and check the box for textures in the upload window to see if they work they dont show up, i cant figure out what the difference between the two are, is there anything i can try to get it working on my laptop?

Share this post


Link to post
Share on other sites

Could be besause the exported collada file is using absolute paths for the locations of the image files. In Blender 2.49b, there is a toggle in the exporter to choose between absolute and relative paths. Of course, you still have to have the texture in the same relative location to your dae file for that to work.

There is also a toggle to choose between using images attached through the materials mechanism or images just opened in the UV editor. That might cause confusion too.

Share this post


Link to post
Share on other sites

Not sure about the "001". Blender uses a lot of numbers like that to resolve ambiguous names. What you need to look for is the <library_images> section, something like this ....

    <library_images>
        <image id="TESTGRID_TGA-img" name="TESTGRID_TGA-img">
            <init_from>..\gallery\baked\testgrid.tga</init_from>
        </image>
    </library_images>

The "<init_from>.....</init_from>" is where the image url goes. The one here is a relative path. The ".." menas the parent of the folder where the  dae file is.  If it's a full path, it will start with "C:/" (or another letter, or something else if you aren't using windows). That is the route to find the image file from the root directory of the disc identified by the drive letter. When you move the files to a different computer, the url in the dae file will only find the image if it's location has exactly the same path, absolute or relative, as on the original computer. The simplest way to achieve that is to put the images in the same folder as the dae file and use a relative path. The relative url will then be just the filename. It still won't work with an absolute path unless the two computers have identical directory routes to where the files are stored.

The other names derived from the image filename, of which there are many in other sections, shouldn't matter as far as finding the file is concerned. They are all (usually) internal references within the dae file.

 

Share this post


Link to post
Share on other sites
You are about to reply to a thread that has been inactive for 3111 days.

Please take a moment to consider if this thread is worth bumping.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...