Maya Training

Introduction to Hard Surface Modeling

Maya Training

Interiors and Furniture Vol 1 & 2 - Modeling & Cloth

Maya Training

Shading, Lighting and Rendering the Bedroom in MR

Maya Training

Robot volume one - Modeling with animation in mind

Maya Training

Spach-Alspaugh House the complete courseware

Maya Training

Burt The Cartoon Dinosaur Vol 01 - Modeling

New Maya Training

Robot Volume 02 - Hybrid Rigging
You are here > Home > SimplyMaya Community Forums
Loading

Welcome to Simply Maya

Please Sign in or Sign up for an account

Member Login

Lost your password?

Not a member yet? Sign Up!

Old 25-01-2011, 04:02 PM   #1
ymharshe
Registered User
 
Join Date: Jan 2011
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default help required-urgently

Hello Folks,

I am complete newbie to Maya. The question I will putforward might sound very easy for you. But I request you to help me immediately.

I have an output file from a fortran program, which contains coordinates (x,y,z) of particles that I am simulating through the code for settling as a function of time (t).

The output file looks like the following.
t1,x1,y1,z1,x2,y2,z2,x3,....
t2,x1,y1,z1,x2,y2,z2,x3,....
t3,x1,y1,z1,x2,y2,z2,x3,....
t4,x1,y1,z1,x2,y2,z2,x3,....
.......................................
PLEASE SEE THE ATTACHED TXT FILE
I would like to create a movie of motion of these particles using Maya. They are all spherical particles with a uniform size.
Is it at all possible? If yes, how?
Please reply quickly. I have Maya 11. Thanks in advance for your help.
ymharshe
ymharshe is offline   Reply With Quote
Old 25-01-2011, 05:32 PM   #2
stwert
EduSciVis-er
 
Join Date: Dec 2005
Location: Toronto
Posts: 3,371
Thanks: 74
Thanked 709 Times in 642 Posts
Default

I would create a Python script that reads in the file and parses it, then iterates through the required number of particles, with a series of setAttr functions for translate channels. You can look in the documentation for the exact syntax of setAttr. I hope that helps. A more informative thread title will probably get more help faster FYI.
stwert is offline   Reply With Quote
Old 25-01-2011, 07:36 PM   #3
ymharshe
Registered User
 
Join Date: Jan 2011
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

thanks for the reply. But what you have wrote is completely "chinese" for me. What do I do with python? I have no experience in python. moreover, i thought it would as easy as reading the data file through some Maya function and defining the variables. The required number of particles is already decided. I want generate a movie for all particles in the text file e.g. 100 in the attached file. in each row there are 301 columns (1 time + 3(x,y,z)* Nparticles). Each row corresponds to a new time coordinates of 100 particles. I hope I am clear. thanks once again. please see if you could help me further.
ymharshe is offline   Reply With Quote
Old 25-01-2011, 07:42 PM   #4
stwert
EduSciVis-er
 
Join Date: Dec 2005
Location: Toronto
Posts: 3,371
Thanks: 74
Thanked 709 Times in 642 Posts
Default

Well since you've got output from a fortran program, I assumed you were familiar with the process of making a script/program. Python is a pretty high-level language, by which I mean it is relatively simple to read/understand and write.
To my knowledge, Maya doesn't have any built in "functions" to read particle location data. It is not that type of software. Declaring variables as you say, doesn't happen in Maya either, except if you create a script. Creating 100 particles and setting the location of one particle at one time is pretty simple. I don't have maya here right now, but I can see about that when I get home. However, reading in your data file might be more difficult. I don't know the best way to approach that.
stwert is offline   Reply With Quote

A little bit about who we are
Links you might find useful
Catch up with SimplyMaya
SimplyMaya specialises in Maya tutorials. We offer over 1,000 individual Maya training videos, ranging from basic Maya tutorials through to intermediate Maya tutorials. Our tutorials are created by instructors with industry experience and are designed to get you up and running in Maya quickly without making it seem like hard work.

Copyright © 1999-2015 SimplyMaya - vBulletin® Copyright © 2000-2015, Jelsoft Enterprises Ltd.