Abrir arquivo AI online
Quando você não precisa da funcionalidade de edição ao abrir o formato AI online, esse AI Viewer é uma boa solução para muitos propósitos. Você pode abrir o arquivo AI online após o upload para o servidor web. O formato AI é um formato vetorial, portanto, a rasterização será realizada no tamanho de imagem especificado. Para as funções adicionais, você pode usar .Net ou Java API de alto código para abrir arquivos de AI nas dimensões de que você precisa
Drag and drop a file or click Open Image
You can reproduce the main functionality of this built-in app using Aspose.PSD
// For the new AI format please use the following code: async Task<bool> OpenPdfToPng(Stream pdfFileStream, string pngFileId, Size size) { pdfFileStream.Position = 0; try { using var pdfDocument = new Aspose.Pdf.Document(pdfFileStream); var page = pdfDocument.Pages[1]; using var imageStream = new MemoryStream(); Resolution resolution = new Resolution(300); PngDevice pngDevice = new PngDevice(size.Width, size.Height, resolution); pngDevice.Process(page, imageStream); imageStream.Position = 0; await StorageService.Upload(pngFileId, imageStream); imageStream.Close(); return true; } catch (Aspose.Pdf.InvalidPdfFileFormatException) { return false; } } // For the Old AI Formats please use the Aspose.PSD high-code API using (AiImage image = (AiImage)Image.Load(sourceFileName)) { ImageOptionsBase options = new PngOptions() { ColorType = PngColorType.TruecolorWithAlpha }; image.Save(outFileName, options); }
You can download Aspose.PSD from Nuget package manager
Check the following list of documentation links:
Please check the offical documentation https://docs.aspose.com/psd/
Abra o arquivo AI com Aspose.PSD ou outros produtos Aspose. Renderize a pré-visualização online do AI File.