exifundefined

package
v3.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 12, 2022 License: MIT Imports: 8 Imported by: 4

README

0xa40b

The specification is not specific/clear enough to be handled. Without a working example ,we're deferring until some point in the future when either we or someone else has a better understanding.

Documentation

Index

Constants

View Source
const (
	TagUndefinedType_9101_ComponentsConfiguration_Channel_Y  = 0x1
	TagUndefinedType_9101_ComponentsConfiguration_Channel_Cb = 0x2
	TagUndefinedType_9101_ComponentsConfiguration_Channel_Cr = 0x3
	TagUndefinedType_9101_ComponentsConfiguration_Channel_R  = 0x4
	TagUndefinedType_9101_ComponentsConfiguration_Channel_G  = 0x5
	TagUndefinedType_9101_ComponentsConfiguration_Channel_B  = 0x6
)
View Source
const (
	TagUndefinedType_9101_ComponentsConfiguration_OTHER = iota
	TagUndefinedType_9101_ComponentsConfiguration_RGB   = iota
	TagUndefinedType_9101_ComponentsConfiguration_YCBCR = iota
)
View Source
const (
	TagUndefinedType_9286_UserComment_Encoding_ASCII     = iota
	TagUndefinedType_9286_UserComment_Encoding_JIS       = iota
	TagUndefinedType_9286_UserComment_Encoding_UNICODE   = iota
	TagUndefinedType_9286_UserComment_Encoding_UNDEFINED = iota
)
View Source
const (
	// UnparseableUnknownTagValuePlaceholder is the string to use for an unknown
	// undefined tag.
	UnparseableUnknownTagValuePlaceholder = "!UNKNOWN"

	// UnparseableHandledTagValuePlaceholder is the string to use for a known
	// value that is not parseable.
	UnparseableHandledTagValuePlaceholder = "!MALFORMED"
)

Variables

View Source
var (
	TagUndefinedType_9286_UserComment_Encoding_Names = map[int]string{
		TagUndefinedType_9286_UserComment_Encoding_ASCII:     "ASCII",
		TagUndefinedType_9286_UserComment_Encoding_JIS:       "JIS",
		TagUndefinedType_9286_UserComment_Encoding_UNICODE:   "UNICODE",
		TagUndefinedType_9286_UserComment_Encoding_UNDEFINED: "UNDEFINED",
	}

	TagUndefinedType_9286_UserComment_Encodings = map[int][]byte{
		TagUndefinedType_9286_UserComment_Encoding_ASCII:     {'A', 'S', 'C', 'I', 'I', 0, 0, 0},
		TagUndefinedType_9286_UserComment_Encoding_JIS:       {'J', 'I', 'S', 0, 0, 0, 0, 0},
		TagUndefinedType_9286_UserComment_Encoding_UNICODE:   {'U', 'n', 'i', 'c', 'o', 'd', 'e', 0},
		TagUndefinedType_9286_UserComment_Encoding_UNDEFINED: {0, 0, 0, 0, 0, 0, 0, 0},
	}
)
View Source
var (
	// ErrUnparseableValue is the error for a value that we should have been
	// able to parse but were not able to.
	ErrUnparseableValue = errors.New("unparseable undefined tag")
)

Functions

func Encode

func Encode(value EncodeableValue, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

Encode encodes the given encodeable undefined value to bytes.

Types

type Codec0002InteropVersion

type Codec0002InteropVersion struct {
}

func (Codec0002InteropVersion) Decode

func (Codec0002InteropVersion) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec0002InteropVersion) Encode

func (Codec0002InteropVersion) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type Codec001BGPSProcessingMethod

type Codec001BGPSProcessingMethod struct {
}

func (Codec001BGPSProcessingMethod) Decode

func (Codec001BGPSProcessingMethod) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec001BGPSProcessingMethod) Encode

func (Codec001BGPSProcessingMethod) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type Codec001CGPSAreaInformation

type Codec001CGPSAreaInformation struct {
}

func (Codec001CGPSAreaInformation) Decode

func (Codec001CGPSAreaInformation) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec001CGPSAreaInformation) Encode

func (Codec001CGPSAreaInformation) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type Codec8828Oecf

type Codec8828Oecf struct {
}

func (Codec8828Oecf) Decode

func (Codec8828Oecf) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec8828Oecf) Encode

func (Codec8828Oecf) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type Codec9000ExifVersion

type Codec9000ExifVersion struct {
}

func (Codec9000ExifVersion) Decode

func (Codec9000ExifVersion) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec9000ExifVersion) Encode

func (Codec9000ExifVersion) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type Codec927CMakerNote

type Codec927CMakerNote struct {
}

func (Codec927CMakerNote) Decode

func (Codec927CMakerNote) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec927CMakerNote) Encode

func (Codec927CMakerNote) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type Codec9286UserComment

type Codec9286UserComment struct {
}

func (Codec9286UserComment) Decode

func (Codec9286UserComment) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (Codec9286UserComment) Encode

func (Codec9286UserComment) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type CodecA000FlashpixVersion

type CodecA000FlashpixVersion struct {
}

func (CodecA000FlashpixVersion) Decode

func (CodecA000FlashpixVersion) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (CodecA000FlashpixVersion) Encode

func (CodecA000FlashpixVersion) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type CodecA20CSpatialFrequencyResponse

type CodecA20CSpatialFrequencyResponse struct {
}

func (CodecA20CSpatialFrequencyResponse) Decode

func (CodecA20CSpatialFrequencyResponse) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (CodecA20CSpatialFrequencyResponse) Encode

func (CodecA20CSpatialFrequencyResponse) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type CodecA302CfaPattern

type CodecA302CfaPattern struct {
}

func (CodecA302CfaPattern) Decode

func (CodecA302CfaPattern) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (CodecA302CfaPattern) Encode

func (CodecA302CfaPattern) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type CodecExif9101ComponentsConfiguration

type CodecExif9101ComponentsConfiguration struct {
}

func (CodecExif9101ComponentsConfiguration) Decode

func (CodecExif9101ComponentsConfiguration) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (CodecExif9101ComponentsConfiguration) Encode

func (CodecExif9101ComponentsConfiguration) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type CodecExifA300FileSource

type CodecExifA300FileSource struct {
}

func (CodecExifA300FileSource) Decode

func (CodecExifA300FileSource) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (CodecExifA300FileSource) Encode

func (CodecExifA300FileSource) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type CodecExifA301SceneType

type CodecExifA301SceneType struct {
}

func (CodecExifA301SceneType) Decode

func (CodecExifA301SceneType) Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

func (CodecExifA301SceneType) Encode

func (CodecExifA301SceneType) Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)

type EncodeableValue

type EncodeableValue interface {
	EncoderName() string
	String() string
}

EncodeableValue wraps a value with the information that will be needed to re- encode it later.

func Decode

func Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)

Decode constructs a value from raw encoded bytes

type Tag0002InteropVersion

type Tag0002InteropVersion struct {
	InteropVersion string
}

func (Tag0002InteropVersion) EncoderName

func (Tag0002InteropVersion) EncoderName() string

func (Tag0002InteropVersion) String

func (iv Tag0002InteropVersion) String() string

type Tag001BGPSProcessingMethod

type Tag001BGPSProcessingMethod struct {
	// contains filtered or unexported fields
}

func (Tag001BGPSProcessingMethod) EncoderName

func (Tag001BGPSProcessingMethod) EncoderName() string

func (Tag001BGPSProcessingMethod) String

func (gpm Tag001BGPSProcessingMethod) String() string

type Tag001CGPSAreaInformation

type Tag001CGPSAreaInformation struct {
	// contains filtered or unexported fields
}

func (Tag001CGPSAreaInformation) EncoderName

func (Tag001CGPSAreaInformation) EncoderName() string

func (Tag001CGPSAreaInformation) String

func (gai Tag001CGPSAreaInformation) String() string

type Tag8828Oecf

type Tag8828Oecf struct {
	Columns     uint16
	Rows        uint16
	ColumnNames []string
	Values      []exifcommon.SignedRational
}

func (Tag8828Oecf) EncoderName

