3D Programming and Scripting

Sakshi offers students an opportunity to become part of team that brings 3D games, animated films, and interactive motion graphics to life using Maya, Python, Shell Scripting etc. In 3D programming, students learn to fill the important role of the technical artist who has both artistic ability and the skills to solve technical problems and bridge the gap between the creative artist and technical programr.
Sakshi designs Coursewares for various institutes for scripting languages such as:
MEL
Python
ActionScript
"C"
C++
MAYA-API
MaxScript
Shell Programming
RSL
MEL
The Maya Embedded Language (MEL) is a scripting language used to simplify tasks in Autodesk's 3D Graphics Software Maya. Most tasks that can be achieved through Maya's GUI can be achieved with MEL, as well as certain tasks that are not available from the GUI. MEL offers a method of speeding up complicated or repetitive tasks, as well as allowing users to redistribute a specific set of commands with others that may find it useful. It provides some memory management and dynamic array-allocation, and offers direct access to functions specific to Maya.
Python
Python is a dynamic object-oriented programming language that can be used for many kinds of software development. It offers strong support for integration with other languages and tools, comes with extensive standard libraries, and can be learned in a few days. Many Python programrs report substantial productivity gains and feel the language encourages the development of higher quality, more maintainable code.
Python runs on Windows, Linux/Unix, Mac OS X, OS/2, Amiga, Palm Handhelds, and Nokia mobile phones. Python has also been ported to the Java and .NET virtual machines. Python is distributed under an OSI-approved open source license that makes it free to use, even for commercial products. The Python Software Foundation (PSF) holds and protects the intellectual property rights behind Python.
Following are the important features of Python:
 Readable syntax and strong introspection capabilities
 Intuitive object orientation
 Natural expression of procedural code full modularity
 Supporting hierarchical packages
 Exception-based error handling
 Very high level dynamic data types
 Extensive standard libraries and third party modules for virtually every task extensions
 Modules easily written in C, C++ (or Java for Jython, or .NET languages for IronPython) embeddable within applications as a scripting interface.
