Documentation
¶
Index ¶
- func RegisterEXIFDecoder(d func(context.Context, []byte, bool, ...image.ReadOption) (*EXIF, error))
- func RegisterEXIFEncoder(e func(context.Context, *EXIF, bool, ...image.WriteOption) ([]byte, error))
- func RegisterICCDecoder(d func(context.Context, []byte, ...image.ReadOption) (*ICC, error))
- func RegisterICCEncoder(e func(context.Context, *ICC, ...image.WriteOption) ([]byte, error))
- func RegisterXMPDecoder(d func(context.Context, string, ...image.ReadOption) (*XMP, error))
- func RegisterXMPEncoder(e func(context.Context, *XMP, ...image.WriteOption) (string, error))
- type Core
- type EXIF
- type GUID
- type ICC
- type LanguageAlternative
- type ProfileVersion
- type Rational
- type RenditionClass
- type ResourceRef
- type Response16
- type S15Fixed16
- type U16Fixed16
- type U8Fixed8
- type XMP
- type XMPIDQ
- type XMPMediaManagement
- type XMPRights
- type XMPSpecific
- type XYZNumber
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterEXIFDecoder ¶
func RegisterEXIFEncoder ¶
func RegisterICCDecoder ¶
func RegisterICCEncoder ¶
func RegisterXMPDecoder ¶
func RegisterXMPEncoder ¶
Types ¶
type Core ¶
type Core struct {
Contributor []string
Coverage string
Creator []string
Date []time.Time
Description []LanguageAlternative
Format string // this is the mime type
Identifier string
Language []string // Really locales
Publisher []string
Relation []string
Rights []LanguageAlternative
Source string
Subject []string
Title []LanguageAlternative
Type []string
}
Things in the Dublin Core namespace
type EXIF ¶
type EXIF struct {
ImageWidth uint32 // 256
ImageHeight uint32 // 257
BitsPerSample [3]uint16 // 258
Compression uint16 // 259
PhotometricInterpretation uint16 // 262
Orientation uint16 // 274
SamplesPerPixel uint16 // 277
PlanarConfiguration uint16 // 284
YCbCrSubsampling [2]uint16 // 530
YCbCrPositioning uint16 // 531
XResolution Rational // 282
YResolution Rational // 283
ResolutionUnit uint16 // 296
TransferFunction [3][256]uint16 // 301
WhitePoint [2]Rational // 318
PrimaryChromaticities [6]Rational // 319
YCbCrCoefficient [3]Rational // 529
ReferenceBlackWhite [6]Rational // 532
DateTime *time.Time // 306
ImageDescription string // 270
Make string // 271
Model string // 272
Software string // 305
Artist string // 315
Copyright string // 33432
}
func DecodeEXIF ¶
type ICC ¶
type ICC struct {
CMMTypeSignature uint32
ProfileVersion ProfileVersion
ProfileClassSignature uint32
ColorSpace uint32
ProfileConnectionSpace uint32
ProfileCreationTime time.Time
PrimaryPlatformSignature uint32
CMMFlags uint32
DeviceManufacturer uint32
DeviceModel uint32
DeviceAttributes uint32
RenderingIntent uint32
ProfileConnectionSpaceIlluminant XYZNumber
ProfileCreatorSignature uint32
}
ICC holds an ICC color profile.
type LanguageAlternative ¶
type ProfileVersion ¶
type ProfileVersion struct {
// Major holds a BCD encoded major version number.
Major uint8
// Minor holds a BCD encoded minor and patch number. The first digit
// is the minor version while the second is the patch level.
Minor uint8
}
ProfileVersion holds a BCD encoded profile version number.
type RenditionClass ¶
type RenditionClass string
type ResourceRef ¶
type ResourceRef string
type Response16 ¶
type Response16 struct {
// Interval holds the interval value
Interval uint16
// Measurement holds the measurement value.
Measurement S15Fixed16
}
Response16 holds an iCC response16Number.
type S15Fixed16 ¶
S15Fixed16 holds a signed 32 bit fixed point number, with 1 sign bit, 15 integer bits, and 16 fractional bits.
type U16Fixed16 ¶
U16Fixed16 holds an unsigned 32 bit fixed point number with 16 integer bits and 16 fractional bits.
type U8Fixed8 ¶
type U8Fixed8 struct {
// Integer holds the unsigned 8 bit integer portion of the number.
Integer uint8
// Fraction holds the 8 bit fractional portion of the number.
Fraction uint8
}
U8Fixed8 holds an unsigned 16 bit fixed point number, with 8 integer bits and 8 fraction bits.
type XMP ¶
type XMP struct {
CoreProperties *Core
Properties *XMPSpecific
Rights *XMPRights
MediaManagement *XMPMediaManagement
IDQ *XMPIDQ
}
XMP holds the XMP metadata. It's a collection of sub-types
type XMPMediaManagement ¶
type XMPMediaManagement struct {
DerivedFrom ResourceRef
DocumentID GUID
InstanceID GUID
OriginalDocumentID GUID
RenditionClass RenditionClass
RenditionParams string
}
Things in the XMP Media Management namespace
type XMPRights ¶
type XMPRights struct {
Certificate string
Marked *bool
Owner []string
UsageTerms []LanguageAlternative
WebStatement string
}
Things in the XMP rights management namespace
type XMPSpecific ¶
type XMPSpecific struct {
CreateDate *time.Time
CreatorTool string
Identifier []string
Label string
MetadataData *time.Time
ModifiedDate *time.Time
Rating float64
}
Things in the XMP namespace
type XYZNumber ¶
type XYZNumber struct {
X S15Fixed16
Y S15Fixed16
Z S15Fixed16
}
XYZ number holds a CIE XYZ tristimulus value.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package exif encodes and decodes EXIF format image metadata.
|
Package exif encodes and decodes EXIF format image metadata. |
|
Package icc encodes and decodes ICC color profiles.
|
Package icc encodes and decodes ICC color profiles. |
|
Package xmp encodes and decodes XMP format image metadata.
|
Package xmp encodes and decodes XMP format image metadata. |