Mama (software)
Encyclopedia
Mama is an educational
Educational programming language
An educational programming language is a programming language that is designed primarily as a learning instrument and not so much as a tool for writing programs for real-world work.-Learning paths:...

 object-oriented programming
Object-oriented programming
Object-oriented programming is a programming paradigm using "objects" – data structures consisting of data fields and methods together with their interactions – to design applications and computer programs. Programming techniques may include features such as data abstraction,...

 language designed to help young students start programming by providing all language elements in the student mother tongue. Mama programming language is available in several languages, with both LTR and RTL language direction support.

A new variant of Mama was built on top of Carnegie Mellon's Alice
Alice (software)
Alice is a freeware object-oriented educational programming language with an integrated development environment . Later versions are implemented in Java. Alice uses a drag and drop environment to create computer animations using 3D models...

 development environment, supporting scripting of the 3D stage objects. This new variant of Mama was designed to help young students start programming by building 3D animations and games.

History

The first versions of Mama - 1.0, 1.1 and 1.2 - provided simple integrated development environment
Integrated development environment
An integrated development environment is a software application that provides comprehensive facilities to computer programmers for software development...

 (IDE) which contained support to standard elements such as text editor with syntax highlighting
Syntax highlighting
Syntax highlighting is a feature of some text editors that display text—especially source code—in different colors and fonts according to the category of terms. This feature eases writing in a structured language such as a programming language or a markup language as both structures and...

, compiler, debugger, output window, etc. Starting at version 1.5, Mama was integrated with the open source Alice IDE to support drag and drop programming and 3D animating. Mama versions are implemented in Java.

The current release of Mama, version 1.5.4, is available both in English and in Hebrew, and it runs on Microsoft Windows.

Design

Mama was designed to address following problems in educational programming:
  1. Industrial programming languages are designed to be usable for production code, thus introducing additional complexity. Mama is designed solely to teach programming concepts, providing simple and quick development of programs.
  2. Syntax errors frustrate students when start learning programming - Mama's variant over Alice uses a drag and drop environment to create computer animation
    Computer animation
    Computer animation is the process used for generating animated images by using computer graphics. The more general term computer generated imagery encompasses both static scenes and dynamic images, while computer animation only refers to moving images....

    s using 3D models
    3D computer graphics
    3D computer graphics are graphics that use a three-dimensional representation of geometric data that is stored in the computer for the purposes of performing calculations and rendering 2D images...

    .


Mama language is a pure object-oriented language
Object-oriented programming
Object-oriented programming is a programming paradigm using "objects" – data structures consisting of data fields and methods together with their interactions – to design applications and computer programs. Programming techniques may include features such as data abstraction,...

, while the Alice IDE is object based. That implies that while writing textual scripts with Mama language supports all object oriented elements (inheritance
Inheritance (object-oriented programming)
In object-oriented programming , inheritance is a way to reuse code of existing objects, establish a subtype from an existing object, or both, depending upon programming language support...

, polymorphism
Polymorphism in object-oriented programming
Subtype polymorphism, almost universally called just polymorphism in the context of object-oriented programming, is the ability to create a variable, a function, or an object that has more than one form. The word derives from the Greek "πολυμορφισμός" meaning "having multiple forms"...

, generic programming
Generic programming
In a broad definition, generic programming is a style of computer programming in which algorithms are written in terms of to-be-specified-later types that are then instantiated when needed for specific types provided as parameters...

, Observer pattern
Observer pattern
The observer pattern is a software design pattern in which an object, called the subject, maintains a list of its dependents, called observers, and notifies them automatically of any state changes, usually by calling one of their methods...

 style event handling), creating objects and methods with the drag and drop interface is object based - there is no inheritance (and thus no polymorphism). The last observation may confuse beginners - thus it is suggested to use Mama scripts only as advance topics in CS courses.

Mama 1.5 main improvements over Alice version 2.2:
  • added Mama programming language as a (rich) scripting language - 3D scene objects can be manipulated using this scripting mechanism
  • full Unicode support
  • creation and editing of 3D objects
  • support uploading movies to YouTube and publishing in Facebook
  • support for scenery and characters
  • tutorial editor tool for instructors
  • movie export with audio
  • user standalone executables
  • better menu logic
  • many bug fixes


IDE Basics

There are several parts in IDE window: at the top you'll find the main menu and the toolbar, which let you execute commands such as create/open a worlds, import 3D objects into the world, create a standalone application, export the animation to YouTube, etc.
The five windows contained in the main window are:
  • object tree - contains the object list in the current world.
  • 3D window - this is where objects are positioned, moved, turned, etc.
  • events area - lets you edit what happens upon occur of certain event.
  • details area - contains information about the currently selected object in 3 tabs: properties, methods and functions.
  • editor area (at the bottom) - that's where the program code is written, using drag and drop of instructions.


When in scene editing mode, two of the above parts are replaced:
  • control panel - replaces the events area, and displays various controls that help manipulating objects in the 3D window.
  • object gallery - replaces the editor area, and displays objects in hierarchic folders to be selected and embedded in the 3D window.

Following are the basic types available in Alice IDE:
  • Number - a numeric type, represents both integers and reals
  • Boolean - a boolean value, accepting either true or false
  • Object - a general Mama object
  • String - a string, a collection of characters
  • Color - an RGB color
  • TextureMap - a texture map
  • Sound - a sound
  • Pose - a captured pose of an object
  • Position - a 3D array defining a position in the 3D space
  • Orientation - a 3D array defining the orientation in the 3D space
  • PointOfView - a combination of a Position and Orientation

The control instructions available in the bottom of the editor area are:
  • doInOrder - execute a sequence of instructions sequentially
  • doTogether - execute a sequence of instructions simultaneously
  • if - execute a sequence of instructions sequentially only under a given condition
  • while - execute a sequence of instructions sequentially while a given condition holds
  • for - execute a sequence of instructions sequentially a given number of times
  • forAllInOrder - execute a sequence of instructions sequentially iterating over the given collection
  • forAllTogether - execute a sequence of instructions simultaneously iterating over the given collection
  • wait - wait a given amount of seconds
  • print - print the given data to the output console
  • assert - assert that a condition is true, display a message if the condition is false (new in Mama 1.5)
  • Script - add a free Mama script to the program
  • # - add a comment to the program


See also

  • Educational programming language
    Educational programming language
    An educational programming language is a programming language that is designed primarily as a learning instrument and not so much as a tool for writing programs for real-world work.-Learning paths:...

  • Visual programming language
    Visual programming language
    In computing, a visual programming language is any programming language that lets users create programs by manipulating program elements graphically rather than by specifying them textually. A VPL allows programming with visual expressions, spatial arrangements of text and graphic symbols, used...

  • Very high-level programming language
    Very high-level programming language
    A very high-level programming language is a programming language with a very high level of abstraction, used primarily as a professional programmer productivity tool....


External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK