Itoo Software Forum

Author Topic: Railclone slow? Vray 3  (Read 2692 times)

VIZIOEN

  • Newbie
  • *
  • Posts: 24
Railclone slow? Vray 3
« on: July 27, 2014, 04:54:01 PM »
Hi,

I'm trying to create a slate roof using railclone. I modelled 4 cupa slate tiles in 3DSmax and mudbox. They were 800K polygons imported, which probably was too heavy so I reduced them to 7000 polygons each. But when I try to render the scene (the roof of the smallest building, my lightcache takes FOREVER. Have I made an error in my style maybe? I've attached a few screenshots. As you can see I have 4 segments which I mirror each around a different axis I then put them in a randomizer. I also have the same segments but scaled 50% every other row, so I can get a stretcher bond, also mirrored, in 3 ways and randomized. Those 2 randomizers are in a Sequence that is connected together with the first randomizer in a conditional with an X counter equal to 1. I would have sent the file but for some obscure reason it's 2,2 GB big. Is that normal for a few splines, 4 slates of 28000 polygons in total and 30 railclone objects. I don't really have a way of calculating but I'm estimating the total shouldn't be more than 70 000 000 polygons. My test wasn't even more than 20 000 000.

Also the scene consists of 30 something RAILCLONE objects, for each roofsegment I have created a new style. Maybe this is what causes it? I have a dual XEON e5 2695v2, 64 GB ram, Nvdia quadro K4000. I don't think it's hardware related.



VIZIOEN

  • Newbie
  • *
  • Posts: 24
Re: Railclone slow? Vray 3
« Reply #1 on: July 27, 2014, 04:57:32 PM »
This was a test with a piece of smaller roof also with railclone. This was with 400K polygons for each slate though, so I'm afraid I won't have that much detail anymore even if it's from far away. I'd rather render with the 400 K polygons than with the low poly ones, So I'm hoping I forgot something :)

Rokas

  • Sr. Member
  • ****
  • Posts: 406
Re: Railclone slow? Vray 3
« Reply #2 on: July 27, 2014, 05:41:42 PM »
how many MB are only those 4 slates?
how many MB are your 4 slates + RC roof?

edit, I see lots of splines- probbly you have multiple RCs with the same style for one roof ?

Make sure they are using the same geometry by copying style to multiple:


This solved my issues I had.
« Last Edit: July 27, 2014, 05:50:59 PM by Rokas »

VIZIOEN

  • Newbie
  • *
  • Posts: 24
Re: Railclone slow? Vray 3
« Reply #3 on: July 27, 2014, 07:32:58 PM »
Well the problem is while they are more or less the same Railclone style, they have different parameters due to the angles and orientation differences. Or am I missing something?

Rokas

  • Sr. Member
  • ****
  • Posts: 406
Re: Railclone slow? Vray 3
« Reply #4 on: July 27, 2014, 07:56:44 PM »
I wonder if copying style would help in the first place.
If it would- then you will have to adjust your parameters.

If you would compress the scene with 7zip, I would love to look at it.

iToo

  • Administrator
  • Hero Member
  • *****
  • Posts: 3094
    • iToo Software
Re: Railclone slow? Vray 3
« Reply #5 on: July 28, 2014, 08:50:06 AM »
It would be very helpful if you can save the RC objects in a separate scene, so we can test it.

Regarding the scene's size, which takes more space in a RC object are the segments, because the rest of geometry is built on the fly. RailClone uses two modes to store the segments:

a) Using a scene's object. In this case, the plugin only holds a reference so it doesn't take space.
b) Keeping the segment embedded within the RC object (segment's name is shown as --embedded--). In this mode, you can use the procedure suggested by Rokas, to be sure all styles share internally the same object.

About rendering speed, there are two ways to estimate the number total of polygons (and therefore, the instancing efficiency):

a) Using Display->Debug Mode, to render instances in a different color (VRay only).
b) Using RailClone Tools. This utility generates two groups of items : one object for each segment which can be instanced, and other big mesh with the rest of the geometry.

You can find these and other tips in the Rendering Best Practices guide.
« Last Edit: July 28, 2014, 08:54:06 AM by iToo »
Carlos Quintero
iToo Software

VIZIOEN

  • Newbie
  • *
  • Posts: 24
Re: Railclone slow? Vray 3
« Reply #6 on: July 28, 2014, 01:40:18 PM »
I have checked all this and as far as I know, they all use the same instance, and they are not embedded as I was checking and none were set  as embedded but If I use the copy style to multiple all my orientations change again (as expected). But when I save the file was 20 times smaller. I'll try to copy style to multiple and change my orientation and see what I can find. If it stays this small but still renders slow I'll send the file over.
« Last Edit: July 28, 2014, 02:37:59 PM by OB2030 »

VIZIOEN

  • Newbie
  • *
  • Posts: 24
