source: Include/Classes/System/Drawing/Imaging/misc.ab@ 123

Last change on this file since 123 was 77, checked in by イグトランス (egtra), 18 years ago

Controlの追加とそれに伴う修正

File size: 17.3 KB
RevLine 
[12]1' Classes/System/Drawing/Imaging/misc.ab
2
3#ifndef __SYSTEM_DRAWING_IMAGING_MISC_AB__
4#define __SYSTEM_DRAWING_IMAGING_MISC_AB__
5
6#include <Classes/System/Drawing/Color.ab>
7
8TypeDef ARGB = DWord
9TypeDef ARGB64 = QWord
10
11Enum ColorMode
12 ARGB32 = 0
13 ARGB64 = 1
14End Enum
15
[77]16Const ALPHA_SHIFT = 24 As DWord
17Const RED_SHIFT = 16 As DWord
18Const GREEN_SHIFT = 8 As DWord
19Const BLUE_SHIFT = 0 As DWord
[12]20Const ALPHA_MASK = ((&hff As ARGB) << ALPHA_SHIFT)
21
22' In-memory pixel data formats:
23' bits 0-7 = format index
24' bits 8-15 = pixel size (in bits)
25' bits 16-23 = flags
26' bits 24-31 = reserved
27
28Enum PixelFormat
29 Indexed = &h00010000
30 Gdi = &h00020000
31 Alpha = &h00040000
32 PAlpha = &h00080000
33 Extended = &h00100000
34 Canonical = &h00200000
35
36 Undefined = 0
37 DontCare = 0
38
39 Format1bppIndexed = (1 Or ( 1 << 8) Or PixelFormat.Indexed Or PixelFormat.Gdi)
40 Format4bppIndexed = (2 Or ( 4 << 8) Or PixelFormat.Indexed Or PixelFormat.Gdi)
41 Format8bppIndexed = (3 Or ( 8 << 8) Or PixelFormat.Indexed Or PixelFormat.Gdi)
42 Format16bppGrayScale = (4 Or (16 << 8) Or PixelFormat.Extended)
43 Format16bppRGB555 = (5 Or (16 << 8) Or PixelFormat.Gdi)
44 Format16bppRGB565 = (6 Or (16 << 8) Or PixelFormat.Gdi)
45 Format16bppARGB1555 = (7 Or (16 << 8) Or PixelFormat.Alpha Or PixelFormat.Gdi)
46 Format24bppRGB = (8 Or (24 << 8) Or PixelFormat.Gdi)
47 Format32bppRGB = (9 Or (32 << 8) Or PixelFormat.Gdi)
48 Format32bppARGB = (10 Or (32 << 8) Or PixelFormat.Alpha Or PixelFormat.Gdi Or PixelFormat.Canonical)
49 Format32bppPARGB = (11 Or (32 << 8) Or PixelFormat.Alpha Or PixelFormat.PAlpha Or PixelFormat.Gdi)
50 Format48bppRGB = (12 Or (48 << 8) Or PixelFormat.Extended)
51 Format64bppARGB = (13 Or (64 << 8) Or PixelFormat.FormatAlpha Or PixelFormat.Canonical Or PixelFormat.Extended)
52 Format64bppPARGB = (14 Or (64 << 8) Or PixelFormat.FormatAlpha Or PixelFormat.PAlpha Or PixelFormat.Extended)
53 Max = 15
54End Enum
55
56Const GetPixelFormatSize(pixfmt) = ((((pixfmt As PixelFormat) >> 8) And &hff) As DWord)
57
58Const IsIndexedPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Indexed) <> 0) As BOOL)
59
60Const IsAlphaPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Alpha) <> 0) As BOOL)
61
62Const IsExtendedPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Extended) <> 0) As BOOL)
63
64Const IsCanonicalPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Canonical) <> 0) As BOOL)
65
66Enum PaletteFlags
67 PaletteFlagsHasAlpha = &h0001
68 PaletteFlagsGrayScale = &h0002
69 PaletteFlagsHalftone = &h0004
70End Enum
71
72Type Align(8) ColorPalette
73 Flags As DWord
74 Count As DWord
75 Entries[1] As ARGB
76End Type
77
78Enum ColorAdjustType
79 Default
80 Bitmap
81 Brush
82 Pen
83 Text
84 Count
85 Any
86End Enum
87
88Type ColorMatrix
89 m[5][5] As Single
90End Type
91
92Type ColorMap
93 OldColor As Color
94 NewColor As Color
95End Type
96
97Enum ColorMatrixFlag
98 Default = 0
99 SkipGrays = 1
100 AltGray = 2
101End Enum
102
103Enum ImageCodecFlags
104 Encoder = &h00000001
105 Decoder = &h00000002
106 SupportBitmap = &h00000004
107 SupportVector = &h00000008
108 SeekableEncode = &h00000010
109 BlockingDecode = &h00000020
110
111 Builtin = &h00010000
112 System = &h00020000
113 User = &h00040000
114End Enum
115
116Enum ImageLockMode
117 Read = &h0001
118 Write = &h0002
119 UserInputBuf= &h0004
120End Enum
121
122Type Align(8) BitmapData
123 Width As DWord
124 Height As DWord
125 Stride As Long
126 PixelFormat As PixelFormat
127 Scan0 As VoidPtr
128 Reserved As ULONG_PTR
129End Type
130
131Type Align(8) EncoderParameter
132 Guid As GUID
133 NumberOfValues As DWord
134 EncoderType As DWord '元はTypeという名前
135 Value As VoidPtr
136End Type
137
138Type Align(8) EncoderParameters
139 Count As DWord
140 Parameter[1] As EncoderParameter
141End Type
142
143Type Align(8) PropertyItem
144 id As PROPID
145 length As DWord
146 piType As Word
147 value As VoidPtr
148End Type
149
150Const PropertyTagTypeByte = 1
151Const PropertyTagTypeASCII = 2
152Const PropertyTagTypeShort = 3
153Const PropertyTagTypeLong = 4
154Const PropertyTagTypeRational = 5
155Const PropertyTagTypeUndefined = 7
156Const PropertyTagTypeSLONG = 9
157Const PropertyTagTypeSRational = 10
158
159Const PropertyTagExifIFD = &h8769
160Const PropertyTagGpsIFD = &h8825
161
162Const PropertyTagNewSubfileType = &h00FE
163Const PropertyTagSubfileType = &h00FF
164Const PropertyTagImageWidth = &h0100
165Const PropertyTagImageHeight = &h0101
166Const PropertyTagBitsPerSample = &h0102
167Const PropertyTagCompression = &h0103
168Const PropertyTagPhotometricInterp = &h0106
169Const PropertyTagThreshHolding = &h0107
170Const PropertyTagCellWidth = &h0108
171Const PropertyTagCellHeight = &h0109
172Const PropertyTagFillOrder = &h010A
173Const PropertyTagDocumentName = &h010D
174Const PropertyTagImageDescription = &h010E
175Const PropertyTagEquipMake = &h010F
176Const PropertyTagEquipModel = &h0110
177Const PropertyTagStripOffsets = &h0111
178Const PropertyTagOrientation = &h0112
179Const PropertyTagSamplesPerPixel = &h0115
180Const PropertyTagRowsPerStrip = &h0116
181Const PropertyTagStripBytesCount = &h0117
182Const PropertyTagMinSampleValue = &h0118
183Const PropertyTagMaxSampleValue = &h0119
184Const PropertyTagXResolution = &h011A ' Image resolution in width direction
185Const PropertyTagYResolution = &h011B ' Image resolution in height direction
186Const PropertyTagPlanarConfig = &h011C ' Image data arrangement
187Const PropertyTagPageName = &h011D
188Const PropertyTagXPosition = &h011E
189Const PropertyTagYPosition = &h011F
190Const PropertyTagFreeOffset = &h0120
191Const PropertyTagFreeByteCounts = &h0121
192Const PropertyTagGrayResponseUnit = &h0122
193Const PropertyTagGrayResponseCurve = &h0123
194Const PropertyTagT4Option = &h0124
195Const PropertyTagT6Option = &h0125
196Const PropertyTagResolutionUnit = &h0128 ' Unit of X and Y resolution
197Const PropertyTagPageNumber = &h0129
198Const PropertyTagTransferFuncition = &h012D
199Const PropertyTagSoftwareUsed = &h0131
200Const PropertyTagDateTime = &h0132
201Const PropertyTagArtist = &h013B
202Const PropertyTagHostComputer = &h013C
203Const PropertyTagPredictor = &h013D
204Const PropertyTagWhitePoint = &h013E
205Const PropertyTagPrimaryChromaticities = &h013F
206Const PropertyTagColorMap = &h0140
207Const PropertyTagHalftoneHints = &h0141
208Const PropertyTagTileWidth = &h0142
209Const PropertyTagTileLength = &h0143
210Const PropertyTagTileOffset = &h0144
211Const PropertyTagTileByteCounts = &h0145
212Const PropertyTagInkSet = &h014C
213Const PropertyTagInkNames = &h014D
214Const PropertyTagNumberOfInks = &h014E
215Const PropertyTagDotRange = &h0150
216Const PropertyTagTargetPrinter = &h0151
217Const PropertyTagExtraSamples = &h0152
218Const PropertyTagSampleFormat = &h0153
219Const PropertyTagSMinSampleValue = &h0154
220Const PropertyTagSMaxSampleValue = &h0155
221Const PropertyTagTransferRange = &h0156
222
223Const PropertyTagJPEGProc = &h0200
224Const PropertyTagJPEGInterFormat = &h0201
225Const PropertyTagJPEGInterLength = &h0202
226Const PropertyTagJPEGRestartInterval = &h0203
227Const PropertyTagJPEGLosslessPredictors = &h0205
228Const PropertyTagJPEGPointTransforms = &h0206
229Const PropertyTagJPEGQTables = &h0207
230Const PropertyTagJPEGDCTables = &h0208
231Const PropertyTagJPEGACTables = &h0209
232
233Const PropertyTagYCbCrCoefficients = &h0211
234Const PropertyTagYCbCrSubsampling = &h0212
235Const PropertyTagYCbCrPositioning = &h0213
236Const PropertyTagREFBlackWhite = &h0214
237
238Const PropertyTagICCProfile = &h8773 ' This TAG is defined by ICC
239 ' for embedded ICC in TIFF
240Const PropertyTagGamma = &h0301
241Const PropertyTagICCProfileDescriptor = &h0302
242Const PropertyTagSRGBRenderingIntent = &h0303
243
244Const PropertyTagImageTitle = &h0320
245Const PropertyTagCopyright = &h8298
246
247' Extra TAGs (Like Adobe Image Information tags etc.)
248
249Const PropertyTagResolutionXUnit = &h5001
250Const PropertyTagResolutionYUnit = &h5002
251Const PropertyTagResolutionXLengthUnit = &h5003
252Const PropertyTagResolutionYLengthUnit = &h5004
253Const PropertyTagPrintFlags = &h5005
254Const PropertyTagPrintFlagsVersion = &h5006
255Const PropertyTagPrintFlagsCrop = &h5007
256Const PropertyTagPrintFlagsBleedWidth = &h5008
257Const PropertyTagPrintFlagsBleedWidthScale = &h5009
258Const PropertyTagHalftoneLPI = &h500A
259Const PropertyTagHalftoneLPIUnit = &h500B
260Const PropertyTagHalftoneDegree = &h500C
261Const PropertyTagHalftoneShape = &h500D
262Const PropertyTagHalftoneMisc = &h500E
263Const PropertyTagHalftoneScreen = &h500F
264Const PropertyTagJPEGQuality = &h5010
265Const PropertyTagGridSize = &h5011
266Const PropertyTagThumbnailFormat = &h5012 ' 1 = JPEG, 0 = RAW RGB
267Const PropertyTagThumbnailWidth = &h5013
268Const PropertyTagThumbnailHeight = &h5014
269Const PropertyTagThumbnailColorDepth = &h5015
270Const PropertyTagThumbnailPlanes = &h5016
271Const PropertyTagThumbnailRawBytes = &h5017
272Const PropertyTagThumbnailSize = &h5018
273Const PropertyTagThumbnailCompressedSize = &h5019
274Const PropertyTagColorTransferFunction = &h501A
275Const PropertyTagThumbnailData = &h501B' RAW thumbnail bits in
276 ' JPEG format or RGB format
277 ' depends on
278 ' PropertyTagThumbnailFormat
279
280' Thumbnail related TAGs
281
282Const PropertyTagThumbnailImageWidth = &h5020 ' Thumbnail width
283Const PropertyTagThumbnailImageHeight = &h5021 ' Thumbnail height
284Const PropertyTagThumbnailBitsPerSample = &h5022 ' Number of bits per
285 ' component
286Const PropertyTagThumbnailCompression = &h5023 ' Compression Scheme
287Const PropertyTagThumbnailPhotometricInterp = &h5024 ' Pixel composition
288Const PropertyTagThumbnailImageDescription = &h5025 ' Image Tile
289Const PropertyTagThumbnailEquipMake = &h5026 ' Manufacturer of Image
290 ' Input equipment
291Const PropertyTagThumbnailEquipModel = &h5027 ' Model of Image input
292 ' equipment
293Const PropertyTagThumbnailStripOffsets = &h5028 ' Image data location
294Const PropertyTagThumbnailOrientation = &h5029 ' Orientation of image
295Const PropertyTagThumbnailSamplesPerPixel = &h502A ' Number of components
296Const PropertyTagThumbnailRowsPerStrip = &h502B ' Number of rows per strip
297Const PropertyTagThumbnailStripBytesCount = &h502C ' Bytes per compressed
298 ' strip
299Const PropertyTagThumbnailResolutionX = &h502D ' Resolution in width
300 ' direction
301Const PropertyTagThumbnailResolutionY = &h502E ' Resolution in height
302 ' direction
303Const PropertyTagThumbnailPlanarConfig = &h502F ' Image data arrangement
304Const PropertyTagThumbnailResolutionUnit = &h5030 ' Unit of X and Y
305 ' Resolution
306Const PropertyTagThumbnailTransferFunction = &h5031 ' Transfer function
307Const PropertyTagThumbnailSoftwareUsed = &h5032 ' Software used
308Const PropertyTagThumbnailDateTime = &h5033 ' File change date and
309 ' time
310Const PropertyTagThumbnailArtist = &h5034 ' Person who created the
311 ' image
312Const PropertyTagThumbnailWhitePoint = &h5035 ' White point chromaticity
313Const PropertyTagThumbnailPrimaryChromaticities = &h5036
314 ' Chromaticities of
315 ' primaries
316Const PropertyTagThumbnailYCbCrCoefficients = &h5037 ' Color space transforma-
317 ' tion coefficients
318Const PropertyTagThumbnailYCbCrSubsampling = &h5038 ' Subsampling ratio of Y
319 ' to C
320Const PropertyTagThumbnailYCbCrPositioning = &h5039 ' Y and C position
321Const PropertyTagThumbnailRefBlackWhite = &h503A ' Pair of black and white
322 ' reference values
323Const PropertyTagThumbnailCopyRight = &h503B ' CopyRight holder
324
325Const PropertyTagLuminanceTable = &h5090
326Const PropertyTagChrominanceTable = &h5091
327
328Const PropertyTagFrameDelay = &h5100
329Const PropertyTagLoopCount = &h5101
330
331Const PropertyTagPixelUnit = &h5110 ' Unit specifier for pixel/unit
332Const PropertyTagPixelPerUnitX = &h5111 ' Pixels per unit in X
333Const PropertyTagPixelPerUnitY = &h5112 ' Pixels per unit in Y
334Const PropertyTagPaletteHistogram = &h5113 ' Palette histogram
335
336' EXIF specific tag
337
338Const PropertyTagExifExposureTime = &h829A
339Const PropertyTagExifFNumber = &h829D
340
341Const PropertyTagExifExposureProg = &h8822
342Const PropertyTagExifSpectralSense = &h8824
343Const PropertyTagExifISOSpeed = &h8827
344Const PropertyTagExifOECF = &h8828
345
346Const PropertyTagExifVer = &h9000
347Const PropertyTagExifDTOrig = &h9003 ' Date & time of original
348Const PropertyTagExifDTDigitized = &h9004 ' Date & time of digital data generation
349
350Const PropertyTagExifCompConfig = &h9101
351Const PropertyTagExifCompBPP = &h9102
352
353Const PropertyTagExifShutterSpeed = &h9201
354Const PropertyTagExifAperture = &h9202
355Const PropertyTagExifBrightness = &h9203
356Const PropertyTagExifExposureBias = &h9204
357Const PropertyTagExifMaxAperture = &h9205
358Const PropertyTagExifSubjectDist = &h9206
359Const PropertyTagExifMeteringMode = &h9207
360Const PropertyTagExifLightSource = &h9208
361Const PropertyTagExifFlash = &h9209
362Const PropertyTagExifFocalLength = &h920A
363Const PropertyTagExifMakerNote = &h927C
364Const PropertyTagExifUserComment = &h9286
365Const PropertyTagExifDTSubsec = &h9290 ' Date & Time subseconds
366Const PropertyTagExifDTOrigSS = &h9291 ' Date & Time original subseconds
367Const PropertyTagExifDTDigSS = &h9292 ' Date & TIme digitized subseconds
368
369Const PropertyTagExifFPXVer = &hA000
370Const PropertyTagExifColorSpace = &hA001
371Const PropertyTagExifPixXDim = &hA002
372Const PropertyTagExifPixYDim = &hA003
373Const PropertyTagExifRelatedWav = &hA004 ' related sound file
374Const PropertyTagExifInterop = &hA005
375Const PropertyTagExifFlashEnergy = &hA20B
376Const PropertyTagExifSpatialFR = &hA20C ' Spatial Frequency Response
377Const PropertyTagExifFocalXRes = &hA20E ' Focal Plane X Resolution
378Const PropertyTagExifFocalYRes = &hA20F ' Focal Plane Y Resolution
379Const PropertyTagExifFocalResUnit = &hA210 ' Focal Plane Resolution Unit
380Const PropertyTagExifSubjectLoc = &hA214
381Const PropertyTagExifExposureIndex = &hA215
382Const PropertyTagExifSensingMethod = &hA217
383Const PropertyTagExifFileSource = &hA300
384Const PropertyTagExifSceneType = &hA301
385Const PropertyTagExifCfaPattern = &hA302
386
387Const PropertyTagGpsVer = &h0000
388Const PropertyTagGpsLatitudeRef = &h0001
389Const PropertyTagGpsLatitude = &h0002
390Const PropertyTagGpsLongitudeRef = &h0003
391Const PropertyTagGpsLongitude = &h0004
392Const PropertyTagGpsAltitudeRef = &h0005
393Const PropertyTagGpsAltitude = &h0006
394Const PropertyTagGpsGpsTime = &h0007
395Const PropertyTagGpsGpsSatellites = &h0008
396Const PropertyTagGpsGpsStatus = &h0009
397Const PropertyTagGpsGpsMeasureMode = &h00A
398Const PropertyTagGpsGpsDop = &h000B ' Measurement precision
399Const PropertyTagGpsSpeedRef = &h000C
400Const PropertyTagGpsSpeed = &h000D
401Const PropertyTagGpsTrackRef = &h000E
402Const PropertyTagGpsTrack = &h000F
403Const PropertyTagGpsImgDirRef = &h0010
404Const PropertyTagGpsImgDir = &h0011
405Const PropertyTagGpsMapDatum = &h0012
406Const PropertyTagGpsDestLatRef = &h0013
407Const PropertyTagGpsDestLat = &h0014
408Const PropertyTagGpsDestLongRef = &h0015
409Const PropertyTagGpsDestLong = &h0016
410Const PropertyTagGpsDestBearRef = &h0017
411Const PropertyTagGpsDestBear = &h0018
412Const PropertyTagGpsDestDistRef = &h0019
413Const PropertyTagGpsDestDist = &h001A
414
415Type ImageCodecInfo
416 Clsid As CLSID
417 FormatID As GUID
418 CodecName As PCWSTR
419 DllName As PCWSTR
420 FormatDescription As PCWSTR
421 FilenameExtension As PCWSTR
422 MimeType As PCWSTR
423 Flags As DWord
424 Version As DWord
425 SigCount As DWord
426 SigSize As DWord
427 SigPattern As *Byte
428 SigMask As DWord
429End Type
430
431#endif '__SYSTEM_DRAWING_IMAGING_MISC_AB__
Note: See TracBrowser for help on using the repository browser.