% Darren Pais % Caltech, Aug 4, 2005 % playmovie.m % NOTE: Open your Matlab figure before running this % This funtion creates an AVI movie clip by rotating the current figure % all around, 360 degrees. The elevation is maintained at 30 degrees and % the Azimuth begins at the default -37.5 degrees and goes all the way % around counter-clockwise. % The output avi file is darren.avi and is created in the current directory % Setup aquiring frames while changing the Azimuth by 1 degree in each % frame. for j = 1:360 view(-37.5-j,30); F(j) = getframe(gcf); end % Convert the Matlab movie to and exportable AVI format. movie2avi(F,'darren','quality',90); % Note that the AVI movies created can be further compressed to other % formats such as MPEG2.