Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

3ds Max - Sculpted Prims exporter Petition / pledges

Kyrah Abattoir
cruelty delight
Join date: 4 Jun 2004
Posts: 2,786
05-08-2007 12:00
the problem of doing projection mapping from a model to a sphere is that you will lose some decent amount of data in the process for a non spherical object, and also for objects that have a distinct detailed front and plain back side you waste pixels on the back side.

I would still recommend to at least tweak the ray cage so you can grab details like the shape of the nose and ears a little better.

I did a few tests with mechanical shapes with little to no success , the lod seems to be twitchy at best.
_____________________

tired of XStreetSL? try those!
apez http://tinyurl.com/yfm9d5b
metalife http://tinyurl.com/yzm3yvw
metaverse exchange http://tinyurl.com/yzh7j4a
slapt http://tinyurl.com/yfqah9u
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-08-2007 13:19
Kyrah, agreed. I did that as just a quick test to see if my idea would work at all. There are always going to be limits on what kinds of objects can be created using sculpt maps. In that example the poles are at the top of the head and the base of the neck. To get a better result of that same model it would likely work better to detach the nose and ears and do them seperately. The overall head shape came out very well. The nose and ears are lacking because not enough points were sampled in those areas.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-08-2007 13:25
From: Ziggy Puff
camilla Yosuke posted a tutorial here which I think addresses that. She takes a sphere, deletes the 2 pole vertices, extrudes the row of vertices right below those (the top/bottom latitudes), then shrinks those down to almost a point. This gets you a 'pole' that's really a group of vertices, and makes the 'sphere's' topology the same as a cylinder. At least, I think that's why she did that.


I think that's really pretty unnecessary. Since the top and bottom edges of the sculpt map define only single points they all end up the same color and what little variation there might be isn't over a large enough area to have much effect on the quality of the resulting sculptie. Running the Solidify plugin takes two seconds, whereas editing the UV's as was done in that tutorial takes several minutes, for no appreciable gain in shape quality.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
Ziggy Puff
Registered User
Join date: 15 Jul 2005
Posts: 1,143
05-08-2007 13:42
Good point. For Blender, it's needed to get the sphere to unwrap into a square correctly (I think).
Kyrah Abattoir
cruelty delight
Join date: 4 Jun 2004
Posts: 2,786
05-08-2007 16:39
i have been trying to sculpt a mechanical element :

http://kdc.ethernia.net/wp-content/uploads/cornershot15.jpg <-yeah this is from me :p)

(not the full thing, just one of the bolted side plates that hold the pistol), by building using the polygons of a properly mapped cylinder to follow the contours of the objects and it's relief, so by giving to a part or another more or less quads i am effectively allocating to it more or less pixels from the final sculptmap.

But it doesn't work exactly that way... it seems working from a sphere is far better than from a capless cylinder as the shape i got finally looked "kinda" like the original, but only with a proper texture applied and when the lod wasn't making it explode or.. turn into a ball -_-
_____________________

tired of XStreetSL? try those!
apez http://tinyurl.com/yfm9d5b
metalife http://tinyurl.com/yzm3yvw
metaverse exchange http://tinyurl.com/yzh7j4a
slapt http://tinyurl.com/yfqah9u
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-08-2007 17:41
Great looking model, Kyrah. I definitely noticed during my experiments that the LOD sucks eggs. It's way too agressive at too close a distance.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
Shack Dougall
self become: Object new
Join date: 9 Aug 2004
Posts: 1,028
05-08-2007 18:19
From: Chip Midnight
I definitely noticed during my experiments that the LOD sucks eggs. It's way too agressive at too close a distance.


Just wondering if the object detail settings in preference help at all, i.e., if maxing the preference gives better LOD. And if it doesn't, maybe that would be a reasonable request to ask LL to give the higher detail settings a better LOD.
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-08-2007 18:33
From: Shack Dougall
Just wondering if the object detail settings in preference help at all, i.e., if maxing the preference gives better LOD. And if it doesn't, maybe that would be a reasonable request to ask LL to give the higher detail settings a better LOD.


