* @param path
* the path or url to the movie
* @return 0-based index of the movie
*/
public int addMovie(String path, int type) {
ExMCIMovie mci;
switch (type) {
case MovieShape.MOVIE_MPEG:
mci = new ExMCIMovie();
break;
case MovieShape.MOVIE_AVI:
mci = new ExAviMovie();
break;
default:
throw new IllegalArgumentException("Unsupported Movie: " + type);
}
ExVideoContainer exVideo = mci.getExVideo();
exVideo.getExMediaAtom().setMask(0xE80000);
exVideo.getPathAtom().setText(path);
int objectId = addToObjListAtom(mci);
exVideo.getExMediaAtom().setObjectId(objectId);