Quantcast
Channel: Scripting - McNeel Forum
Viewing all articles
Browse latest Browse all 5850

Python rs.ObjectsByType() bug

$
0
0

@clement wrote:

Hi @Alain,

there seems to be a "bug" with rs.ObjectsByType() method in python, it does not list any objects placed on hidden layers. eg. using the code below:

ids = rs.ObjectsByType(8 + 16 + 32, state=0)

with state=0, i get zero objects returned, compared to RhinoScript (vb), when i use this code:

Call Main()
Sub Main()
    Dim objs
    objs = Rhino.ObjectsByType(8 + 16 + 32)
    If IsNull(objs) Then 
        Rhino.Print "No Objects found"    
    Else
        Rhino.Print "Objects found: " & UBound(objs) + 1
    End If
End Sub

Objects on hidden layers are returned. IMHO Python behavior should not be different to RhinoScript (vb).

What do you think ?

-
c.

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 5850

Latest Images

Trending Articles



Latest Images