Yes, they do seem to help. At the default (slider in the middle) it's pretty bad. At the highest setting it's not too bad from what I can tell so far.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
Infiniview Merit
The 100 Trillionth Cell
Join date: 27 Apr 2006
Posts: 845
05-08-2007 23:34
Nice work on your technique Chip, very impressive, that is a revolutionary step for statues.

So did you use more than one prim on that model?
Iridium Linden
Wikkid Linden
Join date: 12 Mar 2007
Posts: 262
05-09-2007 00:12
Have you commented on LOD in the talk section of the wiki on scupted prims? Qarl Linden has been monitoring that page very carefully and absorbing Resident feedback as well as answering a lot of questions. If you haven't checked it out, you can find it here: http://wiki.secondlife.com/wiki/Talk:Sculpted_Prims.
Yakumo Masukami
Registered User
Join date: 7 Sep 2006
Posts: 22
05-09-2007 03:47
Given that one of the the first sculpted prims output script was for Maya, is there anyone out there that can let me know how to prep an object ready for output to sculpties from Maya?
Most of my experience is in LW, which seems to be sparsely covered when it comes to creating sculpted prims.
Thanks
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-09-2007 06:48
From: Infiniview Merit
Nice work on your technique Chip, very impressive, that is a revolutionary step for statues.

So did you use more than one prim on that model?


The head is just a single sculptie, but it really should have been done with more (one for the head, one for each ear, and one for the nose). I did another experiement with breaking a complex model up into several sculpties to see how hard it would be. Turns out it's really not all that difficult, at least with the model I tried. I posted the results so far in the Gallery here.

Heretic, I have seen the discussion in the Wiki. I find the format very difficult to follow and I'm curious why such discussions aren't taking place here in the discussion forums which are much better suited to it.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
Joannah Cramer
Registered User
Join date: 12 Apr 2006
Posts: 1,539
05-09-2007 10:37
From: Gearsawe Stonecutter
You really should not have to Photo Shop anything or need plugins.


The plugin in question is available for free, and can be run from also free Irfan View if i recall correct, so it's not really much of issue in the end. There's two modelling ways discussed in this thread really -- Chip's method is generally more convenient because you can model the target shape in any way you find comfortable, but it has drawback that baking should fail in cases where projected ray(s) intersects target mesh more than once. The 'start with cylinder' method limits you to certain modeling techniques, but allows to created shapes that ray-tracing wouldn't parse properly so it can be useful in some cases as well.
Joannah Cramer
Registered User
Join date: 12 Apr 2006
Posts: 1,539
05-09-2007 10:41
From: Yakumo Masukami
Most of my experience is in LW, which seems to be sparsely covered when it comes to creating sculpted prims.


With Lightwave 9 you'll be able to use Chip's method with a simple setup of surface nodes and the built surface baker. For earlier Lightwave versions it's possible to replicate 'textured cylinder' way.
Shack Dougall
self become: Object new
Join date: 9 Aug 2004
Posts: 1,028
05-09-2007 10:50
From: Chip Midnight
I'll put together a tutorial for my method when I get a chance, but briefly what I'm doing is using a sphere, shrinking it down very small, adding a projection modifier to it, scaling the cage up large enough to enclose the model I'm creating a sculpt map for, associating that model with the projection modifier on the sphere, and then baking a diffuse map from the projection. The UV mapping on the target mesh doesn't matter because the map is rendered using the sphere's UVW's. That gets around the limitation of having to model using a sphere or cyllinder. Having to invert the rendered map isn't really a big deal at all because this method requires a final step in Photoshop anyway. The top and bottom rows of polys in the UV map are tris, not quads, so it needs to have Flaming Pear's Solidify plugin run on it to fill in the holes.


