function h3d_test_movie(hts, file) n = numel(hts); fh=figure; hold on; set(fh, 'Position', [100 100 600 300]) movegui(fh); A = moviein(n); mov = avifile(file, 'fps', 7); %, 'compression', 'RLE'); for i=1:n subplot(1,2,1); h3d_draw_sphere_hs(hts{i}, 120) % sizes = size(hts{i}.hs); % axis('equal'); % axis([0 sizes(1) 0 sizes(2)]); % imagesc(hts{i}.hs); % xlabel('\beta'); % ylabel('\alpha'); xlabel('x'); ylabel('y'); zlabel('z'); subplot(1,2,2); plot3points(hts{i}.points,'.'); axis('equal'); axis([-1 1 -1 1 -1 1]); xlabel('x'); ylabel('y'); zlabel('z'); A(i) = getframe(fh); mov = addframe(mov, A(i)); % pause end mov = close(mov);