[Maya-Python] A good way to store mesh components in a set ?

2021-06-17 Thread Alejandro
Hello guys!, What would be the fastest solution to store all the face components for each object I select into its correspondent set? I'm trying something like this: mesh = maya.cmds.ls(selection=True, type='mesh')[0] selection_list = OpenMaya.MSelectionList() selection_list.add(mesh) dag_path

Re: [Maya-Python] A good way to store mesh components in a set ?

2021-06-18 Thread Alejandro
ely via the viewport. > > On Fri, 18 Jun 2021 at 00:44, Alejandro wrote: > >> Hello guys!, >> >> What would be the fastest solution to store all the face components for >> each object I select into its correspondent set? >> >> I'm tryi

[Maya-Python] Fastest way to extract faces / separate in maya ?

2021-06-23 Thread Alejandro
Howdy fellas ! I'm working on a project that will need to extract faces (stored in a set) from a combined object, the object has usually more than 500 groups of faces that need to be extracted and separated in an individual mesh, the vertex order need to be preserved. I did a mockup with

[Maya-Python] Re: transfer vertex ids between different

2021-06-21 Thread Alejandro
I believe you need to have the same topology to transfer the vertex order, since you'll need the same number of vtx to copy the id to, otherwise maya will crash. On Monday, June 21, 2021 at 6:57:33 p.m. UTC-4 Rudi Hammad wrote: > Hello, > haven't found anything in the search bar and nothing

Re: [Maya-Python] A good way to store mesh components in a set ?

2021-06-18 Thread Alejandro
ld you like it to take? > > On Fri, 18 Jun 2021 at 12:38, Alejandro wrote: > >> Thanks a lot Marcus, >> >> I was looking for an option with the API for speed, since I have scenes >> with more than 1k objects, do you think it's not needed in this case ? >>

[Maya-Python] MFnMesh.getTriangles() issue.

2021-07-28 Thread Alejandro
Hello people ! I've been trying to store faces from combined objects using getTriangles method, but I think I'm using it wrong.. to reproduce the issue, duplicate a sphere, move it a little so you can see, and combine it into a single object, name it as "combined_mesh" then: ``` sel =

[Maya-Python] Getting any face for each polygon shell

2022-06-10 Thread Alejandro
Hi guys. I'm trying to query all the polygon shells on a mesh without selecting them, (not the number of shells, the actual components per shell) cmds.polySelect(expandToShell=1) will select the shells and this is causing maya to be unstable and of course it's quite slow. is it possible

[Maya-Python] Maya standalone timeline speed

2022-09-02 Thread Alejandro
Hello I want to measure how long does an animation playback takes in both maya UI and standalone. If I load any animation in maya and do a playback like this: for t in range(1, 100, 1): cmds.currentTime(t) it takes around 2 minutes to complete in maya UI. But if I do the same with the

Re: [Maya-Python] Maya standalone timeline speed

2022-09-02 Thread Alejandro
Thanks Tenghao for you answer. I'll give it a try, I wonder if I can use cmds.profiler in maya standalone, I'll check and come back ! :D Alejandro Cabrera __ On Fri, Sep 2, 2022 at 6:12 PM Tenghao Wang wrote: > I suggest you do a Maya profiler and check your sc