I'm having some limited success with this technique. At least, I think I've got the material figured out.

I started with Abu's material (thanks! :-) which used some angle rotations to orient the X, Y, and Z gradients. That was more than my mind could handle, lol. So I tried using the XY, YZ, and ZX planes instead. That seemed to do about the same thing. So, MultR uses XY, MultG uses YZ, and MultB uses ZX. Then, to eliminate the need to invert the rendered map, I changed the gradients to go from white to 0. So, MultR goes from 255,255,255 to 0,255,255, MultG goes from 255,255,255 to 255,0,255, and MultB goes from 255,255,255 to 255,255,0.

That seems to be the material that we're after. I've attached my version. I called the material "Thing to Sculpt". Because my first confusion was where I should put it. If I'm understanding the technique correctly, the material goes on the thing that we're trying to make a sculptie from. So I called it "Thing to Sculpt", LOL.

So, far I've gotten some recognizable things into SL, but nothing that makes me go wow. I need to experiment some more, but I thought I'd report my progress and share the material file in case it might be helpful.

Thanks Chip and Abu! No way, I would have gotten this far without your help.

Edit: oh, and I'm using 3ds max 9. Not sure what issues there might be if you try to load the material file in an older version.

Edit: Removed the attachment, since Abu has uploaded a better one.
Abu Nasu
Code Monkey
Join date: 17 Jun 2006
Posts: 476
05-09-2007 11:26
How dare you tear apart my shader and fix it. Er, or is that make your own from from the nested RGB Mults? How dare you tear apart my shader and learn something.

Either way, thanks. Probably would have taken me another day to get to it.

Now, about the bounty...
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-09-2007 11:49
From: Joannah Cramer
Chip's method is generally more convenient because you can model the target shape in any way you find comfortable, but it has drawback that baking should fail in cases where projected ray(s) intersects target mesh more than once.


I think the projection modifier only records a single hit on the target mesh. As long as the target object is a solid without holes in it and the center of the projection cage is inside the target object then rays sent along each surface normal of the sphere will produce a hit.

The big problem with sculpties is the use of a standard sphere with poles. This would all work much better if the sculpt mesh was a geosphere instead.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
Shack Dougall
self become: Object new
Join date: 9 Aug 2004
Posts: 1,028
05-09-2007 15:19
From: Shack Dougall
I'm having some limited success with this technique.


So far, very limited.

I created a simple capsule from max's extended primitives. In Max, the capsule was longer than it was wide. When I projected this onto the sphere, it had the right shape, but the proportions were off. Instead of looking like a slender capsule, it looked more like a grill tank.

And I created a planar primitive, added some noise to make it look like terrain, and applied the shell modifier to give it depth. I can't get that to work at all using ray projection. In Render To Texture, under Projection Mapping there is an Options button that opens Projection Options. If I change the method from ray trace to UV match, then I can get something approximating the terrain, but it's not totally right and the proportions are off.

Still working...
Dimentox Travanti
DCS Coder
Join date: 10 Sep 2006
Posts: 228
05-11-2007 07:03
When i get gback into town ill Cover the bounty (is there a detailed tut for it) (sorry if i missed it)
_____________________
LSL Scripting Database - http://lsl.dimentox.com
Abu Nasu
Code Monkey
Join date: 17 Jun 2006
Posts: 476
05-11-2007 09:27
I finally made it to Preview and everything looks good. I know what is wrong with the original shader that I posted and I'll post a cleaner updated version soon. For some reason, two axis are flipped and the third is not. But I still have to do a bit of testing just to make sure.

I'm gonna drop almost everything and start writing this weekend.

I know the attachment prolly belongs in the gallery, but this is my first test just to see. It shows very clearly that I have a lot of catching up to do.
Abu Nasu
Code Monkey
Join date: 17 Jun 2006
Posts: 476
05-11-2007 10:50
Looks like I finally got my shader up and running to my satifaction. Well, mostly to my satisfaction. The angles and directions are quite how I think, but they are proper.

