material by layer

For all the users of Twilight Render (V1 & V2), to ask questions and get started
Post Reply
fierysurprise
Posts: 4
Joined: Wed Oct 06, 2010 8:49 am

material by layer

Post by fierysurprise » Wed Oct 06, 2010 1:03 pm

hi

how do you assign material by layer in TL?

i've got an SU model with materials per layer but it's not coming through on TL
any ideas?

Fletch
Posts: 12906
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: material by layer

Post by Fletch » Wed Oct 06, 2010 3:22 pm

Twilight materials are determined solely by texture/color.
In Twilight, SketchUp layers are not for materials. They are for objects. To control visibility of objects in SU you can hide the object, or put it on a layer and turn it on and off.

Can you tell me, how does one even apply a material by layer in SketchUp? This is an AutoCAD/Revit behavior.... check out the Revit to Twilight Tutorial.

If you can see a color or texture in SketchUp, you can apply Twilight Material Templates to them.

If you can share a scene, we can take a look.

fierysurprise
Posts: 4
Joined: Wed Oct 06, 2010 8:49 am

Re: material by layer

Post by fierysurprise » Wed Oct 06, 2010 5:06 pm

Thanks for your response, i figured that it wasnt a happening thing.

In SU you can choose to 'colour by layer' in the layer menu box
by changing the colour attributed to each layer to a mapped image you can assign a texture / material to all items on that layer.

I learned 3d from Autocad and so have continued to use this way of doing things as it allows you to alter everything much quicker than painting individual objects and allows nesting of components without interfering with materials.

many thanks

ben

Chris
Posts: 5346
Joined: Sun Mar 08, 2009 3:00 am
OS: Win10
SketchUp: 2016

Re: material by layer

Post by Chris » Wed Oct 06, 2010 8:54 pm

That's a cool feature; I've never seen it before. It looks like the "color by layer" doesn't actually save any of that info into the file; it's just temporary coloring. As soon as you click on the material dialog, the coloring goes away.
Because it's not information actually in the model, there isn't any way to associate a Twilight material with the color.

Fletch
Posts: 12906
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: material by layer

Post by Fletch » Wed Oct 06, 2010 10:17 pm

for instance, (to be clear what Chris is saying)
I have read elsewhere regarding SU's application programming interface (API) and it is not possible to even change a layer's color by ruby because of the lack of interaction allowed by outside applications to that function. (at least this was the case before v.8 of SU)

In addition, the assigning of a texture via the method you describe would not allow you to do anything about the mapping of the texture to an object. For instance, how can you even tell SketchUp the real-world physical dimensions of the texture you are assigning (like wood). You would have to do this (as you mention you use 3dsMax) via another external material editor. You can now, with Twilight, just do this WITHIN SketchUp. See the link to the Revit2Twight tutorial above how to get SketchUp to automatically paint your scene for you by assigning a material from the layer color. It does have the limitation that at the time Didier (the programmer for that ruby which performs that function) did not make it work for nested groups/components. But if you contact him, he may be able to 'fix' that issue.

Gaieus
Posts: 426
Joined: Thu Aug 27, 2009 9:08 am
OS: Win XP + SP3
SketchUp: 6 7 8
Location: Pécs, Hungary
Contact:

Re: material by layer

Post by Gaieus » Thu Oct 07, 2010 11:07 am

Fletch wrote: In addition, the assigning of a texture via the method you describe would not allow you to do anything about the mapping of the texture to an object.
Yes, this s the worst part of it. It's (almost) like texturing a group or component from outside; you will never access the mapping tools in SU.

@Ben; there are plugins that assign geometry on respective layers based on their material (although I would not put raw geometry on other than Layer 0) or which explode your entities and re-group them by material (which groups then you can put whichever layer you want)

http://rhin.crai.archi.fr/RubyLibraryDe ... php?id=213
and
http://www.smustard.com/script/GroupByTexture


Would these help to achieve something you are after?
Gai...

fierysurprise
Posts: 4
Joined: Wed Oct 06, 2010 8:49 am

Re: material by layer

Post by fierysurprise » Thu Oct 07, 2010 1:47 pm

screenshot.JPG
screenshot.JPG (240.27 KiB) Viewed 8593 times
Fletch-

you can change the mapping of the material by layer in SU , when you bring in an image ( for instance some tiles) and apply them as a layer 'colour' you have the option of setting the size of that image in the model , and hence it's mapping.
( see attached screen shot)
Admittedly this blanket applies to the whole model but for stuff like bricks or tiles with a set universal module it's perfect

i' ve been using this technique for years without problems, even when exporting to 3ds for nicer renders in Max/ VIZ

I'm really impressed with what i've seen of TL so far however it just means i'll have to build models a little differently to use it well.

cheers
ben

Fletch
Posts: 12906
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: material by layer

Post by Fletch » Thu Oct 07, 2010 7:42 pm

That's great, Ben! It took me a long time to get used to thinking the way SketchUp thinks (I'm an architect, and I come from a heavy CAD/3dsMax/Revit background as well).

How would you handle mapping bricks or wood texture properly in SU on a curved surface using this method? Or turning them 45*?

fierysurprise
Posts: 4
Joined: Wed Oct 06, 2010 8:49 am

Re: material by layer

Post by fierysurprise » Fri Oct 15, 2010 7:59 am

thats the rub right there i've had limited success with curved surfaces- and there's no way to rotate 90 deg

Fletch
Posts: 12906
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: material by layer

Post by Fletch » Fri Oct 15, 2010 10:10 am

by the way - sorry for the :ot: ... I just noticed in the image above you had sun set to intensity of 20 and softness to 80 :shock: quite some interesting lighting there.
5 is probably max. intensity I've ever used. But perhaps you are doing something artistically and because of the very soft shadow setting you can use this bright of sun?
if you are trying to get a flat diffuse light, it renders quickly with turning sun off and setting sky color to light grey (not 'background' color, but 'sky color')
check this about about sky/sun settings in TWL = see item number 7 in the list.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests