# JavaでPowerPointプレゼンテーションをアニメーションGIFに変換

> Aspose.Slides for Javaを使用して、PowerPointプレゼンテーション（PPT、PPTX）を簡単にアニメーションGIFに変換できます。高速で高品質な結果を提供します。

Source: https://docs.aspose.com/slides/ja/java/convert-powerpoint-to-animated-gif/
Updated: 2025-12-09


## デフォルト設定を使用したプレゼンテーションのアニメーションGIFへの変換 ##

このJavaサンプルコードは、標準設定を使用してプレゼンテーションをアニメーションGIFに変換する方法を示しています:
```java
Presentation pres = new Presentation("pres.pptx");
try {
	pres.save("pres.gif", SaveFormat.Gif);
} finally {
	if (pres != null) pres.dispose();
}
```


アニメーションGIFはデフォルトのパラメーターで作成されます。 

{{%  alert  title="TIP"  color="primary"  %}} 
GIFのパラメーターをカスタマイズしたい場合は、[GifOptions](https://reference.aspose.com/slides/java/com.aspose.slides/GifOptions) クラスを使用できます。以下のサンプルコードをご覧ください。 
{{% /alert %}} 

## カスタム設定を使用したプレゼンテーションのアニメーションGIFへの変換 ##
このサンプルコードは、Javaでカスタム設定を使用してプレゼンテーションをアニメーションGIFに変換する方法を示しています:
```java
Presentation pres = new Presentation("pres.pptx");
try {
	GifOptions gifOptions = new GifOptions();
	gifOptions.setFrameSize(new Dimension(960, 720)); // 生成された GIF のサイズ
	gifOptions.setDefaultDelay(2000); // 各スライドが次に切り替わるまでの表示時間
	gifOptions.setTransitionFps(35); // トランジションアニメーションの品質向上のために FPS を上げる
	
	pres.save("pres.gif", SaveFormat.Gif, gifOptions);
} finally {
	if (pres != null) pres.dispose();
}
```


{{% alert title="Info" color="info" %}}
Asposeが提供する無料の [Text to GIF](https://products.aspose.app/slides/text-to-gif) コンバーターをご確認いただけます。 
{{% /alert %}}
