Curious about 1.7 instancing

General disscusion about Kray
tajino
Posts: 45
Joined: Thu Nov 16, 2006 10:22 am
Location: Malaysia
Contact:

Curious about 1.7 instancing

Post by tajino »

How does the instancing in 1.7 work? I'm curious, need to know before purchasing kray. Is it something like hd_instance?
pixym
Posts: 53
Joined: Tue Aug 30, 2005 8:11 pm
Location: In front of a PC

Post by pixym »

Eddy MARILLAT
PIXYM
silverlw
Posts: 453
Joined: Thu Jun 02, 2005 7:05 pm
Location: Sweden
Contact:

Post by silverlw »

You have your object that you want to clone in a layer. Add a null and rename it to clone_objname|layer. position the null,rotate scale it animate it and when you render next time you will see the original object + the instanced object.
Instanced objects works with full GI.
tajino
Posts: 45
Joined: Thu Nov 16, 2006 10:22 am
Location: Malaysia
Contact:

Post by tajino »

Eddy, thanks for the link, 15k poly x 800, with GI in 31mins, that's great!. wonder if the rendertime scales proportionately to the render size, or faster?

Thanks for the explaination Silverlw, I was thinking of something along the line of points/polygon normal instance method like implemented in hd-instance, where randomization value could be adjusted on the fly, could be controlled by weightmap for distribution, polygon edge alignment, mixing several different base objects etc etc, which might aid setting up huge amount of clones and making changes at any time quickly and easily.

null is not bad, just that when it has lots of them >100,000 clones, can't imagine how layout would hold up.
Captain Obvious
Posts: 165
Joined: Mon Oct 10, 2005 6:15 pm
Location: London, UK

Post by Captain Obvious »

Instancing doesn't really affect the render time much. 800 instances of a 15k poly mesh should render in about the same amount of time as 800 clones of a 15k poly mesh. The only difference is that trying to render 12 million polygons without using instances is likely to make Lightwave/Kray crash. Basically, instancing is about saving memory, not about cutting down render times.

I don't have access to Kray 1.7, but I just did a quick test in modo. A subdivision surface teapot primitive instanced out 124 times (for a total of 125 teapots) rendered in 25 seconds (with GI). When I converted the instances to real mesh items, it rendered in 35 seconds. The majority of the time increase was tesselating the meshes and generating the KD-tree, rather than actual rendering. As soon as all 5,890,000 polygons were tallied up, rendering was just as fast with real meshes. The biggest difference was the size of the geometry cache: 4.99 megabytes for the instanced version, and 615 megabytes for the "real" version.

When I added blurred reflections and an area light, the render time was 2m 45s for the instanced version, and 2m 50s for the "real" version. That's not a huge time difference, I'd say.
tajino
Posts: 45
Joined: Thu Nov 16, 2006 10:22 am
Location: Malaysia
Contact:

Post by tajino »

Hi Silverlw, just bought kray and tried the instancing with null naming method you describe. But couldn't get kray to render the instance. I think i must be missing something.

If say the object is called "Tree_01" , then the clone should be a null named "clone_Tree_01", am i right? do i need to turn any settings on or any header/tailer commands?

please advice, thanks.
jure
Posts: 2142
Joined: Thu Jun 02, 2005 6:53 pm

Post by jure »

Nope your instance should be called also Tree_01.

If your tree has layers then object name will be:

tree_01:layer1

and you need to name instance

tree_01|layer1

So whenever you don't have layers in your object instance name is the same as object name, when you do have layers you just replace : with |
- Jure
tajino
Posts: 45
Joined: Thu Nov 16, 2006 10:22 am
Location: Malaysia
Contact:

Post by tajino »

thanks Jure, it is working now. :)
pixym
Posts: 53
Joined: Tue Aug 30, 2005 8:11 pm
Location: In front of a PC

Post by pixym »

I do not suceed in having instance in my scene.In addition, the cloned objects are not rendered...
Eddy MARILLAT
PIXYM
tiktane358
Posts: 90
Joined: Thu Nov 16, 2006 9:11 am
Location: France

Post by tiktane358 »

When you want to make instance of an object :
- select the object to clone
- "replace with null"
- change ":" with "|"
so you're sure to have good name.

It works well, but there is no preview, perhaps you must give the null a custom shape. "Custom Null" is a good plug to have low rez preview.
tajino
Posts: 45
Joined: Thu Nov 16, 2006 10:22 am
Location: Malaysia
Contact:

Post by tajino »

tiktane358 wrote:When you want to make instance of an object :
- select the object to clone
- "replace with null"
- change ":" with "|"
so you're sure to have good name.

It works well, but there is no preview, perhaps you must give the null a custom shape. "Custom Null" is a good plug to have low rez preview.
Or have a downres mesh parent to the clone null and deactivate it, as visual reference. would be great to write an lscript to automate it, replace the stand-in child item, run the script, it will rename the parent null which is the clone proxy.

The current null method instancing is only good for small numbers of clones, anything more than a 1000 will bog down layout horribly.

G. it would be best to have instancing the way hd_instance work, polygon/point base instance. but the current method of null is good for quick setups, so if ever hd_instance style instance handling gonna be implemented, i would suggest to keep the current null method as well.

or how about this,upon init Kray render, parse the scene file, read the hd_instance custom object chunk, interprete those values, and render the instance in Kray. since Hd_instance has already have instance proxy preview, will save you a lot of time.

give hd_instance a try, for those who haven't.http://www.happy-digital.com/instance_demo.asp[/url]
tiktane358
Posts: 90
Joined: Thu Nov 16, 2006 9:11 am
Location: France

Post by tiktane358 »

just a note : Kray instances can't be emitters.
(the ball to the left is an instance)
Attachments
testinstance.jpg
testinstance.jpg (48.81 KiB) Viewed 7443 times
tiktane358
Posts: 90
Joined: Thu Nov 16, 2006 9:11 am
Location: France

Post by tiktane358 »

ah for hd_instance since 9.0 has been using to crash when RT reflection and transparency are checked (see happy digital site)
tajino
Posts: 45
Joined: Thu Nov 16, 2006 10:22 am
Location: Malaysia
Contact:

Post by tajino »

It isn't a problem even if hd_instance crash on render in 9 or whatever, the method i suggest is just parsing the scene file for hd_instance parameters, and borrow its custom object interface to setup the instances. interprete and render in Kray. as long as the custom objects works, we've not nothing to worry about.

anyway, i don't see any advantages of using lw9+ with kray at the moment, might even be a long moment.
tiktane358
Posts: 90
Joined: Thu Nov 16, 2006 9:11 am
Location: France

Post by tiktane358 »

I just point this problem because hd_instance is a great plug that saved my life a lot of time and I don't want that people try it and are not informed of that problem. :-)
but I agree with you at 100% for your request.
A lot of work for G. !
Locked