func (oecf Tag8828Oecf) EncoderName() string

func (Tag8828Oecf) String

func (oecf Tag8828Oecf) String() string

type Tag9000ExifVersion

type Tag9000ExifVersion struct {
	ExifVersion string
}

func (Tag9000ExifVersion) EncoderName

func (Tag9000ExifVersion) EncoderName() string

func (Tag9000ExifVersion) String

func (ev Tag9000ExifVersion) String() string

type Tag927CMakerNote

type Tag927CMakerNote struct {
	MakerNoteType  []byte
	MakerNoteBytes []byte
}

func (Tag927CMakerNote) EncoderName

func (Tag927CMakerNote) EncoderName() string

func (Tag927CMakerNote) String

func (mn Tag927CMakerNote) String() string

type Tag9286UserComment

type Tag9286UserComment struct {
	EncodingType  int
	EncodingBytes []byte
}

func (Tag9286UserComment) EncoderName

func (Tag9286UserComment) EncoderName() string

func (Tag9286UserComment) String

func (uc Tag9286UserComment) String() string

type TagA000FlashpixVersion

type TagA000FlashpixVersion struct {
	FlashpixVersion string
}

func (TagA000FlashpixVersion) EncoderName

func (TagA000FlashpixVersion) EncoderName() string

func (TagA000FlashpixVersion) String

func (fv TagA000FlashpixVersion) String() string

type TagA20CSpatialFrequencyResponse

type TagA20CSpatialFrequencyResponse struct {
	Columns     uint16
	Rows        uint16
	ColumnNames []string
	Values      []exifcommon.Rational
}

func (TagA20CSpatialFrequencyResponse) EncoderName

func (TagA20CSpatialFrequencyResponse) String

type TagA302CfaPattern

type TagA302CfaPattern struct {
	HorizontalRepeat uint16
	VerticalRepeat   uint16
	CfaValue         []byte
}

func (TagA302CfaPattern) EncoderName

func (TagA302CfaPattern) EncoderName() string

func (TagA302CfaPattern) String

func (cp TagA302CfaPattern) String() string

type TagExif9101ComponentsConfiguration

type TagExif9101ComponentsConfiguration struct {
	ConfigurationId    int
	ConfigurationBytes []byte
}

func (TagExif9101ComponentsConfiguration) EncoderName

func (TagExif9101ComponentsConfiguration) String

type TagExifA300FileSource

type TagExifA300FileSource uint32
const (
	TagUndefinedType_A300_SceneType_Others                   TagExifA300FileSource = 0
	TagUndefinedType_A300_SceneType_ScannerOfTransparentType TagExifA300FileSource = 1
	TagUndefinedType_A300_SceneType_ScannerOfReflexType      TagExifA300FileSource = 2
	TagUndefinedType_A300_SceneType_Dsc                      TagExifA300FileSource = 3
)

func (TagExifA300FileSource) EncoderName

func (TagExifA300FileSource) EncoderName() string

func (TagExifA300FileSource) String

func (af TagExifA300FileSource) String() string

type TagExifA301SceneType

type TagExifA301SceneType uint32
const (
	TagUndefinedType_A301_SceneType_DirectlyPhotographedImage TagExifA301SceneType = 1
)

func (TagExifA301SceneType) EncoderName

func (TagExifA301SceneType) EncoderName() string

func (TagExifA301SceneType) String

func (st TagExifA301SceneType) String() string

type UndefinedTagHandle

type UndefinedTagHandle struct {
	IfdPath string
	TagId   uint16
}

UndefinedTagHandle defines one undefined-type tag with a corresponding decoder.

type UndefinedValueDecoder

type UndefinedValueDecoder interface {
	Decode(valueContext *exifcommon.ValueContext) (value EncodeableValue, err error)
}

UndefinedValueDecoder knows how to decode an undefined-type tag's value from bytes.

type UndefinedValueEncoder

type UndefinedValueEncoder interface {
	Encode(value interface{}, byteOrder binary.ByteOrder) (encoded []byte, unitCount uint32, err error)
}

UndefinedValueEncoder knows how to encode an undefined-type tag's value to bytes.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL