' GdiPlusTypes.ab #ifndef __GDIPLUSTYPES_AB__ #define __GDIPLUSTYPES_AB__ #require #require #require #require #require #require #require #require #require Namespace Gdiplus TypeDef ImageAbort = *Function(p As VoidPtr) As BOOL TypeDef DrawImageAbort = ImageAbort TypeDef GetThumbnailImageAbort = ImageAbort TypeDef EnumerateMetafileProc = *Function(recordType As System.Drawing.Imaging.EmfPlusRecordType, flags As DWord, dataSize As DWord, data As BytePtr, callbackData As VoidPtr) As BOOL 'Const REAL_MAX = FLT_MAX 'Const REAL_MIN = FLT_MIN 'Const REAL_TOLERANCE = (FLT_MIN * 100) 'Const REAL_EPSILON = 1.192092896e-07 'FLT_EPSILON Enum Status Ok = 0 GenericError = 1 InvalidParameter = 2 OutOfMemory = 3 ObjectBusy = 4 InsufficientBuffer = 5 NotImplemented = 6 Win32Error = 7 WrongState = 8 Aborted = 9 FileNotFound = 10 ValueOverflow = 11 AccessDenied = 12 UnknownImageFormat = 13 FontFamilyNotFound = 14 FontStyleNotFound = 15 NotTrueTypeFont = 16 UnsupportedGdiplusVersion = 17 GdiplusNotInitialized = 18 PropertyNotFound = 19 PropertyNotSupported = 20 End Enum Class PathData Public Sub PathData() Count = 0 Points = NULL Types = NULL End Sub Sub ~PathData() If Points <> NULL Then Delete Points End If If Types <> NULL Then Delete Types End Sub Private /* Sub PathData(ByRef pd As PathData) Debug End Sub */ Sub Operator =(ByRef pd As PathData) Debug End Sub Public Count As Long Points As *System.Drawing.PointF Types As *BYTE End Class ' -------- TypeDef ARGB = DWord TypeDef ARGB64 = QWord Const ALPHA_SHIFT = 24 As DWord Const RED_SHIFT = 16 As DWord Const GREEN_SHIFT = 8 As DWord Const BLUE_SHIFT = 0 As DWord Const ALPHA_MASK = ((&hff As ARGB) << ALPHA_SHIFT) Const GetPixelFormatSize(pixfmt) = ((((pixfmt As PixelFormat) >> 8) And &hff) As DWord) Const IsIndexedPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Indexed) <> 0) As BOOL) Const IsAlphaPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Alpha) <> 0) As BOOL) Const IsExtendedPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Extended) <> 0) As BOOL) Const IsCanonicalPixelFormat(pixfmt) = ((((pixfmt As PixelFormat) And PixelFormat.Canonical) <> 0) As BOOL) Type Align(8) ColorPalette Flags As DWord Count As DWord Entries[1] As ARGB End Type Type ColorMatrix m[5][5] As Single End Type Type Align(8) EncoderParameter Guid As GUID NumberOfValues As DWord EncoderType As DWord '元はTypeという名前 Value As VoidPtr End Type Type Align(8) EncoderParameters Count As DWord Parameter[1] As EncoderParameter End Type Const PropertyTagTypeByte = 1 Const PropertyTagTypeASCII = 2 Const PropertyTagTypeShort = 3 Const PropertyTagTypeLong = 4 Const PropertyTagTypeRational = 5 Const PropertyTagTypeUndefined = 7 Const PropertyTagTypeSLONG = 9 Const PropertyTagTypeSRational = 10 Const PropertyTagExifIFD = &h8769 Const PropertyTagGpsIFD = &h8825 Const PropertyTagNewSubfileType = &h00FE Const PropertyTagSubfileType = &h00FF Const PropertyTagImageWidth = &h0100 Const PropertyTagImageHeight = &h0101 Const PropertyTagBitsPerSample = &h0102 Const PropertyTagCompression = &h0103 Const PropertyTagPhotometricInterp = &h0106 Const PropertyTagThreshHolding = &h0107 Const PropertyTagCellWidth = &h0108 Const PropertyTagCellHeight = &h0109 Const PropertyTagFillOrder = &h010A Const PropertyTagDocumentName = &h010D Const PropertyTagImageDescription = &h010E Const PropertyTagEquipMake = &h010F Const PropertyTagEquipModel = &h0110 Const PropertyTagStripOffsets = &h0111 Const PropertyTagOrientation = &h0112 Const PropertyTagSamplesPerPixel = &h0115 Const PropertyTagRowsPerStrip = &h0116 Const PropertyTagStripBytesCount = &h0117 Const PropertyTagMinSampleValue = &h0118 Const PropertyTagMaxSampleValue = &h0119 Const PropertyTagXResolution = &h011A ' Image resolution in width direction Const PropertyTagYResolution = &h011B ' Image resolution in height direction Const PropertyTagPlanarConfig = &h011C ' Image data arrangement Const PropertyTagPageName = &h011D Const PropertyTagXPosition = &h011E Const PropertyTagYPosition = &h011F Const PropertyTagFreeOffset = &h0120 Const PropertyTagFreeByteCounts = &h0121 Const PropertyTagGrayResponseUnit = &h0122 Const PropertyTagGrayResponseCurve = &h0123 Const PropertyTagT4Option = &h0124 Const PropertyTagT6Option = &h0125 Const PropertyTagResolutionUnit = &h0128 ' Unit of X and Y resolution Const PropertyTagPageNumber = &h0129 Const PropertyTagTransferFuncition = &h012D Const PropertyTagSoftwareUsed = &h0131 Const PropertyTagDateTime = &h0132 Const PropertyTagArtist = &h013B Const PropertyTagHostComputer = &h013C Const PropertyTagPredictor = &h013D Const PropertyTagWhitePoint = &h013E Const PropertyTagPrimaryChromaticities = &h013F Const PropertyTagColorMap = &h0140 Const PropertyTagHalftoneHints = &h0141 Const PropertyTagTileWidth = &h0142 Const PropertyTagTileLength = &h0143 Const PropertyTagTileOffset = &h0144 Const PropertyTagTileByteCounts = &h0145 Const PropertyTagInkSet = &h014C Const PropertyTagInkNames = &h014D Const PropertyTagNumberOfInks = &h014E Const PropertyTagDotRange = &h0150 Const PropertyTagTargetPrinter = &h0151 Const PropertyTagExtraSamples = &h0152 Const PropertyTagSampleFormat = &h0153 Const PropertyTagSMinSampleValue = &h0154 Const PropertyTagSMaxSampleValue = &h0155 Const PropertyTagTransferRange = &h0156 Const PropertyTagJPEGProc = &h0200 Const PropertyTagJPEGInterFormat = &h0201 Const PropertyTagJPEGInterLength = &h0202 Const PropertyTagJPEGRestartInterval = &h0203 Const PropertyTagJPEGLosslessPredictors = &h0205 Const PropertyTagJPEGPointTransforms = &h0206 Const PropertyTagJPEGQTables = &h0207 Const PropertyTagJPEGDCTables = &h0208 Const PropertyTagJPEGACTables = &h0209 Const PropertyTagYCbCrCoefficients = &h0211 Const PropertyTagYCbCrSubsampling = &h0212 Const PropertyTagYCbCrPositioning = &h0213 Const PropertyTagREFBlackWhite = &h0214 Const PropertyTagICCProfile = &h8773 ' This TAG is defined by ICC ' for embedded ICC in TIFF Const PropertyTagGamma = &h0301 Const PropertyTagICCProfileDescriptor = &h0302 Const PropertyTagSRGBRenderingIntent = &h0303 Const PropertyTagImageTitle = &h0320 Const PropertyTagCopyright = &h8298 ' Extra TAGs (Like Adobe Image Information tags etc.) Const PropertyTagResolutionXUnit = &h5001 Const PropertyTagResolutionYUnit = &h5002 Const PropertyTagResolutionXLengthUnit = &h5003 Const PropertyTagResolutionYLengthUnit = &h5004 Const PropertyTagPrintFlags = &h5005 Const PropertyTagPrintFlagsVersion = &h5006 Const PropertyTagPrintFlagsCrop = &h5007 Const PropertyTagPrintFlagsBleedWidth = &h5008 Const PropertyTagPrintFlagsBleedWidthScale = &h5009 Const PropertyTagHalftoneLPI = &h500A Const PropertyTagHalftoneLPIUnit = &h500B Const PropertyTagHalftoneDegree = &h500C Const PropertyTagHalftoneShape = &h500D Const PropertyTagHalftoneMisc = &h500E Const PropertyTagHalftoneScreen = &h500F Const PropertyTagJPEGQuality = &h5010 Const PropertyTagGridSize = &h5011 Const PropertyTagThumbnailFormat = &h5012 ' 1 = JPEG, 0 = RAW RGB Const PropertyTagThumbnailWidth = &h5013 Const PropertyTagThumbnailHeight = &h5014 Const PropertyTagThumbnailColorDepth = &h5015 Const PropertyTagThumbnailPlanes = &h5016 Const PropertyTagThumbnailRawBytes = &h5017 Const PropertyTagThumbnailSize = &h5018 Const PropertyTagThumbnailCompressedSize = &h5019 Const PropertyTagColorTransferFunction = &h501A Const PropertyTagThumbnailData = &h501B' RAW thumbnail bits in ' JPEG format or RGB format ' depends on ' PropertyTagThumbnailFormat ' Thumbnail related TAGs Const PropertyTagThumbnailImageWidth = &h5020 ' Thumbnail width Const PropertyTagThumbnailImageHeight = &h5021 ' Thumbnail height Const PropertyTagThumbnailBitsPerSample = &h5022 ' Number of bits per ' component Const PropertyTagThumbnailCompression = &h5023 ' Compression Scheme Const PropertyTagThumbnailPhotometricInterp = &h5024 ' Pixel composition Const PropertyTagThumbnailImageDescription = &h5025 ' Image Tile Const PropertyTagThumbnailEquipMake = &h5026 ' Manufacturer of Image ' Input equipment Const PropertyTagThumbnailEquipModel = &h5027 ' Model of Image input ' equipment Const PropertyTagThumbnailStripOffsets = &h5028 ' Image data location Const PropertyTagThumbnailOrientation = &h5029 ' Orientation of image Const PropertyTagThumbnailSamplesPerPixel = &h502A ' Number of components Const PropertyTagThumbnailRowsPerStrip = &h502B ' Number of rows per strip Const PropertyTagThumbnailStripBytesCount = &h502C ' Bytes per compressed ' strip Const PropertyTagThumbnailResolutionX = &h502D ' Resolution in width ' direction Const PropertyTagThumbnailResolutionY = &h502E ' Resolution in height ' direction Const PropertyTagThumbnailPlanarConfig = &h502F ' Image data arrangement Const PropertyTagThumbnailResolutionUnit = &h5030 ' Unit of X and Y ' Resolution Const PropertyTagThumbnailTransferFunction = &h5031 ' Transfer function Const PropertyTagThumbnailSoftwareUsed = &h5032 ' Software used Const PropertyTagThumbnailDateTime = &h5033 ' File change date and ' time Const PropertyTagThumbnailArtist = &h5034 ' Person who created the ' image Const PropertyTagThumbnailWhitePoint = &h5035 ' White point chromaticity Const PropertyTagThumbnailPrimaryChromaticities = &h5036 ' Chromaticities of ' primaries Const PropertyTagThumbnailYCbCrCoefficients = &h5037 ' Color space transforma- ' tion coefficients Const PropertyTagThumbnailYCbCrSubsampling = &h5038 ' Subsampling ratio of Y ' to C Const PropertyTagThumbnailYCbCrPositioning = &h5039 ' Y and C position Const PropertyTagThumbnailRefBlackWhite = &h503A ' Pair of black and white ' reference values Const PropertyTagThumbnailCopyRight = &h503B ' CopyRight holder Const PropertyTagLuminanceTable = &h5090 Const PropertyTagChrominanceTable = &h5091 Const PropertyTagFrameDelay = &h5100 Const PropertyTagLoopCount = &h5101 Const PropertyTagPixelUnit = &h5110 ' Unit specifier for pixel/unit Const PropertyTagPixelPerUnitX = &h5111 ' Pixels per unit in X Const PropertyTagPixelPerUnitY = &h5112 ' Pixels per unit in Y Const PropertyTagPaletteHistogram = &h5113 ' Palette histogram ' EXIF specific tag Const PropertyTagExifExposureTime = &h829A Const PropertyTagExifFNumber = &h829D Const PropertyTagExifExposureProg = &h8822 Const PropertyTagExifSpectralSense = &h8824 Const PropertyTagExifISOSpeed = &h8827 Const PropertyTagExifOECF = &h8828 Const PropertyTagExifVer = &h9000 Const PropertyTagExifDTOrig = &h9003 ' Date & time of original Const PropertyTagExifDTDigitized = &h9004 ' Date & time of digital data generation Const PropertyTagExifCompConfig = &h9101 Const PropertyTagExifCompBPP = &h9102 Const PropertyTagExifShutterSpeed = &h9201 Const PropertyTagExifAperture = &h9202 Const PropertyTagExifBrightness = &h9203 Const PropertyTagExifExposureBias = &h9204 Const PropertyTagExifMaxAperture = &h9205 Const PropertyTagExifSubjectDist = &h9206 Const PropertyTagExifMeteringMode = &h9207 Const PropertyTagExifLightSource = &h9208 Const PropertyTagExifFlash = &h9209 Const PropertyTagExifFocalLength = &h920A Const PropertyTagExifMakerNote = &h927C Const PropertyTagExifUserComment = &h9286 Const PropertyTagExifDTSubsec = &h9290 ' Date & Time subseconds Const PropertyTagExifDTOrigSS = &h9291 ' Date & Time original subseconds Const PropertyTagExifDTDigSS = &h9292 ' Date & TIme digitized subseconds Const PropertyTagExifFPXVer = &hA000 Const PropertyTagExifColorSpace = &hA001 Const PropertyTagExifPixXDim = &hA002 Const PropertyTagExifPixYDim = &hA003 Const PropertyTagExifRelatedWav = &hA004 ' related sound file Const PropertyTagExifInterop = &hA005 Const PropertyTagExifFlashEnergy = &hA20B Const PropertyTagExifSpatialFR = &hA20C ' Spatial Frequency Response Const PropertyTagExifFocalXRes = &hA20E ' Focal Plane X Resolution Const PropertyTagExifFocalYRes = &hA20F ' Focal Plane Y Resolution Const PropertyTagExifFocalResUnit = &hA210 ' Focal Plane Resolution Unit Const PropertyTagExifSubjectLoc = &hA214 Const PropertyTagExifExposureIndex = &hA215 Const PropertyTagExifSensingMethod = &hA217 Const PropertyTagExifFileSource = &hA300 Const PropertyTagExifSceneType = &hA301 Const PropertyTagExifCfaPattern = &hA302 Const PropertyTagGpsVer = &h0000 Const PropertyTagGpsLatitudeRef = &h0001 Const PropertyTagGpsLatitude = &h0002 Const PropertyTagGpsLongitudeRef = &h0003 Const PropertyTagGpsLongitude = &h0004 Const PropertyTagGpsAltitudeRef = &h0005 Const PropertyTagGpsAltitude = &h0006 Const PropertyTagGpsGpsTime = &h0007 Const PropertyTagGpsGpsSatellites = &h0008 Const PropertyTagGpsGpsStatus = &h0009 Const PropertyTagGpsGpsMeasureMode = &h00A Const PropertyTagGpsGpsDop = &h000B ' Measurement precision Const PropertyTagGpsSpeedRef = &h000C Const PropertyTagGpsSpeed = &h000D Const PropertyTagGpsTrackRef = &h000E Const PropertyTagGpsTrack = &h000F Const PropertyTagGpsImgDirRef = &h0010 Const PropertyTagGpsImgDir = &h0011 Const PropertyTagGpsMapDatum = &h0012 Const PropertyTagGpsDestLatRef = &h0013 Const PropertyTagGpsDestLat = &h0014 Const PropertyTagGpsDestLongRef = &h0015 Const PropertyTagGpsDestLong = &h0016 Const PropertyTagGpsDestBearRef = &h0017 Const PropertyTagGpsDestBear = &h0018 Const PropertyTagGpsDestDistRef = &h0019 Const PropertyTagGpsDestDist = &h001A Type ImageCodecInfo Clsid As CLSID FormatID As GUID CodecName As PCWSTR DllName As PCWSTR FormatDescription As PCWSTR FilenameExtension As PCWSTR MimeType As PCWSTR Flags As DWord Version As DWord SigCount As DWord SigSize As DWord SigPattern As *Byte SigMask As DWord End Type End Namespace #endif '__GDIPLUSTYPES_AB__