AIファイルとは何ですか? |知識ベース

導入

AIファイルは、Adobe Illustrator Graphics Editorによって作成および使用されたファイルです。それらはPostScript言語で書かれていますが、これについては記事[「PSファイルとは?」]で読むことができます。 PostScript Language Syntaxには、Backus -Naurフォーム(BNF)のポストフィックス表記があることを思い出してください。

operand1...operandm operator

また、PSファイルには、 prolog and script パーツで構成される構造が最小限にあることを思い出すことができます。

%!PS-Adobe-3.0 EPSF
<header comments>
%%EndComments
%%BeginProlog
{<proc set>}    (not required, but is normally present)
%%EndProlog
<setup>
{<layer>}|{<object>}
{<page trailer>}
<document trailer>
%%EOF

Prolog は、後続のスクリプトに必要なデータを必要としています。レンダリングと印刷が定義されています。このデータには、PostScript言語のバージョン、バウンドボックス、作成者、作成日、タイトルが含まれます。必要なフォント、グローバル変数、および手順もここで定義する必要があります。手順は、すべての手順がリテラル名に接続されている辞書 procsets に組み合わされます。また、すべての procsets にも名前が付いています。必要なフォントまたはその他のリソースが prolog で定義されていない場合のEPSファイルの場合、少なくとも対応するコメント %% documentNeededfonts documentNeededResources %% documentNeededProcsets Script 手順、グローバル変数、および prolog で定義されたフォントを使用するページグラフィックの説明が含まれています。 PS/EPSファイルの構造は、 %% で始まる特別な構造コメントによってマークされています。

.aiファイルとは何ですか?

AIファイルまたはAdobe Illustratorファイルは、AI仕様のAdobeが請求されているように、実際にはEPSファイルです。 EPSファイルに必要な2つのコメントが含まれています。

%!PS-Adobe-3.0 EPSF

and

%%BoundingBox: ...

AIとEPSファイルの違い。

主な違いはオペレーターです。 Adobe Illustratorオペレーターは1つまたは2つのシンボルシーケンスであり、PS/EPSは通常含める人間の読み取り可能なキーワードを使用します 2文字以上。

Adobe Illustratorは、130を超えるこのような1-2文字の演算子を使用しており、それらの定義は、EPSファイルの場合のように、AIファイルのProlog に保存されていませんが、Adobe Illustratorアプリケーションのどこかに保存されます。アプリケーションが開始されると、メモリにロードされている可能性が非常に高いです。 これは、EPSとAIファイルの2番目の主な違いです。

したがって、AIファイルは、Adobe Illustratorが作成、編集、表示、および印刷に使用される場合にのみ、EPSファイルとして扱うことができます。 AIファイルのProlog に含まれていないAdobe Illustratorのライセンスを受けたものにアクセスできない外部消費者向け、AIオペレーターの定義、手順セット、フォントなど、 AI形式は、別の新しいファイル形式と見なす必要があります。

以下に示すように、一部のAIオペレーターはPS演算子の短い形式です。

AI operator

x y m
x y l, x y L
x1 y1 x2 y2 x3 y3 c, x1 y1 x2 y2 x3 y3 C
num w
H
Xa

Native PS operator

x y moveto
x y lineto
x1 y1 x2 y2 x3 y3 curveto
num setlinewidth
closepath
red green blue setrgbcolor

Description

starts a new subpath of the current path
appends a straight line segment to the current path
appends a section of a cubic Bezier curve to the current path
sets the line width parameter in the graphics state
closes the current subpath
sets the current color space in the graphics state to DeviceRGB and the current color to the component values specified by red, green, and blue

その他は、PS演算子のより詳細な形式を表しています。

AI operator

x2 y2 x3 y3 v, x2 y2 x3 y3 V
x1 y1 x3 y3 y, x1 y1 x3 y3 Y
red green blue Xa
red green blue XA
cyan magenta yellow black k
cyan magenta yellow black K
F
f
S
s
[ a b c d tx ty ] llx lly urx ury
h w bits ImageType AlphaChannelCount
reserved bin-ascii ImageMask
XI

Description

adds a Bezier curve segment to the current path between the current point and the point x3, y3, using the current point and then x2, y2 as the Bezier direction points
appends a Bezier curve to the current path between the current point and the point x3, y3 using x1, y1 and x3, y3 as the Bezier direction points
setrgbcolor for fill
setrgbcolor for stroke
setcmykcolor for fill
setcmykcolor for stroke
fills the area enclosed by the current path with the current filling color or pattern, leaving it as an open path
the same, but close path
strokes the area enclosed by the current path with the current filling color or pattern, leaving it as an open path
the same, but close path
describes a raster image in Adobe Illustrator

また、新しいオペレーター、たとえばテキスト、グラデーション、レイヤーを扱うオペレーターがいます。

AI operator

N
n
B
b
(path) modified XG
type To
TO
alignment Ta
a b c d ty ty Tm
ty ty Td
name Ln
[ a b c d tx ty ] llx lly urx ury
h w bits ImageType AlphaChannelCount
reserved bin-ascii ImageMask
XF

Description

neither fills nor strokes, leaving it as an open path
the same, but close path
fills and strokes, leaving it as an open path
the same, but close path
image link operator
begins a text object. The type argument take on one of the following values: 0 − point text; 1 − area text; 2 − path text
ends a text object and restores the current transformation matrix
sets text alignment both horizontally and vertically
sets the text matrix for text along a path
translates the text matrix by tx and ty to the beginning of the next line of text
sets layer name
describes a raster image in Adobe Illustrator when the actual image data is not included in the file

特にグループ化オペレーターに言及する価値があります。彼らはBeginとEndのオペレーターから構成されており、それらの間に他のオペレーターがいます。

AI operator

*u ... *U
u ... U
name type nColors Bd ... BD
topLeftCellIndex selectedIndex Pb ... PB
Mb ... MB
visible preview enabled printing
dimmed hasMultiLayerMasks
colorIndex red green blue
Lb ... LB

Description

begin compound path, end compound path
begin compound group, end compound group
begin gradient definition, end gradient definition
begin palette, end palette
begin mask, end mask
begin layer definition, end layer definition

3番目の違いは、擬似コメントです。 PostScriptの通訳は標準コメント、「」で始まる行、および「 %% 」で始まる構造コメントを区別していることをすでに知っているように。 Adobe Illustratorは、「%_ 」で始まる、いわゆる「擬似」コメントを追加します。これらのコメントは、実際には真新しい、Adobe Illustratorのオペレーターに特有のものです。それらは、PostScriptインタープリターによって無視されるためにコメントとして実装されますが、Adobe IllustratorおよびAIファイルを読み取って解析する他のアプリケーションで使用されます。以下は、そのようなコメントオペレーターの例です。

AI operator

colorSpec colorStyle midPoint rampPoint %_Bs
rampSpec rampType %_Br
%_Gs
%_

Description

gradient color stop description
description of the gradient ramp
opens the graph section
make some other peculiar to Adobe Illustrator operators ignorable by PS interpreter

AIファイルとEPSファイルの最後の違いは、 revisable form です。 Adobeは、ドキュメントの最終フォームとの最終フォームを分離します。 最終フォームには、ページの表示または印刷に必要な情報のみが含まれています。 Revisable Form には、アプリケーションのドキュメントの編集に使用できるが、印刷には必要ない他のものが含まれています。一部のAI演算子は、 revisable form に対してのみ存在します。特に、これらの演算子の多くは、テキストの操作に使用されます。擬似コメントはすべて、 revisable form に使用されます。対照的に、EPSファイルは最終フォームのドキュメントです。

AIファイルは何に使用されていますか?

AIファイルは、Adobe Illustratorアプリケーショングラフィックスの編集、転送、保存に使用されます。

AIファイルを開くにはどうすればよいですか?

AIファイルは、スタンドアロンAdobe Illustratorアプリケーションで開かれて表示できます。 AI Viewerを使用して、AsposeからYPURドキュメントを開くこともできます。これは、インストールを必要としないクロスプラットフォームアプリです。

PDFはAIファイルと同じですか?

いいえ、それらは異なる形式と言語です。 PDFとAIファイルには同じ内部ページの説明モデルがありますが、PDFは静的なページ説明言語であり、AIはPostScriptの動的ページ説明言語のサブセットです。

Have any questions about Aspose.Page?



Subscribe to Aspose Product Updates

Get monthly newsletters & offers directly delivered to your mailbox.