(self)
| 898 | return super().grab_frame(**savefig_kwargs) |
| 899 | |
| 900 | def _run(self): |
| 901 | # make a duck-typed subprocess stand in |
| 902 | # this is called by the MovieWriter base class, but not used here. |
| 903 | class ProcessStandin(object): |
| 904 | returncode = 0 |
| 905 | |
| 906 | def communicate(self): |
| 907 | return '', '' |
| 908 | |
| 909 | self._proc = ProcessStandin() |
| 910 | |
| 911 | # save the frames to an html file |
| 912 | if self.embed_frames: |
| 913 | fill_frames = _embedded_frames(self._saved_frames, |
| 914 | self.frame_format) |
| 915 | Nframes = len(self._saved_frames) |
| 916 | else: |
| 917 | # temp names is filled by FileMovieWriter |
| 918 | fill_frames = _included_frames(self._temp_names, |
| 919 | self.frame_format) |
| 920 | Nframes = len(self._temp_names) |
| 921 | mode_dict = dict(once_checked='', |
| 922 | loop_checked='', |
| 923 | reflect_checked='') |
| 924 | mode_dict[self.default_mode + '_checked'] = 'checked' |
| 925 | |
| 926 | interval = 1000 // self.fps |
| 927 | |
| 928 | with open(self.outfile, 'w') as of: |
| 929 | of.write(JS_INCLUDE) |
| 930 | of.write(DISPLAY_TEMPLATE.format(id=uuid.uuid4().hex, |
| 931 | Nframes=Nframes, |
| 932 | fill_frames=fill_frames, |
| 933 | interval=interval, |
| 934 | **mode_dict)) |
| 935 | |
| 936 | |
| 937 | class Animation(object): |
no test coverage detected