The function parameters were extended without spotting another
user with their own local prototype.
Observed as misaligned exception when using video_render.
MIPI raw 14 wasn't previously defined, so add it for completeness
To support monochrome image sensors, add formats to handle the relevant
packed data formats into the ISP, and disable demosaic.
The Bayer pipeline is still active in Bayer mode, so all 4 channels need
to be programmed with the same data for blocks such as black level and
lens shading.
Adds the equivalent to "Add option to start in burst mode if AE settings
are manual" patch to RaspiStillYUV so it too can drop straight into
capture mode.
See https://github.com/raspberrypi/userland/issues/640
The examples read the first 512 bytes of the stream and try stuffing
them into the codec as header bytes.
If running a debug build of MMAL this will fail as the extradata
field of the port format is bigger than MMAL_FORMAT_EXTRADATA_MAX_SIZE
Reduce the header bytes array down to 128bytes to match
MMAL_FORMAT_EXTRADATA_MAX_SIZE.
Both these libraries/apps were related to the VPU accessing the
host file system over VCHI. This has never been used on the Pi,
and is creating build warnings with the latest versions of gcc.
Remove them from the source tree.
Current header generates warnings of the form "warning: cast from
function call of type ‘pthread_t’ {aka ‘long unsigned int’} to
non-matching type ‘VCOS_LLTHREAD_T *’ {aka ‘struct VCOS_LLTHREAD_T *’}
[-Wbad-function-cast]". Fix that.
SET_LAUNCH_VPU (0x30013) works like SET_EXECUTE_CODE except it
runs the code on VPU1 using the QPU rpc thread. The mailbox
returns immediately, and will only fail if out of memory.
The old lens_shading parameter structures exist for backwards
compatability, but there's a new v2 version which includes a
corner_sampled flag (when the grid is sampled on cell corners rather
than centrally) and a gain_format, which allows different fractional
precision in the uint8_t values, and even a u4.10 16-bit format.
Calls through the V4L2 interface to the ISP should use the v2
style of structure.
The new 3-channel method wants 16-bit black levels whereas the single-channel method uses native sensor bit depth. This does lead to some slightly awkward code; please refer to the inline comments for the conventions used.
If exposure and analogue gain are set manually, and we run a stats
pass to setup all other control algorithms, then we can skip the
viewfinder phase and jump straight into captures, saving time over
dropped frames.
Add the relevant logic to allow this.
MMAL and video_render used not to allow the client to set the column
stride or the chroma offset.
format->es->video.width wasn't actually being used for anything as
mmal_encoding_width_to_stride returns 0 meaning the component has to
compute it.
Add an extra flag for format->flags (MMAL_ES_FORMAT_FLAG_COL_FMTS_WIDTH_IS_COL_STRIDE)
that treats format->es->video.width as the column stride instead of
being ignored.
video_render also used to ignore nSliceHeight (format->es->video.width)
on the column formats.
Adding support in setting that (via vc_image vpitch) means that you can
crop down a larger image with the chroma in a different place.
eg width=(col stride), height=2160, crop.width=1920, crop.height=1080
flags = MMAL_ES_FORMAT_FLAG_COL_FMTS_WIDTH_IS_COL_STRIDE
will display the top left 1080p image out of a 4k source image.
Need to reduce the min fps limit to 0.005 for 200s exposures
available in HQ cam.
commit 27db31a8a8 fixed this for the video
port, but we need to do the same for the stills port as well.
Add a new option (-fw) in the raspicam applications to draw
a Figure of Merit (FoM) value to indicate sharpness in the displayed
region. A larger value of FoM indicates a sharper image.
This is useful for the HQ camera to help with focussing on a subject.
This fixes infinity loop at tvservice_wait_for_reply on initialize
with older firmare. [E] No multi display support in firmware!
Checked with `tvservice --list`
The overlay_map DTB file provides a way to load different .dtbo
files on different platforms from the same overlay name, e.g.
translating "vc4-kms-v3d" to "vc4-kms-v3d-pi4" on bcm2711.
See: https://github.com/raspberrypi/linux/issues/3520
This allows the use of /dev/mem instead of /dev/vc-mem (ie it
should work on mainline kernel builds.
vcdbg needs the offset and size of memory to work.
The firmware should have inserted these into the kernel
command line as vc_mem.mem_base and vc_mem.mem_size, so libdebugsym
tries to extract those values from /proc/cmdline, or you can
provide them on the command line via -l and -s
(/dev/mem couldn't be used previously as libdebugsym tries to do
lseek(SEEK_END) to get the length, and that isn't supported by
/dev/mem).
The advanced deinterlaced algorithm wanted 16 extra lines of height on
SAND images as a scratchpad. vc_image had been hacked to add those lines
to each and every SAND image.
HEVC decode uses SAND but doesn't care about that context, and will never
support interlaced content.
Remove the +16 lines from vc_image, and add specify it as a vpitch when
creating the image from within the decoder.
The firmware's overlay application code has long supported fragments
that target other fragments, but the kernel's dynamic overlay
mechanism doesn't support them. Avoid the restriction by partially
merging overlays with themselves before handing them over to the
kernel.
The kernel's dynamic overlay mechanism does not support fragments that
target other fragments, so modify dtoverlay_merge_overlay to make it
capable of partially merging an overlay with itself. After this pass
(indicated by passing in a NULL base_dtb pointer), all intra-overlay
fragments will have been applied and made dormant.
It's useful to be able to perform the dry run on any host, not just
a Raspberry Pi with runtime overlay support, and this works once the
validity check has been removed.
Up to now, all labels have been local to overlays. It has been possible
to explicitly add labels to the base DTB, but only in a way that is
ugly and fragile - it requires knowledge of the absolute path to where
the overlay will be applied (which could vary between DTBs), and would
break if the target of a fragment was changed.
Overlay writers can now choose to explicitly export some labels by
listing them as empty properties in a first-level node called
"__exports__". For example, to export a label called "newnode", add
the following node to the overlay:
__exports__ {
newnode;
};
Make use of the new ability by replacing the deletion of the __symbols__
node with a call to dtoverlay_filter_symbols.
Give overlay writers the ability to export symbols so that they become
visible to other overlays once the overlay is applied. Symbols (labels)
for exporting should be listed as empty properties in a first-level
node called "__exports__".
The new API function dtoverlay_filter_symbols deletes non-exported
symbols, and dtoverlay_merge_overlay rewrites any exported symbols
so as to be relative to the base tree.