Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Preserving UV mapping in Sculpted prims

Bea Georgette
Registered User
Join date: 24 Nov 2006
Posts: 7
09-29-2007 09:33
I have here a question about preserving UV mapping.

I have an old MAX version (6) in which I have an object mapped in two different ways (planar and spherical).

I then export these as OBJ files and read them into Wings3D (which has a exporter for sculpt maps.

In Wings3D the mapping is preserved still.
However, when I export as a sculpt map and import to SL I appear only to have a spherical type mapping.

is this a problem with Wings3D exporter or am I just missing something here?

In fact, how does SL know what mapping was used? The sculpt map merely indicates vertex offsets from an ideal sphere. No mapping involved there.

Would welcome some feedback and correction to my evident misconceptions.

Thanks, Bea
DanielFox Abernathy
Registered User
Join date: 20 Oct 2006
Posts: 212
09-29-2007 10:37
You have to set your mapping mode via script. You can't yet do it from the editor.

llSetPrimitiveParams( [PRIM_TYPE, PRIM_TYPE_SCULPT, "sculpt_map_uuid", PRIM_SCULPT_TYPE_PLANE or PRIM_SCULPT_TYPE_SPHERE or PRIM_SCULPT_TYPE_CYLINDER or PRIM_SCULPT_TYPE_TORUS ] );

See http://wiki.secondlife.com/wiki/LlSetPrimitiveParams
Bea Georgette
Registered User
Join date: 24 Nov 2006
Posts: 7
09-29-2007 23:05
Ahh, thanks for the tip.

This sets the way SL stitches the sculpted prim and I guess how the UV map is used. However, this does not allow for my own mapping. In many places I have read that you can create your own mapping in high-end software and use this in SL (for instance read this in a recent copy of 3D World magazine). The script function you point out allows a limited number of pre-made mappings only. Also it doesn't answer how (if at all possible) SL could possibly get an alternative mapping except for the pre-made ones you pointed out.

Thanks for the feedback anyway. The other mappings alredy in SL will come in handy.

Bea
DanielFox Abernathy
Registered User
Join date: 20 Oct 2006
Posts: 212
09-30-2007 02:51
Ah, sorry, I didn't understand what you meant, then.
Bea Georgette
Registered User
Join date: 24 Nov 2006
Posts: 7
09-30-2007 03:04
It is confusing.
Here's some text from the sculpted prims FAQ:

Q. What about the UV mapping of the Sculpted Prim's single texture?
You can use the texture scale/rotate/offset controls to position the texture on the sculpted prim. In terms of UV mapping, the sculpt map defines the texture space — the sculpted prim will have the same UV space as the object in your modeling program.
Users are discovering various ways to create UV-maps to aid in the creation of image textures.

Does this make sence to anyone?

Bea
Chosen Few
Alpha Channel Slave
Join date: 16 Jan 2004
Posts: 7,496
09-30-2007 05:02
The UV map of a sculpty is aways going to be a uniform 32x32 grid. As with all other prim surfaces in SL, you can change the repeats, offsets, and rotation of the texture any way you want, but you cannot rearrange the map itself.

I'm guessing that whatever you read in PC magazine was either an error (which is EXTREMELY common) or else they were talking about using a high end 3D program that allows multiple UV channels per surface. If it's the latter, then what you would do is have the uniform 32x32 grid on channel 1, and your own custom map on channel 2. Do whatever you want to create your texture on channel 2 and then bake it out to channel 1 at the end so that it will work in SL.
_____________________
.

Land now available for rent in Indigo. Low rates. Quiet, low-lag mainland sim with good neighbors. IM me in-world if you're interested.
Bea Georgette
Registered User
Join date: 24 Nov 2006
Posts: 7
09-30-2007 06:10
Mr Few,

Your a genious.

A very good idea indeed having multiple channels and baking out.
I can only guess this is the method being referred to in the 3D World article.

It makes more sence to me anyhow.
Now, where did I put that manual?

Thanks again, Bea
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
09-30-2007 10:20
this gives me some things to wonder...

is there any description of how the mapping works for other types than sphere? the tech explanation in the wiki only covers spherical mapping... I can gather how stitching works for the torus ( both axial edges ) but can't seem to wrap my head around how the cyllinder would stitch together...
Deanna Trollop
BZ Enterprises
Join date: 30 Jan 2006
Posts: 671
10-01-2007 00:09
From: Void Singer
can't seem to wrap my head around how the cyllinder would stitch together...

Right and left edges are stitched together, top and bottom are open.
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
10-01-2007 00:21
so kinda like planar with a flat surface, but left to right matching... thanks, I was over thinking it ::eyeroll::
Katryna Jie
Registered User
Join date: 24 Jun 2007
Posts: 187
10-01-2007 01:23
hmmm... sooo.. if we have to flip the sculpty maps made by Wings, do we have to flip the UV maps too??
Klingon Warrior
Registered User
Join date: 26 Dec 2006
Posts: 3
10-01-2007 07:41
I've never used Wings, so I don't know for certain how it would handle this, but theoretically if you flip the UV map, you shouldn't have to flip the sculpt map. It should end up flipped already since it was generated via the UV's. That's just a guess though. You'll need to experiment to find out if it's right or wrong.