Exemple #1
0
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// Package modi provides tiff extensions for working with Microsoft Office
// Document Imaging based tiff files.
package modi

import "github.com/google/tiff"

var modiTags = tiff.NewTagSet("MODI", 32768, 65535)

func init() {
	modiTags.Register(tiff.NewTag(37679, "MODIText", nil))
	modiTags.Register(tiff.NewTag(37680, "MODIOLEPropertySetStorage", nil))
	modiTags.Register(tiff.NewTag(37681, "MODIPositioning", nil))

	modiTags.Lock()

	tiff.DefaultTagSpace.RegisterTagSet(modiTags)
}
Exemple #2
0
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package dng

import "github.com/google/tiff"

var (
	DNGv1_0_0_0Tags = tiff.NewTagSet("DNGv1.0.0.0", 32768, 65535)
	DNGv1_1_0_0Tags = tiff.NewTagSet("DNGv1.1.0.0", 32768, 65535)
	DNGv1_2_0_0Tags = tiff.NewTagSet("DNGv1.2.0.0", 32768, 65535)
	DNGv1_3_0_0Tags = tiff.NewTagSet("DNGv1.3.0.0", 32768, 65535)
	DNGv1_4_0_0Tags = tiff.NewTagSet("DNGv1.4.0.0", 32768, 65535)
)

func init() {
	// Original tags for Version 1.0.0.0
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50706, "DNGVersion", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50707, "DNGBackwardVersion", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50708, "UniqueCameraModel", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50709, "LocalizedCameraModel", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50710, "CFAPlaneColor", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50711, "CFALayout", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50712, "LinearizationTable", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50713, "BlackLevelRepeatDim", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50714, "BlackLevel", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50715, "BlackLevelDeltaH", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50716, "BlackLevelDeltaV", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50717, "WhiteLevel", nil))
	DNGv1_0_0_0Tags.Register(tiff.NewTag(50718, "DefaultScale", nil))
Exemple #3
0
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package exif

import (
	"math/big"

	"github.com/google/tiff"
)

const GPSIFDTagID = 34853

var (
	gpsTags     = tiff.NewTagSet("GPS", 0, 65535)
	GPSTagSpace = tiff.NewTagSpace("GPS")
	gpsIFDTag   = tiff.NewTag(GPSIFDTagID, "GPSIFD", nil)
)