ActionScript
ActionScript is a scripting language based on ECMAScript. ActionScript is used primarily for the development of websites and software using the Adobe Flash Player platform (in the form of SWF files embedded into Web pages), but is also used in some database applications (such as Alpha Five), and in basic robotics, as with the Make Controller Kit. Originally developed by Macromedia, the language is now owned by Adobe (which acquired Macromedia in 2005). ActionScript was initially designed for controlling simple 2D vector animations made in Adobe Flash (formerly Macromedia Flash). Later versions added functionality allowing for the creation of Web-based games and rich Internet applications with streaming media (such as video and audio).
"C"
C is a general-purpose computer programming language originally developed in 1972 by Dennis Ritchie at the Bell Telephone Laboratories to implement the Unix operating system.
Although C was designed for writing architecturally independent system software, it is also widely used for developing application software.
Worldwide, C is the first or second most popular language in terms of number of developer positions or publicly available code. It is widely used on many different software platforms, and there are few computer architectures for which a C compiler does not exist. C has greatly influenced many other popular programming languages, most notably C++, which originally began as an extension to C, and Java and C# which borrow C lexical conventions and operators.
C++
C++ is a general-purpose programming language. It is regarded as a middle-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup in 1979 at Bell Labs as an enhancement to the C programming language and originally named "C with Classes". It was renamed to C++ in 1983.
C++ is widely used in the software industry. Some of its application domains include systems software, device drivers, embedded software, high-performance server and client applications, and entertainment software such as video games. Several groups provide both free and proprietary C++ compiler software, including the GNU Project, Microsoft, Intel, Borland and others.
Maya API
The Maya API is a powerful tool that allows developers to add new functionality to Maya. Through the Maya API it is possible to add new MEL (Maya Embedded Language) commands, file translators, shaders, animation nodes, 3d graphical manipulators, geometry shapes, types of deformations, dynamic fields, particle emitters, inverse-kinematic solvers, custom hardware-only shaders, motion capture servers, and any type of custom node.
The Maya API does this by providing a rich set of C++ classes which can be used or derived from to provide the new capabilities. These capabilities are, for the most part, completely indistinguishable fromnative Maya capabilities, and perform almost as fast. While it provides a lot of power, the Maya API isnot very complicated to learn, and any programr should be able to write their first simple plug-in very quickly.
The concepts such as the scene graph and dependency graph, which manage the way data are processed, are visible through the Maya API. During designing, a special care is taken to build Maya and its API together in order to maximize extensibility and openness of Maya.
MaxScript
Maxscript is a language used primarily by 3dstudiomax for inter-application 3d editing. Anytime you give your users a scripting language, you hinder your ability to describe what you can do with it. Suffice to say bunches and bunches. Examples include TreeMaker, a dialog box pop-up inside max which let's you control spin dials indicating brances and leaves on a tree. Flower petal explorers are another example but i don't mean to just stay in nature (although we are all natural regardless in the grand scheme, add tangent here). Maxscript covers version numbers sadly. Meaning not all maxscripts will work with your version of studio max. Beware i say, but don't be glum, there are some great sites out there which will offer up for absolutely nothing, some super fine maxscripts per version. Most maxscripts carry the extension ms.
Shell Programming
By typing commands in a shell, your speed and flexibility greatly increase. There are numerous tasks that can be done in a shell that are just not possible with a GUI (Graphical User Interface). Also, by not having the memory overhead of a GUI, programs can run faster and more efficiently. By using powerful scripting, work can be batched and automated.
Different machines will have different Unix Shells. On a Macintosh with OSX there is a Terminal that gives you access to many different flavors of shells for you to run your unix commands. On a Linux or SGI machine there is also a built in Terminal Shell. Both OSX and Linux are Operating Systems built on Unix. On a Windows2000, or WindowsXP system, you will need to download a Unix Emulator, like CyGwin. A simple web search will find many Windows Unix Emulators. These Emulators give you a Shell type environment to run the Unix commands, but have some slight differences.
RSL (Renderman Shading Language)
Shaders are written with RSL (Renderman Shading Language). These descriptions tell the renderer what to do when it needs to render the surface or light that has a shader attached. In order to use shaders you can give them input parameters (for example what color is the surface) and shader will return it's values to the surface it is attached to in order that renderer can proceed with it's rendering. Input parameters for shaders are something you describe when you write a shader. You can have shader receive color of the surface, but if none is given to it, shader can have its default color, which you can also describe. This is how shaders work. You give them input values, and they give you output values. These output values are what renderer uses for rendering.
There are several types of shaders, each one with it's own usage. Shader types are: Surface, Displacement, Volume, Light and Imager Shaders.
Let's have a look at what each type of shader is used for.

Surface shaders
Surface shaders are attached to geometry. These shaders describe optical properties of geometric object. Simply said, Surface shaders tells the renderer what will the surface look like when it is hit by the light. Consider this shader, as the one that describes what will the object look like

Displacement shaders
These shaders change the topology of the surface. In order to change the topology, Displacement shader can do one of two things. It can do REAL displacement, which moves the actual geometry, or it can move the surface normals, which produce the infamous BUMP effect. These shaders are also attached to the geometry.

Volume shaders
Volume shader changes the color of the light ray as it travels through volume. Volume can be one of several things. For one, it can be geometry. If light ray travels through geometry and it has volume shader attached, this shader will modulate light ray's color in a way you've described in shader. Secondly, volume can be light item. This means that you can have, for example, Spot Light's cone represent the volume through which light ray's will be modulated by a volume shader (volumetric lights). As for the third type of volume, if volume shader isn't attached to anything, it will be considered as atmospheric volume shader. Consider fog, myst and similar effects.

Light shaders
This shader represents the light source. With light shader you describe the emission of light rays from the source (item that has the light shader attached) to the destination point, which is the surface being illuminated. These shaders generally give control over light color, shadows, intensity, falloff with distance, barn doors etc. Light shaders are shaders with which you control light sources. Important to note is that light source to which this shader can be attached to is either light item or geometry.

Imager Shaders
Imager shaders operate on image just prior to the final output. When renderer is finished with calculating pixel colors for the image output, this shader operates on these pixels. Look at this kind of shaders as MAX Render Effects. It's a post-process shader, but with access to scene data (just like MAX Render Effects).