summaryrefslogtreecommitdiff
path: root/utils/gen-formats.py
AgeCommit message (Collapse)Author
2021-02-01utils: gen-formats: Support big-endian DRM formatsLaurent Pinchart
DRM 4CCs are defined in little-endian, and can be declined in a big-endian version by setting bit 31 (DRM_FORMAT_BIG_ENDIAN) in the 4CC value. Add support for such formats in the gen-formats.py script. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
2020-09-24libcamera: Move Header generation utilities to utilsKieran Bingham
Move the GPL2 utilities which handle generation of controls, formats and the top level libcamera header to the utils subtree. Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
href='#n23'>23 24 25 26 27 28 29 30
/* SPDX-License-Identifier: BSD-2-Clause */
/*
 * Copyright (C) 2019, Raspberry Pi (Trading) Limited
 *
 * device_status.h - device (image sensor) status
 */
#pragma once

// Definition of "device metadata" which stores things like shutter time and
// analogue gain that downstream control algorithms will want to know.

#ifdef __cplusplus
extern "C" {
#endif

struct DeviceStatus {
	// time shutter is open, in microseconds
	double shutter_speed;
	double analogue_gain;
	// 1.0/distance-in-metres, or 0 if unknown
	double lens_position;
	// 1/f so that brightness quadruples when this doubles, or 0 if unknown
	double aperture;
	// proportional to brightness with 0 = no flash, 1 = maximum flash
	double flash_intensity;
};

#ifdef __cplusplus
}
#endif