Documentation ¶
Overview ¶
Package xmpdm implements the XMP Dynamic Media namespace as defined by XMP Specification Part 2.
Package xmpdm implements the XMP Dynamic Media namespace as defined by XMP Specification Part 2.
Index ¶
- Variables
- func NewModel(name string) xmp.Model
- type AlphaMode
- type AudioChannelType
- type AudioSampleType
- type BeatSpliceStretch
- type CameraAngle
- type CameraMove
- type ColorSpace
- type CuePointParam
- type CuePointParamArray
- type FieldOrder
- type FileType
- type FrameCount
- type FrameRate
- type Marker
- type MarkerList
- func (x MarkerList) Filter(types MarkerTypeList) MarkerList
- func (x MarkerList) Len() int
- func (x MarkerList) Less(i, j int) bool
- func (x MarkerList) MarshalXMP(e *xmp.Encoder, node *xmp.Node, m xmp.Model) error
- func (x *MarkerList) Sort()
- func (x MarkerList) Swap(i, j int)
- func (x MarkerList) Typ() xmp.ArrayType
- func (x *MarkerList) UnmarshalXMP(d *xmp.Decoder, node *xmp.Node, m xmp.Model) error
- type MarkerType
- type MarkerTypeList
- type MaskType
- type Media
- type MediaArray
- type MediaTime
- type MusicalKey
- type MusicalScale
- type Part
- type PartList
- type PixelDepth
- type ProjectLink
- type PullDown
- type Quality
- type RenditionClass
- type ResampleStretch
- type ShotSize
- type StretchMode
- type TimeScaleStretch
- type TimeSignature
- type Timecode
- func (x Timecode) IsZero() bool
- func (x Timecode) MarshalJSON() ([]byte, error)
- func (x Timecode) MarshalXMP(e *xmp.Encoder, node *xmp.Node, m xmp.Model) error
- func (x Timecode) String() string
- func (x *Timecode) UnmarshalJSON(data []byte) error
- func (x *Timecode) UnmarshalXMP(d *xmp.Decoder, node *xmp.Node, m xmp.Model) error
- func (x *Timecode) Unpack() error
- type TimecodeFormat
- type Track
- type TrackArray
- type VideoFrameRate
- type XmpDM
- func (x XmpDM) Can(nsName string) bool
- func (x *XmpDM) CanTag(tag string) bool
- func (x *XmpDM) GetTag(tag string) (string, error)
- func (x XmpDM) Namespaces() xmp.NamespaceList
- func (x *XmpDM) SetTag(tag, value string) error
- func (x *XmpDM) SyncFromXMP(d *xmp.Document) error
- func (x *XmpDM) SyncModel(d *xmp.Document) error
- func (x XmpDM) SyncToXMP(d *xmp.Document) error
Constants ¶
This section is empty.
Variables ¶
View Source
var (
NsXmpDM = xmp.NewNamespace("xmpDM", "http://ns.adobe.com/xmp/1.0/DynamicMedia/", NewModel)
)
Functions ¶
Types ¶
type AudioChannelType ¶
type AudioChannelType string
const ( AudioChannelTypeInvalid AudioChannelType = "" AudioChannelTypeMono AudioChannelType = "Mono" AudioChannelTypeStereo AudioChannelType = "Stereo" AudioChannelType5_1 AudioChannelType = "5.1" AudioChannelType7_1 AudioChannelType = "7.1" AudioChannelType16Ch AudioChannelType = "16 Channel" AudioChannelTypeOther AudioChannelType = "Other" )
type AudioSampleType ¶
type AudioSampleType string
const ( AudioSampleTypeInvalid AudioSampleType = "" AudioSampleType8i AudioSampleType = "8Int" AudioSampleType16i AudioSampleType = "16Int" AudioSampleType24i AudioSampleType = "24Int" AudioSampleType32i AudioSampleType = "32Int" AudioSampleType32f AudioSampleType = "32Float" AudioSampleTypeCompressed AudioSampleType = "Compressed" AudioSampleTypePacked AudioSampleType = "Packed" AudioSampleTypeOther AudioSampleType = "Other" )
type BeatSpliceStretch ¶
type BeatSpliceStretch struct { RiseInDecibel float64 `xmp:"xmpDM:riseInDecibel,attr"` RiseInTimeDuration MediaTime `xmp:"xmpDM:riseInTimeDuration"` UseFileBeatsMarker xmp.Bool `xmp:"xmpDM:useFileBeatsMarker,attr"` }
1.2.6.1 beatSpliceStretch
func (BeatSpliceStretch) IsZero ¶
func (x BeatSpliceStretch) IsZero() bool
type CameraAngle ¶
type CameraAngle string
const ( CameraAngleInvalid CameraAngle = "" CameraAngleLowAngle CameraAngle = "Low Angle" CameraAngleEyeLevel CameraAngle = "Eye Level" CameraAngleHighAngle CameraAngle = "High Angle" CameraAngleOverheadShot CameraAngle = "Overhead Shot" CameraAngleBirdsEyeShot CameraAngle = "Birds Eye Shot" CameraAngleDutchAngle CameraAngle = "Dutch Angle" CameraAnglePOV CameraAngle = "POV" CameraAngleOverTheShoulder CameraAngle = "Over the Shoulder" CameraAngleReactionShot CameraAngle = "Reaction Shot" )
type CameraMove ¶
type CameraMove string
const ( CameraMoveInvalid CameraMove = "" CameraMoveAerial CameraMove = "Aerial" CameraMoveBoomUp CameraMove = "Boom Up" CameraMoveBoomDown CameraMove = "Boom Down" CameraMoveCraneUp CameraMove = "Crane Up" CameraMoveCraneDown CameraMove = "Crane Down" CameraMoveDollyIn CameraMove = "Dolly In" CameraMoveDollyOut CameraMove = "Dolly Out" CameraMovePanLeft CameraMove = "Pan Left" CameraMovePanRight CameraMove = "Pan Right" CameraMovePedestalUp CameraMove = "Pedestal Up" CameraMovePedestalDown CameraMove = "Pedestal Down" CameraMoveTiltUp CameraMove = "Tilt Up" CameraMoveTiltDown CameraMove = "Tilt Down" CameraMoveTracking CameraMove = "Tracking" CameraMoveTruckLeft CameraMove = "Truck Left" CameraMoveTruckRight CameraMove = "Truck Right" CameraMoveZoomIn CameraMove = "Zoom In" CameraMoveZoomOut CameraMove = "Zoom Out" )
type ColorSpace ¶
type ColorSpace string
const ( ColorSpaceInvalid ColorSpace = "" ColorSpaceSRGB ColorSpace = "sRGB" ColorSpaceCCIR601 ColorSpace = "CCIR-601" ColorSpaceCCIR709 ColorSpace = "CCIR-709" )
type CuePointParam ¶
type CuePointParam struct { Key string `xmp:"xmpDM:key,attr"` Value string `xmp:"xmpDM:value,attr"` }
1.2.6.2 CuePointParam
func (CuePointParam) IsZero ¶
func (x CuePointParam) IsZero() bool
type CuePointParamArray ¶
type CuePointParamArray []CuePointParam
func (CuePointParamArray) MarshalXMP ¶
func (CuePointParamArray) Typ ¶
func (x CuePointParamArray) Typ() xmp.ArrayType
func (*CuePointParamArray) UnmarshalXMP ¶
type FieldOrder ¶
type FieldOrder string
const ( FieldOrderInvalid FieldOrder = "" FieldOrderUpper FieldOrder = "Upper" FieldOrderLower FieldOrder = "Lower" FieldOrderProgressive FieldOrder = "Progressive" )
type FrameCount ¶
1.2.6.3 FrameCount ##<FrameRate>
func (FrameCount) IsSmaller ¶
func (x FrameCount) IsSmaller(y FrameCount) bool
func (FrameCount) IsZero ¶
func (x FrameCount) IsZero() bool
func (FrameCount) MarshalText ¶
func (x FrameCount) MarshalText() ([]byte, error)
func (FrameCount) String ¶
func (x FrameCount) String() string
func (FrameCount) Sub ¶
func (x FrameCount) Sub(y FrameCount) FrameCount
func (*FrameCount) UnmarshalText ¶
func (x *FrameCount) UnmarshalText(data []byte) error
type FrameRate ¶
1.2.6.4 FrameRate "f###" "f###s###"
func (FrameRate) MarshalText ¶
func (*FrameRate) UnmarshalText ¶
type Marker ¶
type Marker struct { Comment string `xmp:"xmpDM:comment,attr"` CuePointParams CuePointParamArray `xmp:"xmpDM:cuePointParams"` CuePointType string `xmp:"xmpDM:cuePointType,attr"` Duration FrameCount `xmp:"xmpDM:duration,attr"` Location xmp.Uri `xmp:"xmpDM:location"` Name string `xmp:"xmpDM:name,attr"` Probability float64 `xmp:"xmpDM:probability,attr"` Speaker string `xmp:"xmpDM:speaker,attr"` StartTime FrameCount `xmp:"xmpDM:startTime,attr"` Target string `xmp:"xmpDM:target,attr"` Types MarkerTypeList `xmp:"xmpDM:type"` }
1.2.6.5 Marker
type MarkerList ¶
type MarkerList []Marker
func (MarkerList) Filter ¶
func (x MarkerList) Filter(types MarkerTypeList) MarkerList
func (MarkerList) Len ¶
func (x MarkerList) Len() int
func (MarkerList) Less ¶
func (x MarkerList) Less(i, j int) bool
func (MarkerList) MarshalXMP ¶
func (*MarkerList) Sort ¶
func (x *MarkerList) Sort()
func (MarkerList) Swap ¶
func (x MarkerList) Swap(i, j int)
func (MarkerList) Typ ¶
func (x MarkerList) Typ() xmp.ArrayType
func (*MarkerList) UnmarshalXMP ¶
type MarkerType ¶
type MarkerType string
const ( MarkerTypeInvalid MarkerType = "" // implementation internal MarkerTypeChapter MarkerType = "Chapter" // XMP DM MarkerTypeCue MarkerType = "Cue" // XMP DM MarkerTypeIndex MarkerType = "Index" // XMP DM MarkerTypeSpeech MarkerType = "Speech" // XMP DM MarkerTypeTrack MarkerType = "Track" // XMP DM MarkerTypeIptcDuration MarkerType = "ivqu:editorialDuration" // IPTC Video Metadata Nov 2016 MarkerTypeIptcStart MarkerType = "ivqu:editorialDurationStart" // IPTC Video Metadata Nov 2016 MarkerTypeIptcEnd MarkerType = "ivqu:editorialDurationEnd" // IPTC Video Metadata Nov 2016 )
type MarkerTypeList ¶
type MarkerTypeList []MarkerType
func (MarkerTypeList) Contains ¶
func (x MarkerTypeList) Contains(t MarkerType) bool
func (MarkerTypeList) Intersect ¶
func (x MarkerTypeList) Intersect(y MarkerTypeList) MarkerTypeList
type Media ¶
type Media struct { Duration MediaTime `xmp:"xmpDM:duration"` Managed xmp.Bool `xmp:"xmpDM:managed,attr"` Path xmp.Uri `xmp:"xmpDM:path,attr"` StartTime MediaTime `xmp:"xmpDM:startTime"` Track string `xmp:"xmpDM:track,attr"` WebStatement xmp.Uri `xmp:"xmpDM:webStatement"` }
1.2.6.6 Media
type MediaArray ¶
type MediaArray []Media
func (MediaArray) MarshalXMP ¶
func (MediaArray) Typ ¶
func (x MediaArray) Typ() xmp.ArrayType
func (*MediaArray) UnmarshalXMP ¶
type MediaTime ¶
type MediaTime struct { Scale xmp.Rational `xmp:"xmpDM:scale,attr"` Value int64 `xmp:"xmpDM:value,attr"` }
1.2.6.9 Time
type MusicalKey ¶
type MusicalKey string
const ( MusicalKeyInvalid MusicalKey = "" MusicalKeyC MusicalKey = "C" MusicalKeyC_ MusicalKey = "C#" MusicalKeyD MusicalKey = "D" MusicalKeyD_ MusicalKey = "D#" MusicalKeyE MusicalKey = "E" MusicalKeyF MusicalKey = "F" MusicalKeyF_ MusicalKey = "F#" MusicalKeyG MusicalKey = "G" MusicalKeyG_ MusicalKey = "G#" MusicalKeyA MusicalKey = "A" MusicalKeyA_ MusicalKey = "A#" MusicalKeyB MusicalKey = "B" )
type MusicalScale ¶
type MusicalScale string
const ( MusicalScaleInvalid MusicalScale = "" MusicalScaleMajor MusicalScale = "Major" MusicalScaleMinor MusicalScale = "Minor" MusicalScaleBoth MusicalScale = "Both" MusicalScaleNeither MusicalScale = "Neither" )
type Part ¶
type Part struct { Path string Start FrameCount Duration FrameCount }
1.2.3.1 Part [/]time:## - duration from node=0 [/]time:##d## - duration from given node [/]time:##r## - range from given node to end
## is FrameCount
func (Part) MarshalText ¶
func (Part) MarshalXMP ¶
func (*Part) UnmarshalText ¶
type PartList ¶
type PartList []Part
func NewPartList ¶
func (PartList) MarshalText ¶
func (*PartList) UnmarshalText ¶
type PixelDepth ¶
type PixelDepth string
const ( PixelDepthInvalid PixelDepth = "" PixelDepth8 PixelDepth = "8Int" PixelDepth16 PixelDepth = "16Int" PixelDepth24 PixelDepth = "24Int" PixelDepth32 PixelDepth = "32Int" PixelDepth32f PixelDepth = "32Float" PixelDepthOther PixelDepth = "Other" )
type ProjectLink ¶
1.2.6.7 ProjectLink
func (ProjectLink) IsZero ¶
func (x ProjectLink) IsZero() bool
type PullDown ¶
type PullDown string
const ( PullDownInvalid PullDown = "" PullDownWSSWW PullDown = "WSSWW" PullDownSSWWW PullDown = "SSWWW" PullDownSWWWS PullDown = "SWWWS" PullDownWWWSS PullDown = "WWWSS" PullDownWWSSW PullDown = "WWSSW" PullDownWWWSW PullDown = "WWWSW" PullDownWWSWW PullDown = "WWSWW" PullDownWSWWW PullDown = "WSWWW" PullDownSWWWW PullDown = "SWWWW" PullDownWWWWS PullDown = "WWWWS" )
type RenditionClass ¶
type RenditionClass string
Part 1: 8.2.2.8 RenditionClass
const ( RenditionClassInvalid RenditionClass = "" RenditionClassDefault RenditionClass = "default" RenditionClassDraft RenditionClass = "draft" RenditionClassLowRes RenditionClass = "low-res" RenditionClassProof RenditionClass = "proof" RenditionClassScreen RenditionClass = "screen" RenditionClassThumbnail RenditionClass = "thumbnail" )
type ResampleStretch ¶
type ResampleStretch struct {
Quality Quality `xmp:"xmpDM:quality,attr"`
}
1.2.6.8 resampleStretch
func (ResampleStretch) IsZero ¶
func (x ResampleStretch) IsZero() bool
type ShotSize ¶
type ShotSize string
const ( ShotSizeInvalid ShotSize = "" // implementation internal ShotSizeECU ShotSize = "ECU" // extreme close-up ShotSizeMCU ShotSize = "MCU" // medium close-up ShotSizeCU ShotSize = "CU" // close-up ShotSizeMS ShotSize = "MS" // medium shot ShotSizeWS ShotSize = "WS" // wide shot ShotSizeMWS ShotSize = "MWS" // medium wide shot ShotSizeEWS ShotSize = "EWS" // extreme wide shot )
type StretchMode ¶
type StretchMode string
const ( StretchModeInvalid StretchMode = "" StretchModeFixedLength StretchMode = "Fixed length" StretchModeTimeScale StretchMode = "Time-Scale" StretchModeResample StretchMode = "Resample" StretchModeBeatSplice StretchMode = "Beat Splice" StretchModeHybrid StretchMode = "Hybrid" )
type TimeScaleStretch ¶
type TimeScaleStretch struct { Overlap float64 `xmp:"xmpDM:frameOverlappingPercentage,attr"` FrameSize float64 `xmp:"xmpDM:frameSize,attr"` Quality Quality `xmp:"xmpDM:quality,attr"` }
1.2.6.11 timeScaleStretch
func (TimeScaleStretch) IsZero ¶
func (x TimeScaleStretch) IsZero() bool
type TimeSignature ¶
type TimeSignature string
const ( TimeSignatureInvalid TimeSignature = "" TimeSignature2_4 TimeSignature = "2/4" TimeSignature3_4 TimeSignature = "3/4" TimeSignature4_4 TimeSignature = "4/4" TimeSignature5_4 TimeSignature = "5/4" TimeSignature7_4 TimeSignature = "7/4" TimeSignature6_8 TimeSignature = "6/8" TimeSignature9_8 TimeSignature = "9/8" TimeSignature12_8 TimeSignature = "12/8" )
type Timecode ¶
type Timecode struct { Format TimecodeFormat `xmp:"xmpDM:timeFormat"` Value string `xmp:"xmpDM:timeValue"` // hh:mm:ss:ff or hh;mm;ss;ff H int `xmp:"-"` M int `xmp:"-"` S int `xmp:"-"` F int `xmp:"-"` IsDropFrame bool `xmp:"-"` }
func (Timecode) MarshalJSON ¶
func (Timecode) MarshalXMP ¶
func (*Timecode) UnmarshalJSON ¶
func (*Timecode) UnmarshalXMP ¶
type TimecodeFormat ¶
type TimecodeFormat string
const ( TimecodeFormatInvalid TimecodeFormat = "" TimecodeFormat24 TimecodeFormat = "24Timecode" TimecodeFormat25 TimecodeFormat = "25Timecode" TimecodeFormat2997 TimecodeFormat = "2997DropTimecode" // (semicolon delimiter) TimecodeFormat2997ND TimecodeFormat = "2997NonDropTimecode" TimecodeFormat30 TimecodeFormat = "30Timecode" TimecodeFormat50 TimecodeFormat = "50Timecode" TimecodeFormat5994 TimecodeFormat = "5994DropTimecode" // (semicolon delimiter) TimecodeFormat5994ND TimecodeFormat = "5994NonDropTimecode" TimecodeFormat60 TimecodeFormat = "60Timecode" TimecodeFormat23976 TimecodeFormat = "23976Timecode" )
func ParseTimecodeFormat ¶
func ParseTimecodeFormat(f float64, isdrop bool) TimecodeFormat
type Track ¶
type Track struct { FrameRate FrameRate `xmp:"xmpDM:frameRate,attr"` Markers MarkerList `xmp:"xmpDM:markers"` Name string `xmp:"xmpDM:trackName,attr"` Type MarkerTypeList `xmp:"xmpDM:trackType,attr"` }
1.2.6.12 Track
type TrackArray ¶
type TrackArray []Track
func (TrackArray) MarshalXMP ¶
func (TrackArray) Typ ¶
func (x TrackArray) Typ() xmp.ArrayType
func (*TrackArray) UnmarshalXMP ¶
type VideoFrameRate ¶
type VideoFrameRate float64
func (*VideoFrameRate) UnmarshalText ¶
func (x *VideoFrameRate) UnmarshalText(data []byte) error
type XmpDM ¶
type XmpDM struct { AbsPeakAudioFilePath string `xmp:"xmpDM:absPeakAudioFilePath"` Album string `xmp:"xmpDM:album"` AltTapeName string `xmp:"xmpDM:altTapeName"` AltTimecode Timecode `xmp:"xmpDM:altTimecode"` Artist string `xmp:"xmpDM:artist"` AudioChannelType AudioChannelType `xmp:"xmpDM:audioChannelType"` AudioCompressor string `xmp:"xmpDM:audioCompressor"` AudioSampleRate float64 `xmp:"xmpDM:audioSampleRate"` AudioSampleType AudioSampleType `xmp:"xmpDM:audioSampleType"` BeatSpliceParams BeatSpliceStretch `xmp:"xmpDM:beatSpliceParams"` CameraAngle CameraAngle `xmp:"xmpDM:cameraAngle"` CameraLabel string `xmp:"xmpDM:cameraLabel"` CameraModel string `xmp:"xmpDM:cameraModel"` CameraMove CameraMove `xmp:"xmpDM:cameraMove"` Client string `xmp:"xmpDM:client"` Comment string `xmp:"xmpDM:comment"` Composer string `xmp:"xmpDM:composer"` ContributedMedia MediaArray `xmp:"xmpDM:contributedMedia"` Director string `xmp:"xmpDM:director"` DirectorPhotography string `xmp:"xmpDM:directorPhotography"` Duration MediaTime `xmp:"xmpDM:duration"` Engineer string `xmp:"xmpDM:engineer"` FileDataRate xmp.Rational `xmp:"xmpDM:fileDataRate"` Genre string `xmp:"xmpDM:genre"` Good xmp.Bool `xmp:"xmpDM:good"` Instrument string `xmp:"xmpDM:instrument"` IntroTime MediaTime `xmp:"xmpDM:introTime"` Key MusicalKey `xmp:"xmpDM:key"` LogComment string `xmp:"xmpDM:logComment"` Loop xmp.Bool `xmp:"xmpDM:loop"` NumberOfBeats float64 `xmp:"xmpDM:numberOfBeats"` Markers MarkerList `xmp:"xmpDM:markers"` OutCue MediaTime `xmp:"xmpDM:outCue"` ProjectName string `xmp:"xmpDM:projectName"` ProjectRef ProjectLink `xmp:"xmpDM:projectRef"` PullDown PullDown `xmp:"xmpDM:pullDown"` RelativePeakAudioFilePath xmp.Uri `xmp:"xmpDM:relativePeakAudioFilePath"` RelativeTimestamp MediaTime `xmp:"xmpDM:relativeTimestamp"` ReleaseDate xmp.Date `xmp:"xmpDM:releaseDate"` ResampleParams ResampleStretch `xmp:"xmpDM:resampleParams"` ScaleType MusicalScale `xmp:"xmpDM:scaleType"` Scene string `xmp:"xmpDM:scene"` ShotDate xmp.Date `xmp:"xmpDM:shotDate"` ShotDay string `xmp:"xmpDM:shotDay"` ShotLocation string `xmp:"xmpDM:shotLocation"` ShotName string `xmp:"xmpDM:shotName"` ShotNumber string `xmp:"xmpDM:shotNumber"` ShotSize ShotSize `xmp:"xmpDM:shotSize"` SpeakerPlacement string `xmp:"xmpDM:speakerPlacement"` StartTimecode Timecode `xmp:"xmpDM:startTimecode"` StretchMode StretchMode `xmp:"xmpDM:stretchMode"` TakeNumber int `xmp:"xmpDM:takeNumber"` TapeName string `xmp:"xmpDM:tapeName"` Tempo float64 `xmp:"xmpDM:tempo"` TimeScaleParams TimeScaleStretch `xmp:"xmpDM:timeScaleParams"` TimeSignature TimeSignature `xmp:"xmpDM:timeSignature"` TrackNumber int `xmp:"xmpDM:trackNumber"` Tracks TrackArray `xmp:"xmpDM:Tracks"` VideoAlphaMode AlphaMode `xmp:"xmpDM:videoAlphaMode"` VideoAlphaPremultipleColor xmptpg.Colorant `xmp:"xmpDM:videoAlphaPremultipleColor"` VideoAlphaUnityIsTransparent xmp.Bool `xmp:"xmpDM:videoAlphaUnityIsTransparent"` VideoColorSpace ColorSpace `xmp:"xmpDM:videoColorSpace"` VideoCompressor string `xmp:"xmpDM:videoCompressor"` VideoFieldOrder FieldOrder `xmp:"xmpDM:videoFieldOrder"` VideoFrameRate VideoFrameRate `xmp:"xmpDM:videoFrameRate"` VideoFrameSize xmptpg.Dimensions `xmp:"xmpDM:videoFrameSize"` VideoPixelDepth PixelDepth `xmp:"xmpDM:videoPixelDepth"` VideoPixelAspectRatio xmp.Rational `xmp:"xmpDM:videoPixelAspectRatio"` PartOfCompilation xmp.Bool `xmp:"xmpDM:partOfCompilation"` Lyrics string `xmp:"xmpDM:lyrics"` DiscNumber int `xmp:"xmpDM:discNumber"` // not found in XMP spec, but in files StartTimeScale int `xmp:"xmpDM:startTimeScale"` // "24" StartTimeSampleSize int `xmp:"xmpDM:startTimeSampleSize"` // "1" }
func (XmpDM) Namespaces ¶
func (x XmpDM) Namespaces() xmp.NamespaceList
Click to show internal directories.
Click to hide internal directories.