Re: Railclone slow? Vray 3
« Reply #7 on: July 28, 2014, 03:31:58 PM »
So the file with copied styles and then edited to correct orientations is now around 8 times smaller but still renders the same (mind you it's not my render settings or material because i test render with a default white material). You can find the max file on this URL:  http://vizioen.be/temp/BF_Roof_V3.7z max 2015 Vray 3.00.07, latest railclone. It's actually used as an xref scene so render settings and all are not the ones I use.

iToo

  • Administrator
  • Hero Member
  • *****
  • Posts: 3094
    • iToo Software
Re: Railclone slow? Vray 3
« Reply #8 on: July 28, 2014, 07:46:51 PM »
Thanks for the scene. At quick glance, RC objects are taking much more memory than expected. We are investigating what is the cause.
Carlos Quintero
iToo Software

VIZIOEN

  • Newbie
  • *
  • Posts: 24
Re: Railclone slow? Vray 3
« Reply #9 on: July 28, 2014, 09:36:51 PM »
Thanks for the scene. At quick glance, RC objects are taking much more memory than expected. We are investigating what is the cause.

Thank you!

Rokas

  • Sr. Member
  • ****
  • Posts: 406
Re: Railclone slow? Vray 3
« Reply #10 on: July 29, 2014, 07:03:03 AM »
first of all, not all styles use the same segments- after RailClone26- they are not instances.


using maxscript
$RailClone001.sobjref[1] == $RailClone002.sobjref[1]
Quote
"RailClone003"
"RailClone003 true"
"RailClone004 true"
"RailClone005 true"
"RailClone006 true"
"RailClone007 true"
"RailClone008 true"
"RailClone009 true"
"RailClone010 true"
"RailClone011 true"
"RailClone012 true"
"RailClone013 true"
"RailClone014 true"
"RailClone015 true"
"RailClone016 true"
"RailClone017 true"
"RailClone018 true"
"RailClone019 true"
"RailClone020 true"
"RailClone021 true"
"RailClone022 true"
"RailClone023 true"
"RailClone024 true"
"RailClone025 true"
"RailClone026 false"
"RailClone027 false"
"RailClone028 false"
"RailClone029 false"
"RailClone030 false"
"RailClone031 false"
"RailClone033 false"
"RailClone034 false"

That aside, even those which are instances between themselves, are not instances in top part and bottom part, of your style:


Problem is, that bottom part uses your not optimized plates- but ones with 800000 faces.

The question is, why railclone displays like they are instances from the scene,- why it doesn`t say "embedded", which they are.
After extraction:
« Last Edit: July 29, 2014, 07:04:55 AM by Rokas »

iToo

  • Administrator
  • Hero Member
  • *****
  • Posts: 3094
    • iToo Software
Re: Railclone slow? Vray 3
« Reply #11 on: July 29, 2014, 11:20:01 AM »
Thanks for your help, Rokas.

As you pointed, RailClone026-034 are using yet the high-poly geometry. Although Segment's name is correct in the Style Editor, the reference to geometry is not updated, probably because a previous collapse mesh operation. This issue is described here. In this case the problem is solved clicking the "Reload Segments" button in the Style Editor.

Ideally the reload process should be done automatically by RailClone, to avoid similar problems. We'll work on that.

Regarding the duplicated segments in the sytle (Top/Bottom in the image), there are not problems if both points to the same object. Anyway, when possible is preferable to use unique segments.

By the way, if only there are minor differences between those RC styles (as the Clipping Area orientation in your case), you can export that parameter and copy the style safely. The values in the "Parameters" rollout are not copied with the "Copy Style" operations.
Carlos Quintero
iToo Software

VIZIOEN

  • Newbie
  • *
  • Posts: 24
Re: Railclone slow? Vray 3
« Reply #12 on: July 29, 2014, 06:18:49 PM »
Thank you all for the reply. Much appreciated. I have succesfully reduced the scene to 30 MB and it now renders MUCH faster. Unfortunately I still have 1 problem to solve.

As you can see in the attached screenshot. The vertical siding slates are missing a few slates. but I've managed to fix that. The other problem is that that of the cut. I don't know if there's a way that the bottom doesn't get cut but instead a full tile at the edge of the clipping area begins (this is only necessary for the smaller house and the small roofs that are on 'eye level' you don't see it anywhere else i think. Also the overhanging smaller roofs shouldn't be cut on the sides either as they are rectangular in shape. Any ideas?

I've uploaded the fixed max file too. You can find it at: http://vizioen.be/temp/BF_Roof_V4.7z
« Last Edit: July 29, 2014, 06:21:04 PM by OB2030 »

Paul Roberts

  • iToo Software
  • Hero Member
  • *****
  • Posts: 1517
Re: Railclone slow? Vray 3
« Reply #13 on: July 29, 2014, 08:02:50 PM »
Hi,

To get rid of the clipping at the bottom of the slope you may have to make a few small changes to your style. When using Clipping Paths RailClone uses its local coordinate system to start building the Array. This means that in order to get this to work,  you will have to set your exported Z Rotation parameter to 0, and instead rotate the RailClone object itself so that the Y Axis points up the roof slope. That way you will ensure a full tile at the bottom of the roof.



As the array now starts from the bottom of the roof, it will be necessary to move all the clipping splines down to compensate, you may also need to rotate the tiles in the other direction for the overlap.



Nearly there, but you will still see some clipping. So to remove this we need to shift the bottom row of tiles up a little, away from the clipping path. To do this I've added a conditional operator to detect the first row (Y Count = 1) and used a transform operator to add some bottom padding to move the tiles up a little.



To prevent the clipping on the ends of the rectangular roofs I've removed the conditional operator that was being used to detect the fist segment on the X axis and instead I've wired the sequence operator that is used for the first segment directly into the left and right input slots of the generator. This will provide a clear start and finish to the style and should prevent clipping from occurring on the sides.

You can download a file here with some of these changes made. I hope that helps, please let me know if you have further questions.

Cheers,

Paul
Paul Roberts
iToo Software

Rokas

  • Sr. Member
  • ****
  • Posts: 406
Re: Railclone slow? Vray 3
« Reply #14 on: July 29, 2014, 09:50:46 PM »
How do You rotate Pivot, I have problems rotating it and forcing RC to behave as wanted: