Language
mel mel is Maya Embedded Language (Maya built-in language) acronym,
nike air force 1 high, is a powerful command and scripting language gives you direct control of Maya's features, processes and workflow.
directory
mel can do the basic concept of learning Maya mel can not do mel have to learn it? Can first learn to learn Maya mel it? Do you want to learn math learning mel? Do you want to learn graphics? How to write a mel? How to use the mel? How to learn mel? What is the expression? What is the relationship with the expression of mel? Supplement
Basic Concepts mel mel can do a very important function is to write the interface, Maya mel entire interface is written, Maya all the interface elements can be written to your own mel program interface, you can use mel According to customize their own custom interface. Maya all the buttons in the command is invoked by mel, you can record and put together some of the command, by a key or button to automatically implement this set of commands, like PhotoShop Actions in the same. Maya is in operation every step in the implementation of mel, so any one of Maya's features, can do any operation, you can add your own mel program. mel and the c language with similar syntax, there are powerful string processing capabilities, also includes some of the more low-level commands (such as access to select the object's name and access point in space coordinates and other commands), you can write in a number of Maya No, the more complex functions. mel mel can not do is a scripting language, by the script interpreter (Command Engine) and built-in command of Maya, there are still many limitations. mel can not use the ActiveX plug-in. mel only in accordance with an order already in Maya (dll or registered mll in the command) be extended, can not directly call the function module dll. We normally use the dll or exe file is the result of compiler optimization of binary files, command execution speed is very fast. mel scripting language is the text of a script interpreter process the command's execution speed is slow, about 20 times slower. mel does not support pointers, can not directly manipulate memory. This leads to a lot of the efficiency of the super-low indirect memory operations may make the speed lower than 100-fold or even 1000 times. But this also has an indisputable advantage is that no memory leaks to ensure the stability of the Maya. mel can not read and write binary files. Since the mel does not support pointers, data structures do not support, even if we can not be very meaningful to read and write binary files. mel renderer can not write a program, the player; can not write Maya does not exist in the interface elements, such as TreeView,
nike air force one, RichEdit, transparent windows, etc.; can not write the program to read binary files, such as 3dmax (*. max), LightWave (*. lwo, *. lw) and so on. Some people have asked mel can write viruses. The answer is yes. What the virus does not require the preparation of mel superb skills, as long as the call by mel dos command or JavaScript / VBScript command on the line. The preparation of the virus is a dog in the manger thing, mel virus must not be highly representative of the technical writers, can only mean that the quality of the poor. mel virus is extremely rare, and only heard was compiled over the domestic and harm their own people. If the virus if you are formatting a hard disk or mel delete a file, you can use programs like EasyRecover to recover, but one thing to remember is that the recovery of damaged files before the hard disk do not write! Including data storage can not be restored to the damaged hard drive! Otherwise, another powerful master could not save you. Mel Maya must learn to learn it? Do not have to learn mel. However, the relationship between Maya and too close to the mel, Maya's user interface is written by mel, you Every step of the operation in the Maya are in the implementation of mel, you are often used in expressions mel, or use someone else procedures for the preparation of external mel, all this requires you at least have a basic understanding of mel. Can first learn to learn Maya mel it? Not. Maya only be familiar with the operation before they can learn mel. Learning at least two months or more general Maya, we can learn mel. Mel whether there should be the basis of learning programming? Should first learn C language to learn mel? Will indeed have a programming foundation of great help learning mel, mel does not mean that science must have a programming foundation. C language and Java language, while the syntax is very similar with mel, but the idea of programming has a big gap, mel pay more attention to the simplicity of the code rather than the code to run efficiently. Mel is not compiled as a scripting language, some programming is not very strict regulatory requirements, learning curve than C or Java easier. Do you want to learn math learning mel? Do you want to learn graphics? If you are the sciences, and 3D graphics programming in the future intends to develop in this area, then learn mathematics and graphics is a must. If you work in the arts, learning Maya mel just to assist mapping, then you are less in mathematics and graphics on the waste of time. mel is a more high-level scripting language called Maya are generally direct method has been programmed, as long as you master the operation of Maya on the line. If you have a good graphics foundations, but will not like to use mel,
air force one low, because many good algorithms can not achieve by mel - mel too slow. How to write a mel? mel is a scripting language, which means you can use any text editor to write, such as WordPad, Notepad, and so on. Maya comes with a good editor, so we generally use an external editor to write mel. Have more professional editor: TextPad, UltraEditor, EditPlus, etc., with these editor, but also in the online (such as Highend3d) mel syntax highlighting download a file, the configuration is completed, we go by. How to use the mel? mel a mel command-line editor, can be directly on the command line (Command Line) implementation can also Window> General Editors> Command Shell execution. Mel multiple lines of code in the Script Editor you can press Ctrl + Enter in the implementation. shelf in the Shelf in the implementation of mel. Select the code to be executed with the mouse to drag and drop on the Shelf, Shelf, on more than a mel icon, point this icon, you can perform your mel code. Use textToShelf command. For example: textToShelf Using the Shelf Editor, add, edit your mel code, or change the icon. mel mel file name of the file and file must take the primary function of the same name. Mel should copy the file to My Documents / Maya/5.0/scripts directory, then enter the main function at the command line to perform this function name to the command. The source of the script (Source Script) Source Script can make mel file code or commands take effect immediately. There are several ways Source Script, for example in the command line source yourScript.mel, or use the Script Editor's File> Source Script ..., or directly drag and drop your files into Maya mel the window. To the Maya startup file userSetup.mel are executed each time it starts a piece of code, we need to add this code in Maya startup file userSetup.mel. The specific method is in the My Documents / Maya/5.0/scripts directory create a new text file and rename it userSetup.mel, and then put your code into the file. If the scripts directory already exists userSetup.mel, put your code to the end of this document. The other can also shortcut keys, menus, Marking Menu, mll plugin, external program files, JavaScript and other methods to call mel. How to learn mel? Science mel is the best reference manual with the help of Maya documents,
air force one high, when they encounter problems, you should first find the answers from these documents. I put the document Mel Command Reference section of the chm file to facilitate inquiries made, you can point here to download. To improve their level of need to look at other people write the mel code. : Alias Maya6.0 scripts directory of all Maya's own store mel, mel free to copy them, modify and distribute, without copyright restrictions, we learn of the template. Another official in the Maya sites and Highend3d can also be downloaded to a large number of useful mel for us to learn. What is the expression? What is the relationship with the expression of mel? mel and the relationship between the expression, Maya helps document made it clear: Expressions have a different purpose from MEL commands and MEL scripts. You enter a MEL command to do a single action, for example, to create a sphere. A MEL script is a list of commands you create to do a sequence of actions, for instance, create a wall-shaped object and apply a brick texture to it. Because you store a MEL script in a file on disk,
nike air force one high, you can run a script in different scenes and different work sessions, whether today or next year. An expression animates one or more attributes over time in a single scene. By default, an expression executes each frame as an animation plays. After you create an expression, it executes whenever you play the animation-including when you play the animation after saving, closing, and reopening the scene. A MEL command or script is not part of a scene after you execute it. You must execute it again to repeat the action. supplement mel is the user and the Maya internal mechanisms for an exchange. mel can not directly write nodes and attributes, it can often use the expression of objects in real-time control. Animation is an integral expression, the expression and animation of the time (time or frame) are closely related, the expression of the animation is calculated every frame. Can be used in expressions mel, but many mel expression is used in the does not make sense, for example, the preparation of the interface are generally not used in the expression of mel. mel script can be used for any scenario. Expression can only be used for a scene, another scene even used the same expression, but also re-created. Expression is mainly to control the properties of objects, you can use equal values of the properties of objects directly or assignment, such as: cone.translateX = 3; and mel must getAttr or setAttr to do the same thing, for example: setAttr cone.translateX 3; What is MayaAPI? What is the relationship with the mel? API - Application Programmer Interface (Application Program Interface). It was also known as SDK, is a specialized interface to the programmer or interface. MayaAPI provides Maya 5 dll files. Maya these dll contains a large number of classes and the control function, we use these classes and functions vc + + to write your own dll (mll) files, these functions the way through the Maya (eg, the form with the mel command) to call. We used to *. mll plugin is written by MayaAPI. MayaAPI more powerful than the mel, more complex, more efficient,
air force one low nike, can do many things that mel can not run more than ten times the speed in the mel. MayaAPI functions in the following points: the preparation of mel commands. Execute mel command. To create objects, select, zoom, delete, and other basic operations. Write manipulator. Writing contexts (tool). Write an attribute node. Preparation of material nodes. File input and output. Exe console application prepared by an independent. MayaAPI procedures for using vc + +, you can use MayaAPI, MFC, there are many SDK, virtually is unlimited. But things can not change the underlying Maya, Maya can not change the mode of operation. Use MayaAPI, need to have vc + + programming experience, and has graphics base. mayamaya entries Atlas Atlas more extended reading: 1
http://www.comicsee.com/index.asp?boardid=6&page=1
Open Category: maya :