LOD - Level of Detail

3906
6
06-10-2016 07:58 AM
MarkusKlein
New Contributor II

I look for a way to change the LOD of one of the tutorial scenes. Isn't there a global way to change the lod of the whole scene or do i have to change the rule attributes of every seperate model?

Any kind of help much appreciated! Thanks!

By the way I want to test the trial of city engine in a 3ds max workflow (vfx shot rendered in mental ray - an lod of 3 or 4 is going to be needed).

Maybe someone can share a testscene where the level of detail is already changed to 4. A city scene would be perfect. Woulde be awesome!

Markus.

6 Replies
AdrianWelsh
MVP Notable Contributor

Markus,

It would help to move this thread to the CityEngine​ space and put some tags into your post as well for greater visibility and ideally a quicker answer to your question.

MarkusKlein
New Contributor II

Thank you Adrian,

will do what you've mentioned!

Cheers

Marc

0 Kudos
LR
by
Regular Contributor

If the buildings use the same rule, you can simply select them and change their attribute at the same time. If you use a few different rules, you could select one building and select the other buildings that use the same rule through the rightclick menu. If you're using hundreds of different rules, you could change the attribute with Python (assuming they have the same attribute name).

MarkusKlein
New Contributor II

Hi ZR.

Thank you for your comment! The problem is I can't find a tutorial, which is explaining the concept of changing the rules for LOD in a way that beginners like me don't try to jump out of the next window. I tried to add/rise the level of lod rule in a scene, which is coming with CityEngine, but no luck so far. The changes to the rules were absolutely doing nothing!

A LOD-menu in CityEngine would be nice!

Marc.

0 Kudos
LR
by
Regular Contributor

Ah, that's a different story . There are a couple of ways to do this, but I think the example below is the least painful one for beginners. Basically, you have an attribute called LOD and its value determines which rule the script uses to generate the building. The rules each contain successively more modeling commands to make more detailed buildings. Make a few shapes and drag the rule onto them, then change their "LOD" value (default = 0).

@Range(0,1,2,3)
attr LOD = 0

@StartRule
Lot -->
  case LOD == 0: LOD0
  case LOD == 1: LOD1
  case LOD == 2: LOD2
  else: LOD3

LOD0 -->
  color("#FF0000")

LOD1 -->
  extrude(10)
  color("#00FF00")

LOD2 -->
  extrude(10)
  color("#0000FF")
  comp(f){side: X. | bottom: X. | top: Roof}

Roof -->
  roofGable(30)

LOD3 -->
  NIL
MarkusKlein
New Contributor II

Hi ZR.

sorry, was the last couple of days on the move! Today I will try your approach. Great, that even looks like I would get that to work!

I'll let you know if I got it to work!

I've seen that the gnomon site offers a nice tutorial about CityEngine! seems like to be a great investment for me!

CityEngine in VFX | The Gnomon Workshop

Cheers

Marc

0 Kudos