func init() {
	tiff.PrivateTags.Register(gpsIFDTag)

	// http://www.awaresystems.be/imaging/tiff/tifftags/privateifd/gps.html
	// http://www.exiv2.org/tags.html
	gpsTags.Register(tiff.NewTag(0, "GPSVersionID", nil))
	gpsTags.Register(tiff.NewTag(1, "GPSLatitudeRef", nil))
	gpsTags.Register(tiff.NewTag(2, "GPSLatitude", nil))
	gpsTags.Register(tiff.NewTag(3, "GPSLongitudeRef", nil))
	gpsTags.Register(tiff.NewTag(4, "GPSLongitude", nil))
	gpsTags.Register(tiff.NewTag(5, "GPSAltitudeRef", nil))
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package nikon

import "github.com/google/tiff"

var (
	MakerNoteTags     = tiff.NewTagSet("NikonMakerNote", 0, 65535)
	MakerNoteTagSpace = tiff.NewTagSpace("NikonMakerNote")
)

func init() {
	// Tag 0
	MakerNoteTags.Register(tiff.NewTag(1, "Version", nil))
	MakerNoteTags.Register(tiff.NewTag(2, "ISOSpeed", nil))
	MakerNoteTags.Register(tiff.NewTag(3, "ColorMode", nil))
	MakerNoteTags.Register(tiff.NewTag(4, "Quality", nil))
	MakerNoteTags.Register(tiff.NewTag(5, "WhiteBalance", nil))
	MakerNoteTags.Register(tiff.NewTag(6, "Sharpening", nil))
	MakerNoteTags.Register(tiff.NewTag(7, "FocusMode", nil))
	MakerNoteTags.Register(tiff.NewTag(8, "FlashSetting", nil))
	MakerNoteTags.Register(tiff.NewTag(9, "FlashDevice", nil))
	// Tag 10
	MakerNoteTags.Register(tiff.NewTag(11, "WhiteBalanceFineTune", nil))
	MakerNoteTags.Register(tiff.NewTag(12, "WB_RBLevels", nil))
	MakerNoteTags.Register(tiff.NewTag(13, "ProgramShift", nil))
	MakerNoteTags.Register(tiff.NewTag(14, "ExposureDifference", nil))
	MakerNoteTags.Register(tiff.NewTag(15, "ISOSelection", nil))
	MakerNoteTags.Register(tiff.NewTag(16, "DataDump", nil))
Exemple #5
0
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package geotiff

import "github.com/google/tiff"

var geotiffTags = tiff.NewTagSet("GeoTIFF", 32768, 65535)

func init() {
	geotiffTags.Register(tiff.NewTag(33550, "ModelPixelScaleTag", nil))
	geotiffTags.Register(tiff.NewTag(34264, "ModelTransformationTag", nil))
	geotiffTags.Register(tiff.NewTag(33922, "ModelTiepointTag", nil))
	geotiffTags.Register(tiff.NewTag(34735, "GeoKeyDirectoryTag", nil))
	geotiffTags.Register(tiff.NewTag(34736, "GeoDoubleParamsTag", nil))
	geotiffTags.Register(tiff.NewTag(34737, "GeoAsciiParamsTag", nil))
	geotiffTags.Register(tiff.NewTag(33920, "IntergraphIrasBMatrixTag", nil))

	geotiffTags.Lock()

	tiff.DefaultTagSpace.RegisterTagSet(geotiffTags)
}
Exemple #6
0
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package tiffep

import "github.com/google/tiff"

var tiffEPTags = tiff.NewTagSet("TIFF/EP", 32768, 65535)

func init() {
	tiffEPTags.Register(tiff.NewTag(33421, "CFARepeatPatternDim", nil))
	tiffEPTags.Register(tiff.NewTag(33422, "CFAPattern", nil))
	tiffEPTags.Register(tiff.NewTag(34859, "SelfTimeMode", nil))
	tiffEPTags.Register(tiff.NewTag(37390, "FocalPlaneXResolution", nil))
	tiffEPTags.Register(tiff.NewTag(37391, "FocalPlaneYResolution", nil))
	tiffEPTags.Register(tiff.NewTag(37392, "FocalPlaneResolutionUnit", nil))
	tiffEPTags.Register(tiff.NewTag(37398, "TIFF/EPStandardID", nil))
	tiffEPTags.Register(tiff.NewTag(37399, "SensingMethod", nil))

	tiffEPTags.Lock()

	tiff.DefaultTagSpace.RegisterTagSet(tiffEPTags)
}
Exemple #7
0
// Copyright 2016 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package exif

import "github.com/google/tiff"

const InteroperabilityIFDTagID = 40965

var (
	iopTags     = tiff.NewTagSet("Interoperability", 0, 65535)
	IOPTagSpace = tiff.NewTagSpace("Interoperability")
	iopIFDTag   = tiff.NewTag(InteroperabilityIFDTagID, "InteroperabilityIFD", nil)
)

func init() {
	tiff.PrivateTags.Register(iopIFDTag)

	// http://www.exiv2.org/tags.html
	iopTags.Register(tiff.NewTag(1, "InteroperabilityIndex", nil))
	iopTags.Register(tiff.NewTag(2, "InteroperabilityVersion", nil))
	iopTags.Register(tiff.NewTag(4096, "RelatedImageFileFormat", nil))
	iopTags.Register(tiff.NewTag(4097, "RelatedImageWidth", nil))
	iopTags.Register(tiff.NewTag(4098, "RelatedImageLength", nil))

	iopTags.Lock()

	IOPTagSpace.RegisterTagSet(iopTags)
	tiff.RegisterTagSpace(IOPTagSpace)
}
Exemple #8
0
	"github.com/google/tiff"
)

/*
http://www.awaresystems.be/imaging/tiff/tifftags/privateifd/exif.html
http://www.exiv2.org/tags.html
http://www.cipa.jp/exifprint/index_e.html
http://www.cipa.jp/std/documents/e/DC-008-2012_E.pdf
http://www.cipa.jp/std/documents/e/DC-008-Translation-2016-E.pdf
http://www.jeita.or.jp/cgi-bin/standard_e/list.cgi?cateid=1&subcateid=4
*/

const ExifIFDTagID = 34665

var (
	exifTags     = tiff.NewTagSet("Exif", 0, 65535)
	ExifTagSpace = tiff.NewTagSpace("Exif")
	exifIFDTag   = tiff.NewTag(ExifIFDTagID, "ExifIFD", nil)
)

/*
TODO: Break up these exif tags into sets based on the exif version.  They
still all likely belong in the same space though.  For an example, take
a look at the way DNG was broken up.  Tags introduced in newer versions
are added to a set named for the version.  They still all get put into
the same space, just the sets are identified separately.
*/

/*
TODO: Break up tags into categories
From TIFF: