Chaos Corona Forum

Chaos Corona for Cinema 4D => [C4D] General Discussion => Topic started by: fla on 2015-05-24, 17:35:19

Title: Grass scattering
Post by: fla on 2015-05-24, 17:35:19
Hi to all!

I'm starting to test recently published Corona alpha2 for Cinema. I must say I'm really impressed!
Today I was playing around with grass scattering (with surface Spread) and I have a question for anybody that has some experience with it.
It's precompiling really fast when I keep number of render instances low (p.e. when I cover a filed aprox 20meters from camera) but when I try covering aprox 40meters the "Preparing" part goes on and on. I'm asking this because a friend that uses Max + Corona does not seem to experience the same long "Preparing" pre-rendering time. I'm wondering if anybody could light the subject a bit.

I'm attaching a preview image - it only took 2min to render this, which is pretty fast (I'm covering aprox 20m radius around the camera - actually only the cone area). But increasing the size just increases the time really drastically (to about 20min of Preparing time).
Is there anything I can do to speed it up?

The grass patch has 800 polys, it's not that heavy.

I'm using i7 3930K, 32gb ram

cheers,
matej
Title: Re: Grass scattering
Post by: cecofuli on 2015-05-25, 00:24:18
Maybe precompiling in C4D isn't multithread. Look at the CPU usage.
Title: Re: Grass scattering
Post by: fla on 2015-05-25, 10:40:12
I've checked. CPU usage is around 10-15%. Ram around 8Gb. Which is comparable to vray readings when rendering(precompiling) the same scene.
Title: Re: Grass scattering
Post by: maru on 2015-05-25, 12:06:14
Are you using textures on these grass blades? Could you check without? Maybe this is the case?
Title: Re: Grass scattering
Post by: fla on 2015-05-25, 12:32:15
I've tried rendering without the texture on the blades - I'm afraid preparing time stays the same as before.
I'm attaching the whole scene.

cheers
m
Title: Re: Grass scattering
Post by: burnin on 2015-05-25, 14:43:57
Yes, the problem is in multiplying too many by plugin (even MoGraph cloner would have problem spreading 7million objects) that's an old limitation of cinema (it can handle polygon counts but not too many objects).

Edit: Deleted useless mumbling
Title: Re: Grass scattering
Post by: fla on 2015-05-25, 14:46:06
Thanks for an elaborative answer burnin!
Title: Re: Grass scattering
Post by: fLuppster on 2015-05-26, 11:42:15
Yeah, C4D is really bad in handling many objects, i had the same problem. I will soon purchase carbon scatter to get some multicore support.

But in your case its easy to fix: just increase the size of your grass patches. It should be no problem, because your ground is pretty flat. I had ~1 mio. grass patches in one scene, it was a nightmare...
Title: Re: Grass scattering
Post by: fla on 2015-05-26, 12:01:16
Carbon Scatter is multithreaded? It looks like a good piece of software.
Does anybody have experience with it?

Yes, I could easily make a biger grass patch, but the result isn't as good as having small patches and having control over size and color variations.
Title: Re: Grass scattering
Post by: pBarrelas on 2015-05-26, 16:43:01
I use SurfaceSPREAD and personally I think it works a lot better than the built in a Cloner object.
Title: Re: Grass scattering
Post by: fla on 2015-05-26, 22:24:17
If it's really Cinema that can't handle large number of clones than even Carbon Scatter might not help?
I really hope Maxon would tackle the problem in the next version.

@pBarrelas: I like SurfaceSpread too. It has many usefull options with scattering, many of which Mograph doesn't. I mainly use it for grass.
Title: Re: Grass scattering
Post by: kod3d on 2015-05-26, 23:20:40
I use carbon scatter a lot and it has saved me when it comes to cloning vegetation and other stuff! It can handle much more than the native cinema cloners and it is so much smoother with much more intuitive controls when it comes to spreading vegetation. You can use splines etc. which is really handy. I can clone a hole field with grass and it can handle it just fine. Also I don't work for them, I just like it..

:)
Title: Re: Grass scattering
Post by: fLuppster on 2015-05-27, 12:33:01
Sure, SurfaceSpread is nice and has many useful options, but its not really faster than the mograph stuff. Thats the big advantage @ CarbonScatter.

I had a bug with SurfaceSpread: It was not possible to populate the patches with a normal alignment. So i had to change to mograph cloners. But C4D and scattering is as we already found out a pain in the ass... To be honest, i dont think that there will be changes very soon, because the viewport core in cinema unfortunately supports just a single core. They need to change the whole C4D core, which would take a long long time.
Title: Re: Grass scattering
Post by: fla on 2015-05-28, 09:28:50
Thanks guys!
Nice to hear that Carbon Scatter is the way to go.
I'm downloading the trial right now.
Will get back with feedback.

cheers
m
Title: Re: Grass scattering
Post by: Han on 2015-06-02, 22:43:14
A lot of people wrote a lot of nonsense.
In C4D several amended versions in different modules of the program for multithreading.
When using Corona at the moment there is a problem with the preparation stage. Remember this is only the Alpha 2.

Attached image Made in the standard render.
All objects are unique. Render Instance were not used.
Polycount - 30M   Time -1,21min
Title: Re: Grass scattering
Post by: burnin on 2015-06-04, 00:51:23
It's not problem with poly count, but object count. It starts at around 30.000+ objects (even without any geometry/ nulls only).
Title: Re: Grass scattering
Post by: fLuppster on 2015-06-04, 01:52:56
Yep, thats the point. Thats why i dont understand where you see all the "nonsense" @ Han...
Title: Re: Grass scattering
Post by: kod3d on 2015-06-04, 12:51:45
Well I just rendered a super dense field of grass with 117.000 instances and 460M polys with Carbon Scatter and there was No preparation time. None! That wasn't the case with surface spread or mograph. Also RAM usage was 1.5 gigs out of my 64. I don't know how carbon does it but it looks to me that it somehow overcame the standard C4D problem with many objects. At least it feels that way. I repeat I bought the program like everyone else and i don't work for them! It used to be a crappy program back in the beggining it would crash a lot but nowdays no crashes and its a solid tool.

Title: Re: Grass scattering
Post by: Han on 2015-06-04, 21:13:45
PT+PT 297,000 clones with MoGraph preparation scene about 30 ~ 40 seconds.
8.7 M polygons
12 GB of RAM
2560х1600

PT+UHD  297,000 clones with MoGraph preparation scene about 30   seconds.
8.7 M polygons
- 4096х3112   
- 13.6 GB of RAM
https://www.dropbox.com/s/u591ak2d8xpeokw/T3.png?dl=0

Future releases will Corona the proxy and then we go back to our subject.
Title: Re: Grass scattering
Post by: burnin on 2015-06-05, 12:39:29
Nice workarounds ;)
Title: Re: Grass scattering
Post by: Rhodesy on 2015-06-05, 13:14:56
Thats and interesting test @Kod3d. I bought carbon scatter when it was on offer recently but only tried it for a short test and just found the workflow more of a hassle than surface spread as it seemed more disjointed from C4D and more its own thing. But perhaps thats its strength and does all that generation outside C4D, I will dust it off and give it another go now. Cheers
Title: Re: Grass scattering
Post by: alekba on 2015-06-05, 22:17:12
I hope that in future versions of Corona will be supported Hair render, in a similar way as in Vray, or Corona team maybe make Corona own scatter for C4D. Anyway it is necessary to be patient, I have no doubt that we will be rewarded with some nice solution.
  Do not know how  works surface Spread, but mograf have some..... limitations. For example, when distribute clones on surface you need much more clones than is required or be visible, but they eat your resources. So you can with Hair make distribution for clones. In Hair menu choose add Hair guides and set  guides numbers to 1 and for min. spacing put value depending of grass patch size, then simply draw.  In generate tab chose spline, make Hair object editable, disable hair render. In cloner menu chose object mode, and put hair spline there. In that way have control how many clones have and his distribution.
 I hope you understand my  Tarzan tongue :p
Title: Re: Grass scattering
Post by: Barba on 2015-06-19, 11:35:33
How do you make grass with Corona? i m looking for it to make carpets
Title: Re: Grass scattering
Post by: Old man on 2015-06-19, 13:18:03
See the attached file
https://www.dropbox.com/s/szgoukfy20vguq1/Grass.7z?dl=0
Title: Re: Grass scattering
Post by: Barba on 2015-06-22, 11:52:46
Ok thanks I'll check it
.)
Title: Re: Grass scattering
Post by: fla on 2016-03-03, 21:32:42
I've made a short video about the topic CarbonScatter vs SurfaceSpread.

If there's intereset in these kind of video I'm ready to make some more.

thanks
matej
Title: Re: Grass scattering
Post by: Rhodesy on 2016-03-04, 17:09:56
Thanks for the vid - thats mighty impressive. I am trying to install my carbon scatter on my R17 but I can only seem to get it to work on R16. There is an update but it doesnt seem to do anything for me so far. I do wish eon would just do a simple installation like everyone else!
Title: Re: Grass scattering
Post by: fla on 2016-03-04, 17:55:12
@Rhodesy: I'm not completely sure but I think it sad somewhere that it runs R17. Good luck with it!
Title: Re: Grass scattering
Post by: 4b4 on 2016-03-04, 21:50:50
Deffo worth checking out forester as well. http://www.3dquakers.com (http://www.3dquakers.com)

It's very tightly integrated in C4D and has excellent cloner options and a load of in depth tutorial videos.   There's a thread over at cgsociety about it as well, seems to be pretty highly regarded.

I've always hated grass but I get on alright with it now and it plays nicely with the variation shader as well.
Title: Re: Grass scattering
Post by: Nejc Kilar on 2016-03-04, 23:05:52
Deffo worth checking out forester as well. http://www.3dquakers.com (http://www.3dquakers.com)

It's very tightly integrated in C4D and has excellent cloner options and a load of in depth tutorial videos.   There's a thread over at cgsociety about it as well, seems to be pretty highly regarded.

I've always hated grass but I get on alright with it now and it plays nicely with the variation shader as well.

slightly offtopic question but does the variance shader work with Corona for things like grass and leafs?
Title: Re: Grass scattering
Post by: 4b4 on 2016-03-05, 07:47:23
Yep, works a treat in the diffuse channel.  It's easy to set the number of polygons used for the each blade of grass, leaf, petal etc.  You then just use that number to vary colour/texture every x polygons.
Title: Re: Grass scattering
Post by: Nejc Kilar on 2016-03-05, 20:57:10
Yep, works a treat in the diffuse channel.  It's easy to set the number of polygons used for the each blade of grass, leaf, petal etc.  You then just use that number to vary colour/texture every x polygons.

Thanks! I haven't tried the R17 yet but the variance shader seems quite fundamental for arch vis :)
Title: Re: Grass scattering
Post by: Rhodesy on 2016-03-06, 00:02:55
In typical Maxon fashion it's only the studio version that gets it though! Kendo shaders from tools 4d does much the same thing though.