The Gist contains code snippets related to Aspose.Imabging Cloud SDK for .NET. For more information on usage of these code snippets, please visit the following links
This gist contains the code snippets related to GIF image to DICOM and JPEG to PNG conversion using Aspose.Imaging Cloud SDK for .NET
String MyClientID = "c235e685-1aab-4cda-a95b-54afd63eb87f"; // Get AppKey and AppSID from https://dashboard.aspose.cloud/ | |
String MyClientSecret = "b8da4ee37494f2ef8da3c727f3a0acb9"; // Get AppKey and AppSID from https://dashboard.aspose.cloud/ | |
ImagingApi imagingApi = new ImagingApi(MyClientSecret, MyClientID,"https://api.aspose.cloud"); | |
// Please refer to https://docs.aspose.cloud/display/imagingcloud/Supported+File+Formats | |
// for possible output formats | |
string format = "dicom"; | |
string folder = null; // Input file is saved at the root of the storage | |
string storage = null; // Cloud Storage name | |
var request = new Aspose.Imaging.Cloud.Sdk.Model.Requests.ConvertImageRequest("kite.gif", format, folder, storage); | |
Stream updatedImage = imagingApi.ConvertImage(request); | |
// Save updated image to local storage | |
using (var fileStream = File.Create("/Users/nayyershahbaz/Documents/myResultant." + format)) | |
{ | |
updatedImage.Seek(0, SeekOrigin.Begin); | |
updatedImage.CopyTo(fileStream); | |
} |
String MyClientID = "c235e685-1aab-4cda-a95b-54afd63eb87f"; // Get AppKey and AppSID from https://dashboard.aspose.cloud/ | |
String MyClientSecret = "b8da4ee37494f2ef8da3c727f3a0acb9"; // Get AppKey and AppSID from https://dashboard.aspose.cloud/ | |
ImagingApi imagingApi = new ImagingApi(MyClientSecret, MyClientID,"https://api.aspose.cloud"); | |
// Please refer to https://docs.aspose.cloud/display/imagingcloud/Supported+File+Formats | |
// for possible output formats | |
string format = "png"; | |
string folder = null; // Input file is saved at the root of the storage | |
string storage = null; // Cloud Storage name | |
var request = new Aspose.Imaging.Cloud.Sdk.Model.Requests.ConvertImageRequest("Converter.jpg", format, folder, storage); | |
Stream updatedImage = imagingApi.ConvertImage(request); | |
// Save updated image to local storage | |
using (var fileStream = File.Create("/Users/nayyershahbaz/Documents/myResultant." + format)) | |
{ | |
updatedImage.Seek(0, SeekOrigin.Begin); | |
updatedImage.CopyTo(fileStream); | |
} |
This gist contains the code snippets related to GIF image to DICOM and JPEG to PNG conversion using Aspose.Imaging Cloud SDK for .NET |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment