You can read all the details at: Convert PSB to PDF, JPG, or PSD Programmatically using C#
Last active
December 23, 2021 06:19
-
-
Save aspose-com-gists/82ed927dadb9a188f4a0afb937f18313 to your computer and use it in GitHub Desktop.
Convert PSB to PDF, JPG, or PSD Programmatically in C# .NET
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Specify input path for PSB file | |
String sourceFileName = "Simple.psb"; | |
// Load input PSB file | |
Aspose.PSD.ImageLoadOptions.PsdLoadOptions options = new Aspose.PSD.ImageLoadOptions.PsdLoadOptions(); | |
PsdImage image = (PsdImage)Aspose.PSD.Image.Load(sourceFileName, options); | |
// Initialize JpegOptions class object | |
Aspose.PSD.ImageOptions.JpegOptions jpgoptions = new Aspose.PSD.ImageOptions.JpegOptions(); | |
jpgoptions.Quality = 95; | |
// Convert PSB to JPG image file | |
image.Save("Simple_output.jpg", jpgoptions); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Specify path for input PSB file | |
String sourceFileName = "Simple.psb"; | |
// Load input PSB file | |
PsdImage image = (PsdImage)Aspose.PSD.Image.Load(sourceFileName); | |
// Convert PSB to PDF file | |
image.Save(dataDir + "Simple_output.pdf", new Aspose.PSD.ImageOptions.PdfOptions()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Specify path for input PSB file | |
String sourceFileName = "2layers.psb"; | |
// Load input PSB file | |
PsdImage image = (PsdImage)Aspose.PSD.Image.Load(sourceFileName); | |
// Initialize PsdOptions class instance | |
Aspose.PSD.ImageOptions.PsdOptions options = new Aspose.PSD.ImageOptions.PsdOptions(); | |
options.FileFormatVersion = FileFormatVersion.Psd; | |
// Convert PSB to PSD file | |
image.Save("ConvertFromPsb_out.psd", options); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment