Reputation: 149
I can't convert a simple [0, 20, 0, 20, 0, 20]
to a list
.
Code:
geo = hou.pwd().geometry()
print geo.boundingBox()
print type(geo.boundingBox())
Output:
[0, 20, 0, 20, 0, 20]
<class 'hou.BoundingBox'>
Test:
list(geo.boundingBox())
len(geo.boundingBox())
I get the following error:
object BoundingBox is not iterable.
Object of type 'BoundingBox' has no len()
I read all the related questions but they don't seem to solve my problem.
Upvotes: 3
Views: 16835
Reputation: 798814
Vector3
s can be converted to list
since they implement item access methods.
list(geo.boundingBox().minvec()) + list(geo.boundingBox().maxvec())
Upvotes: 3