iptc

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2026 License: Apache-2.0 Imports: 7 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package iptc reads IPTC metadata, in the Information Interchange Model (IIM), which is a sequence of datasets, such as the title, keywords and caption of a photo, in a JPEG image or a Photoshop document

Index

Constants

View Source
const (
	// Namespace is the namespace of IPTC metadata
	Namespace = "iptc"
)

Variables

This section is empty.

Functions

func Metadata

func Metadata(datasets []Dataset) []metadata.Metadata

Metadata returns the datasets of the application record as metadata, in the iptc namespace, such as iptc:ObjectName and iptc:Keywords, which is a list when a dataset can be repeated, and the date and time the photo was created, as iptc:DateCreated. The text is UTF-8 when the envelope says so, or it's valid UTF-8, and otherwise ISO 8859-1.

Types

type Dataset

type Dataset struct {
	Record uint8
	Number uint8
	Data   []byte
}

Dataset is a dataset of IPTC metadata, which is a record, such as 2 for the application record, a number, such as 5 for the object name, and its data

func Parse

func Parse(data []byte) []Dataset

Parse returns the datasets of IPTC metadata, stopping at data which isn't a dataset, or a dataset which is cut short, so the datasets before it are returned

Jump to

Keyboard shortcuts

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