pptx2mp4 プログラム仕様
- 概要:
Windows版PowerPointを使って、PPTXファイルをMP4へ変換します。
- 詳細説明:
必要条件として pip install pywin32 を実行してモジュールをインストールしてください。
- 関連リンク:
pptx2mp4_usage
- pptx2mp4.convert_pptx_to_mp4(input_path: Path, output_path: Path, *, resolution: int = 720, fps: int = 30, quality: int = 100, default_slide_duration: int = 5, use_timings_and_narrations: bool = True, overwrite: bool = False) None
- 概要:
PowerPointのCreateVideoを使ってPPTXをMP4に変換します。
- 詳細説明:
入力されたPowerPointファイルを指定された設定でMP4動画ファイルに変換します。 変換の進捗状況を標準出力に表示し、完了するまで待機します。
- 引数:
- param input_path:
入力となるPowerPointファイルのパス。
- type input_path:
pathlib.Path
- param output_path:
出力するMP4ファイルのパス。
- type output_path:
pathlib.Path
- param resolution:
動画の縦解像度。
- type resolution:
int
- param fps:
動画のフレームレート。
- type fps:
int
- param quality:
動画の品質設定。
- type quality:
int
- param default_slide_duration:
タイミング未設定時の1スライドの秒数。
- type default_slide_duration:
int
- param use_timings_and_narrations:
記録済みのタイミングとナレーションを使用するかどうか。
- type use_timings_and_narrations:
bool
- param overwrite:
既存の出力ファイルがある場合に上書きするかどうか。
- type overwrite:
bool
- 戻り値:
- returns:
なし。
- rtype:
None
- 例外:
- raises FileNotFoundError:
入力ファイルが存在しない場合に発生します。
- raises ValueError:
入出力ファイルの拡張子が適切でない場合に発生します。
- raises FileExistsError:
出力ファイルがすでに存在し、overwriteがFalseの場合に発生します。
- raises RuntimeError:
PowerPointのビデオ作成処理に失敗した場合、またはMP4ファイルが作成されなかった場合に発生します。