Re: Best way to back out ICE instances to Geo + UVs

2015-02-03 Thread julien carmagnac
Select one or many point cloud objects and run.
I hope that help you.

2015-02-03 19:28 GMT+01:00 Eric Thivierge :

>  Sure I'll have a look at the script if you have it handy.
>
> Thanks,
> Eric T.
>
>
> On 2/3/2015 1:18 PM, julien carmagnac wrote:
>
>  Hello,
>
> At least, a simple script can read point clouds data and create all
> instance objects (can be critic if you have many many particles).
> I can share my script if you are interested.
>
>  Julien.
>
> 2015-02-03 17:14 GMT+01:00 Mario Reitbauer :
>
>> In case we are talking about static instances then I would export the
>> particles and instance again in maya.
>>
>>  Otherwise Momentum got a tool called "Instancer" which should do what
>> you want.
>>
>>  Or this here:
>> http://www.si-community.com/community/viewtopic.php?f=19&t=3588
>>
>>  And probably the most reason tool would be emTopolizer 2 from mootzoid.
>>
>> 2015-02-03 17:07 GMT+01:00 Eric Thivierge :
>>
>>> Hi all,
>>>
>>> We need to back out some ICE instances to geometry with UVs to transfer
>>> over to Maya. What's the best way to go about this? I thought I'd seen one
>>> of the Mootzoid plug-ins able to do this but not sure which one it was or
>>> whether actual UVs were generated or if they are just ICE based.
>>>
>>> Any help is appreciated as always,
>>>
>>> Eric T.
>>>
>>>
>>
>
>
Set maSelection = CreateObject("XSI.Collection")
maSelection.AddItems Application.Selection
auMoinsUnPointCloudTrouve = false

SetUserPref siScrCommandLogEnabled , FALSE

for each objEnCour in maSelection
if objEnCour.Type = "pointcloud" then
opereSurPointCloud objEnCour
auMoinsUnPointCloudTrouve = true
end if
next

if not auMoinsUnPointCloudTrouve then
logMessage "Selectionnez un(ou plusieurs) objet de type ""Point 
Cloud"".", siwarning
end if


sub opereSurPointCloud(ByRef inPointCloud)
logMessage "inPointCloud.FullName = " & inPointCloud.FullName
set monNullRangement = GetPrim("Null", inPointCloud.Name & "_instance")
DeselectAll

set maGeometrie = inPointCloud.ActivePrimitive.Geometry

'   for each attributEnCour in maGeometrie.ICEAttributes
'   logMessage "attributEnCour.Name = " & attributEnCour.Name
'   next


set attributPtPosition = 
maGeometrie.GetICEAttributeFromName("PointPosition")
tabDataPtPosition = attributPtPosition.DataArray

set attributSize = maGeometrie.GetICEAttributeFromName("Size")
tabDataSize = attributSize.DataArray

set attributScale = maGeometrie.GetICEAttributeFromName("Scale")
tabDataScale = attributScale.DataArray

set attributOrientation = 
maGeometrie.GetICEAttributeFromName("Orientation")
tabDataOrientation = attributOrientation.DataArray

set attributShape = maGeometrie.GetICEAttributeFromName("Shape")
tabDataShape = attributShape.DataArray


'barre de progression
set oProgressBar = XSIUIToolkit.ProgressBar
oProgressBar.Maximum = attributPtPosition.ElementCount
oProgressBar.Step = 1
oProgressBar.CancelEnabled = true
oProgressBar.Caption = inPointCloud.Name
oProgressBar.Visible= true

questionPourLaCreationDunModelParentDejaPose = false
creationDunModelParent = false
dim nouveauModelParent

for cpt = 0 to attributPtPosition.ElementCount - 1
oProgressBar.Caption = inPointCloud.Name & " to Instance (" & 
cpt & " / " & attributPtPosition.ElementCount & ")"
oProgressBar.Increment

if oProgressBar.CancelPressed then
exit for
end if

'--- position ---
set monVecteurPos = XSIMath.CreateVector3(1, 1, 1)
'logMessage "TypeName(tabDataPtPosition(cpt)) = " & 
TypeName(tabDataPtPosition(cpt))
set monVecteurPos = tabDataPtPosition(cpt)

'logMessage monVecteurPos.X & ", " & monVecteurPos.Y & ", " & 
monVecteurPos.Z


'--- size ---
on error resume next
'logMessage "TypeName(tabDataSize(cpt)) = " & 
TypeName(tabDataSize(cpt))
size = tabDataSize(cpt)

If Err.Number <> 0 Then
'reinitialise l'objet Err
Err.Clear
'logMessage "pas d'attribut : Size"
size = 1
else
'size = tabDataSize(cpt)
end if
On Error GoTo 0



'--- scale ---
on error resume next
'logMessage "TypeName(tabDataScale(cpt)) = " & 
TypeName(tabDataScale(cpt))
set monVecteurScale = tabDataScale(cpt)

If Err.

Re: Best way to back out ICE instances to Geo + UVs

2015-02-03 Thread Oscar Gonzalez Diez
Have a look at the 'create polymesh from instance shapes' addon on rray, it
merges the instances and preserves UVs.

On Tue, Feb 3, 2015 at 6:28 PM, Eric Thivierge 
wrote:

>  Sure I'll have a look at the script if you have it handy.
>
> Thanks,
> Eric T.
>
>
> On 2/3/2015 1:18 PM, julien carmagnac wrote:
>
>  Hello,
>
> At least, a simple script can read point clouds data and create all
> instance objects (can be critic if you have many many particles).
> I can share my script if you are interested.
>
>  Julien.
>
> 2015-02-03 17:14 GMT+01:00 Mario Reitbauer :
>
>> In case we are talking about static instances then I would export the
>> particles and instance again in maya.
>>
>>  Otherwise Momentum got a tool called "Instancer" which should do what
>> you want.
>>
>>  Or this here:
>> http://www.si-community.com/community/viewtopic.php?f=19&t=3588
>>
>>  And probably the most reason tool would be emTopolizer 2 from mootzoid.
>>
>> 2015-02-03 17:07 GMT+01:00 Eric Thivierge :
>>
>>> Hi all,
>>>
>>> We need to back out some ICE instances to geometry with UVs to transfer
>>> over to Maya. What's the best way to go about this? I thought I'd seen one
>>> of the Mootzoid plug-ins able to do this but not sure which one it was or
>>> whether actual UVs were generated or if they are just ICE based.
>>>
>>> Any help is appreciated as always,
>>>
>>> Eric T.
>>>
>>>
>>
>
>


-- 
Oscar González Diez
oscargonzalez.tv
wall.oscargonzalez.tv
vimeo.com/oscargonzalez


Re: Best way to back out ICE instances to Geo + UVs

2015-02-03 Thread Eric Thivierge

Sure I'll have a look at the script if you have it handy.

Thanks,
Eric T.

On 2/3/2015 1:18 PM, julien carmagnac wrote:

Hello,

At least, a simple script can read point clouds data and create all 
instance objects (can be critic if you have many many particles).

I can share my script if you are interested.

Julien.

2015-02-03 17:14 GMT+01:00 Mario Reitbauer >:


In case we are talking about static instances then I would export
the particles and instance again in maya.

Otherwise Momentum got a tool called "Instancer" which should do
what you want.

Or this here:
http://www.si-community.com/community/viewtopic.php?f=19&t=3588

And probably the most reason tool would be emTopolizer 2 from
mootzoid.

2015-02-03 17:07 GMT+01:00 Eric Thivierge mailto:ethivie...@hybride.com>>:

Hi all,

We need to back out some ICE instances to geometry with UVs to
transfer over to Maya. What's the best way to go about this? I
thought I'd seen one of the Mootzoid plug-ins able to do this
but not sure which one it was or whether actual UVs were
generated or if they are just ICE based.

Any help is appreciated as always,

Eric T.







Re: Best way to back out ICE instances to Geo + UVs

2015-02-03 Thread julien carmagnac
Hello,

At least, a simple script can read point clouds data and create all
instance objects (can be critic if you have many many particles).
I can share my script if you are interested.

Julien.

2015-02-03 17:14 GMT+01:00 Mario Reitbauer :

> In case we are talking about static instances then I would export the
> particles and instance again in maya.
>
> Otherwise Momentum got a tool called "Instancer" which should do what you
> want.
>
> Or this here:
> http://www.si-community.com/community/viewtopic.php?f=19&t=3588
>
> And probably the most reason tool would be emTopolizer 2 from mootzoid.
>
> 2015-02-03 17:07 GMT+01:00 Eric Thivierge :
>
>> Hi all,
>>
>> We need to back out some ICE instances to geometry with UVs to transfer
>> over to Maya. What's the best way to go about this? I thought I'd seen one
>> of the Mootzoid plug-ins able to do this but not sure which one it was or
>> whether actual UVs were generated or if they are just ICE based.
>>
>> Any help is appreciated as always,
>>
>> Eric T.
>>
>>
>


Re: Best way to back out ICE instances to Geo + UVs

2015-02-03 Thread Mario Reitbauer
In case we are talking about static instances then I would export the
particles and instance again in maya.

Otherwise Momentum got a tool called "Instancer" which should do what you
want.

Or this here:
http://www.si-community.com/community/viewtopic.php?f=19&t=3588

And probably the most reason tool would be emTopolizer 2 from mootzoid.

2015-02-03 17:07 GMT+01:00 Eric Thivierge :

> Hi all,
>
> We need to back out some ICE instances to geometry with UVs to transfer
> over to Maya. What's the best way to go about this? I thought I'd seen one
> of the Mootzoid plug-ins able to do this but not sure which one it was or
> whether actual UVs were generated or if they are just ICE based.
>
> Any help is appreciated as always,
>
> Eric T.
>
>


Best way to back out ICE instances to Geo + UVs

2015-02-03 Thread Eric Thivierge

Hi all,

We need to back out some ICE instances to geometry with UVs to transfer 
over to Maya. What's the best way to go about this? I thought I'd seen 
one of the Mootzoid plug-ins able to do this but not sure which one it 
was or whether actual UVs were generated or if they are just ICE based.


Any help is appreciated as always,

Eric T.