It it possible to write a plugin in VRay SDK that creates instances of proxyMeshFile's (alembic files)?
At the moment I have a postTranslate script that works, but gets pretty slow when you have a lot of instances.
I have found examples of creating new Plugins within a plugin using:
VRayPlugin *meshPlugin = (VRayPlugin*) plugman->newPlugin("GeomMeshFile", NULL);
Is that also possible with the instancer? If so, how do I generate the list of instances to pass to the instancer plugin node?
Post translate pseudo code below:
proxyMeshNode = vr.create('GeomMeshFile', 'GeomMeshFile')
proxyMeshNode.set('file', abcPath)
proxyNode = vr.create('Node', 'TransformNode)
proxyNode.set('geometry', proxyMeshNode)
instanceList = []
for i in range(0, 100000):
instanceList.append([0, vrayTr, velTransform, proxyNode)
instanceObj = vr.create('Instancer', instancerName)
instanceObj.set('instances', instanceList)
--
Jacob
At the moment I have a postTranslate script that works, but gets pretty slow when you have a lot of instances.
I have found examples of creating new Plugins within a plugin using:
VRayPlugin *meshPlugin = (VRayPlugin*) plugman->newPlugin("GeomMeshFile", NULL);
Is that also possible with the instancer? If so, how do I generate the list of instances to pass to the instancer plugin node?
Post translate pseudo code below:
proxyMeshNode = vr.create('GeomMeshFile', 'GeomMeshFile')
proxyMeshNode.set('file', abcPath)
proxyNode = vr.create('Node', 'TransformNode)
proxyNode.set('geometry', proxyMeshNode)
instanceList = []
for i in range(0, 100000):
instanceList.append([0, vrayTr, velTransform, proxyNode)
instanceObj = vr.create('Instancer', instancerName)
instanceObj.set('instances', instanceList)
--
Jacob
Comment