Mel (Maya Embedded Language)


This is a reference photographic image of a Saw Palmetto frawn taken from near my house.


This drawing was produced to better understand the morphological structure of the plant.




This single curve was created using a basic MEL script. The script allows for manipulating the segmentation but it does not allow for curve placement within the coordinate system or curve length. By clicking on the text to the right of this image, you can see the basic script that was used to create this.

Click for the MEL script









By including a sphrand function and using a for loop, we are able to create random curves within a one unit sphere of the origin point. This will allow us to define the shape of the Palmetto frawn.

Click for the MEL script








To continue with the idea of the palm frawn, we introduce bending of the curve in relation to the points on the curve. By using a exponential curve function that is acting only on the y coordinates of the curve points we are able to get a specific almost parabolic bend. We are able to constrain the points above the xz plane by adding a abs function to the y coordinates.

Click for the MEL script









By constaining the curve points to the z axis( by multiplying the z coordinates bu zero), we are able to get the shape and bend of the palm frawn. With the use of construction angles we are able to get a more uniform structure of the individual leaf spikes. To the left is the UI that was used to create this image.




This is a basic user interface that was created using a MEL script. The interface allows the user to make adjustments to the MEL script, without having to actually go into the code. By clicking on the text to the right of this image, you can see the script that was used to create this user interface.


Click for the MEL UI script














Eventhough I am happy with the results of this project, I have fallen short of the entire assignment. Creating a stem and generating these frawns on a random basis on a NURBS plane is are still things that needs to be accomplished.







As a good art student, I always have my eyes open to interesting things around me. This plant (Miscanthus sinensis ssp.) is growing near my home and it reminded me of this project. I took a couple of reference photos (seen here) and decide to try and get this look out of the Mel scripts that we have produced.

By running the script a number of times with a change in the bend of the curves I was able to get an object that almost represents the actual plant to the left. I then used a basic slim shader (plastic) and connected a color ramp to it to get more of the actual color of the plant (green to a yellowish color). This obvisously can be refined to create more leaves and the curly dead one that are apparent on the plant.