As near as I can tell, only y is flipped. This caused a decent round or two of trial-n-error. Ugh!

One trick I did pull in the newer shader is that I mirrored the gradient. This means tile and offset had to be tweaked. Why did I mirror? Because interpolation and tiling don't always get along. I've seen edges get artifacts because of wrap-around. This can cause not good things to happen. This can be especially true when dealing with such small images being used for big things. Nothing like a dimple at the bounding box edges. Ugh! I'll clarify this when I get to my tutorials.

Bake it, upload, apply, and scale to taste.

If it doesn't work for you dispite my testing, let me know.

And I'll have a few tutorials up soon.
Shack Dougall
self become: Object new
Join date: 9 Aug 2004
Posts: 1,028
05-11-2007 20:40
From: Abu Nasu

One trick I did pull in the newer shader is that I mirrored the gradient. This means tile and offset had to be tweaked. Why did I mirror? Because interpolation and tiling don't always get along. I've seen edges get artifacts because of wrap-around. This can cause not good things to happen. This can be especially true when dealing with such small images being used for big things.


I might have seen something like this. Not sure if it was this exactly, but I was getting some artifacts on the top edge of a 64 x 64 baked image. Took me a while to realize that it was only occurring in the small image. If generated a larger image, for example 512 x 512, and then photoshopped it down to the smaller size, everything was okay.

Anyway, thanks Abu! I'll give it a spin!
SuezanneC Baskerville
Forums Rock!
Join date: 22 Dec 2003
Posts: 14,229
05-15-2007 22:11
Do any of the modelling programs have a "shrinkwrap" command, which would let you create an arbitrary model, then create a sphere ( for sculpted prim making), select them, execute the shrinkwrap command, and it would move the points in the sphere to approximate the arbitrary model?

Note: I'm not asking about the presence of a command called shrinkwrap, rather one that accomplishes the effect described above.
_____________________
-

So long to these forums, the vBulletin forums that used to be at forums.secondlife.com. I will miss them.

I can be found on the web by searching for "SuezanneC Baskerville", or go to

http://www.google.com/profiles/suezanne

-

http://lindenlab.tribe.net/ created on 11/19/03.

Members: Ben, Catherine, Colin, Cory, Dan, Doug, Jim, Philip, Phoenix, Richard,
Robin, and Ryan

-
Elle Pollack
Takes internets seriously
Join date: 12 Oct 2004
Posts: 796
05-16-2007 18:29
I'm still awaiting a tutorial for Abu's shader methood (will you have to change it again now that the normals have been fixed in Preview?) but between Chip's description and Gearsawe's tutorial I seem to have it down except for one thing...I keep rendering the sculpt map of the sphere I applied the Projection modifier to and not the shape I actualy want rendered. I'd offer to help writing the tutorial if I can just get one done right...
_____________________
***********************************************
"Ya'll are so cute with your pitchforks and torches ..." ~Brent Linden

SL streams a world, can you also stream a mind?
Chip Midnight
ate my baby!
Join date: 1 May 2003
Posts: 10,231
05-16-2007 20:42
I'll definitely do one if someone doesn't beat me to it, Elle. It got a bit waylayed by two hard drive failures (on consecutive days no less), and my parents visiting for a week. I probably won't be able to get back to any serious sculptie work until the middle of next week.

Suzanne, I'm pretty sure that the kind of feature you're describing is out there. If memory serves Max has something like that (called the conform modifier I think?). The forthcoming Zbrush 3 does also. It's one of the things shown off in the demo movie. It shows a plane conforming to a human head mesh, but only along one axis. Conforming a sphere to another mesh and then rendering a sculpt map from the deformed sphere would certainly be a viable method for making scuplties.
_____________________

My other hobby:
www.live365.com/stations/chip_midnight
1 2 3 4 5 6