mirror of
https://git.libcamera.org/libcamera/libcamera.git
synced 2025-07-13 15:29:45 +03:00
libcamera: utils: Add hex stream output helper
Add a utils::hex() function that simplifies writing hexadecimal values to an ostream. The function handles the '0x' prefix, the field width and the fill character automatically. Use it through the libcamera code base, and add a test. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
This commit is contained in:
parent
ce739e616c
commit
f391048a7b
11 changed files with 147 additions and 22 deletions
|
@ -640,7 +640,7 @@ int CameraDevice::configureStreams(camera3_stream_configuration_t *stream_list)
|
|||
<< ", direction: " << stream->stream_type
|
||||
<< ", width: " << stream->width
|
||||
<< ", height: " << stream->height
|
||||
<< ", format: " << std::hex << stream->format;
|
||||
<< ", format: " << utils::hex(stream->format);
|
||||
}
|
||||
|
||||
/* Hardcode viewfinder role, collecting sizes from the stream config. */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue