AL_USDMaya
AL_USDMaya copied to clipboard
Instanced prims breaking selection
Hi,
I'm getting some incorrect results when using the plug with the following arrangement of usd files. I've modelled this structure on information from Sebastian on the usd-interest google group so it should be sound.
I've included the contents of some usd files that I'm using to test with. When I load the shot_layout.usda file, it will always select RockA_01 no matter which one I select. If I set instanceable to false in the component.usda file it works as expected.
Thanks Jason
// shot_layout.usda -- instancing 2 rocks in a shot layout
#usda 1.0
(
defaultPrim = "world"
)
def Xform "World" {
def Xform "RockA_01" (
add references = @./component.usda@
)
{
double3 xformOp:translate = (5, 5, 5)
uniform token[] xformOpOrder = ["xformOp:translate"]
}
def Xform "RockA_02" (
add references = @./component.usda@
)
{
double3 xformOp:translate = (-5, -5, -5)
uniform token[] xformOpOrder = ["xformOp:translate"]
}
}
// component.usda -- The interface file for the rock component
#usda 1.0
(
defaultPrim = "RockA"
)
def Xform "RockA" (
assetInfo = {
asset identifier = ""
string name = ""
}
kind = "component"
instanceable = true
payload = @./payload.usda@
variants = {
string LevelOfDetail = "proxy"
}
add variantSets = ["LevelOfDetail"]
)
{
variantSet "LevelOfDetail" = {
"high" {}
"medium" {}
"low" {}
"proxy" {}
"bbox" {}
}
}
// payload.usda -- mesh data that makes up the rock
#usda 1.0
(
defaultPrim = "RockA"
)
over "RockA" (
variants = {
string LevelOfDetail = "proxy"
}
add variantSets = ["LevelOfDetail"]
)
{
variantSet "LevelOfDetail" = {
"high" {
def Xform "geom"
{
def Sphere "Mesh01" () {}
def Sphere "Mesh02" () {}
}
}
"medium" {
def Xform "geom"
{
def Sphere "Mesh01" () {}
def Sphere"Mesh02" () {}
}
}
"low" {
def Xform "geom"
{
def Sphere "Mesh01" () {}
def Sphere "Mesh02" () {}
}
}
"proxy" {
def Xform "geom"
{
def Sphere "Mesh01" () {}
def Sphere "Mesh02" () {}
}
}
"bbox" {
def Xform "geom"
{
def Sphere "Mesh01" () {}
def Sphere "Mesh02" () {}
}
}
}
}
Hi Jason, this is a known issue which I thought we had documented somewhere - but maybe not. We will definitely look into this in the next few days, and try and work out what's involved in fixing. Will update as soon as we can. Thanks!
Thanks Eoin. It's looking great so far.
Apologies if you've already documented this and I've missed it.
Hi Jason, I've found the cause of the bug, and have a fix in internal review. It should be on the public branch in a day or two.