Node.jsのAPIを使用してBMPをEPSに変換します
Contents
[
Hide
Show
]概要
この記事では、nodejs **を使用してBMPをEPSに変換する方法について説明します。次のトピックをカバーしています。
nodejsイメージからEPS変換
JPG、TIFF、PNGなどの他の形式からNodeJSを使用してEPSに画像を変換することは、BMPに似ています。
nodejs BMPからEPS変換
Aspose.Page BMPの品質をEPS変換に確認し、無料オンラインで結果を表示できます bmp to eps converter そして、 eps viewerで結果のEPSファイルを表示するよりも
Asposesaveimageasepsメソッドを呼び出して、EPSに画像を保存します。
nodejsのEPSにBMPを保存するために文字列を使用します
次のNodeJSコードスニペットでは、入力画像と出力EPSファイルが文字列で割り当てられます。
1const AsposePage = require('asposepagenodejs');
2
3const img_file = "./data/PAGENET-361-10.bmp";
4
5console.log("Aspose.Page for Node.js via C++ examples.");
6
7AsposePage().then(AsposePageModule => {
8
9 //SaveImageAsEps - convert image to EPS
10 const JSON = AsposePageModule.AsposeSaveImageAsEps(img_file, img_file + ".eps");
11 console.log("SaveImageAsEps => %O", JSON.errorCode == 0 ? "Files(pages) count: " + JSON.filesCount.toString() + JSON.filesNameResult.toString() : JSON.errorText);
12
13},
14 reason => {console.log(`The unknown error has occurred: ${reason}`);}
15);
bmp to eps converter でBMPをオンラインでEPS変換に評価します。複数のBMP画像をEPSファイルに一度に変換し、数秒で結果をダウンロードできます。
GitHubから例とデータファイルをダウンロードできます。