libcamera/include/libcamera
Laurent Pinchart d5446e9f32 libcamera: geometry: Provide in-place versions of the Size helpers
Add alignDownTo(), alignUpTo(), boundTo() and expandTo() helper
functions to the Size class. These are in-place versions of the existing
alignedDownTo(), alignedUpTo(), boundedTo() and expandedTo() functions.

The new helpers return a reference to the size, to allow chaining the
functions. One can thus write

	size.alignDownTo(16, 16).alignUpTo(32, 32)
	    .boundTo({ 40, 80 }).expandTo({ 16, 80 });

instead of

	size.alignDownTo(16, 16);
	size.alignUpTo(32, 32);
	size.boundTo({ 40, 80 });
	size.expandTo({ 16, 80 });

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
2020-07-15 17:33:54 +03:00
..
internal libcamera: PixelFormatInfo: Add functions stride and frameSize 2020-07-10 16:11:08 +09:00
ipa libcamera: ipa: raspberrypi: Plumb in the libcamera sharpness control 2020-06-25 06:47:53 +03:00
bound_method.h libcamera: Use C++14 std::*_t type traits 2020-02-18 02:15:25 +02:00
buffer.h libcamera: FrameBuffer: Add a setRequest() interface 2020-03-27 16:27:28 +01:00
camera.h libcamera: camera: Allow unspecified roles for generateConfiguration 2020-07-06 23:58:42 +01:00
camera_manager.h libcamera: camera_manager: Introduce signals when a camera is added or removed 2020-06-17 00:27:54 +03:00
control_ids.h.in libcamera: Replace C++ comments with C comments 2020-06-06 00:25:04 +03:00
controls.h libcamera: controls: Add rectangle and size control types 2020-04-28 20:44:47 +03:00
event_dispatcher.h libcamera: event_dispatcher: Add interrupt() function 2019-01-23 18:51:56 +02:00
event_notifier.h libcamera: Add parent argument to constructors of Object-derived classes 2019-08-17 18:47:17 +03:00
file_descriptor.h libcamera: file_descriptor: Implement move semantics for constructor 2020-05-19 18:07:49 +03:00
formats.h.in libcamera: Define constants for pixel formats in the public API 2020-06-18 13:26:36 +03:00
framebuffer_allocator.h libcamera: framebuffer_allocator: Lift camera restrictions on allocator 2020-03-18 19:15:18 +02:00
gen-formats.py libcamera: Define constants for pixel formats in the public API 2020-06-18 13:26:36 +03:00
gen-header.sh include: libcamera: Improve automation of libcamera.h generation 2020-03-08 19:33:59 +02:00
geometry.h libcamera: geometry: Provide in-place versions of the Size helpers 2020-07-15 17:33:54 +03:00
logging.h libcamera: logging: add syslog, stream, and nowhere logging targets 2019-07-17 14:36:35 +09:00
meson.build libcamera: Define constants for pixel formats in the public API 2020-06-18 13:26:36 +03:00
object.h libcamera: Use C++14 std::*_t type traits 2020-02-18 02:15:25 +02:00
pixel_format.h libcamera: Replace explicit DRM FourCCs with libcamera formats 2020-06-18 13:26:58 +03:00
property_ids.h.in libcamera: Replace C++ comments with C comments 2020-06-06 00:25:04 +03:00
request.h libcamera: Switch to FrameBuffer interface 2020-01-12 16:10:38 +01:00
signal.h libcamera: Use C++14 std::*_t type traits 2020-02-18 02:15:25 +02:00
span.h libcamera: Add a C++20-compliant std::span<> implementation 2020-03-06 18:08:37 +02:00
stream.h libcamera: StreamConfiguration: Add frameSize field 2020-07-10 16:11:05 +09:00
timer.h libcamera: Standardise on C compatibility headers 2019-10-23 17:39:39 +03:00
version.h.in libcamera: Rework automatic version generation to avoid rebuilds 2019-07-09 12:34:10 +03:00