head 1.2; access; symbols pkgsrc-2026Q1:1.2.0.6 pkgsrc-2026Q1-base:1.2 pkgsrc-2025Q4:1.2.0.4 pkgsrc-2025Q4-base:1.2 pkgsrc-2025Q3:1.2.0.2 pkgsrc-2025Q3-base:1.2 pkgsrc-2025Q2:1.1.0.4 pkgsrc-2025Q2-base:1.1 pkgsrc-2025Q1:1.1.0.2 pkgsrc-2025Q1-base:1.1; locks; strict; comment @// @; 1.2 date 2025.07.07.05.15.26; author wiz; state Exp; branches; next 1.1; commitid wcVX5TfvRCX20M1G; 1.1 date 2025.02.07.21.57.08; author wiz; state Exp; branches; next ; commitid uRbaTdeeqjiImAIF; desc @@ 1.2 log @opencv*: update to 4.12.0 Summer update for OpenCV 4.x Core Module: Added user-defined logger callback #27154 Added reinterpret() method to cv::Mat #25394 Fixed empty ND-array construction #27362 Fixed bug with int64 support for FileStorage #26846 Fixed cv::meanStdDev overflow for large images #26867 Useed HAL for cv::mean function too #26895 Vectorized cv::normalize / cv::norm #26885 Enabled SIMD_SCALABLE for exp and sqrt #26886 vectorized normDiff with universal intrinsics #27042 Refactored normDiff in hal_rvv and extended with support of more data types #27115 Further vectorized copyTo with mask #27145 Fix POWN OpenCL implementation #27274 Restored legacy universal intrinsics operators in a separate header #27327 Improved solveCubuc accuracy: #27331, #27347 Deprecated copyData Parameter in cv::UMat construction from std::vector and always copy data #27408 Imgproc Module: Optimized and reduced memory consumption in cv::findContours #26690, #26834 Fixed integer overflow in cv::HoughLinesProbabilistic with very large input images #26744 Fixed several potential overflows in image warping #26765, #26776 Improved robustness for ellipse fitting #26773 Added cv::THRESH_DRYRUN flag to get adaptive threshold values without input thresholding #26836 Fixed cv::getPerspectiveTransform for singular case #26926 Optimized bayer2Gray with universal intrinsics #26868 Added optional mask to cv::threshold #26842 Accelerated cv::remap calculation with multi-threading, when cv::WARP_INVERSE_MAP is used #27108 Reworked HSV color conversion tables initialization in OpenCL branch to fix possible data raise #27287 Fixed bilateral filter's sigma color and sigma space issue #27309 Impoved performance of medianblur #27299 Added cv::getClosestEllipsePoints function to get the closest point on an ellipse #26299 Corrected IPP implementation for cv::distanceTransform results with single thread #27432 Fixed cv::matchTemplate with mask crash #26703 Added diamond structuring element to morphology operations #27441, #27492 Improved cv::intersectConvexConvex accuracy in corner cases #26974 Calib3d module: Fixed inliers updating in homography estimation #26742 Added cv::solvePnPRansac implementation for the fisheye camera model #26669 Fixed different marker ordering with cv::findChessboardCornersSBWithMeta and cv::CALIB_CB_LARGER flag. Fixed logical mistake in FilterSpecklesImpl #26996 Optimized undistort points for the fisheye camera model #26988 Optimized new camera matrix estimation and some related functions #27001 Added warning if projected axes are out of camera frame in cv::drawAxes function #27311 Added image dimension check to avoid StereoSGBM non-determinism #27305 Fixed bugs in SQPNP orthogonalization and simplified column vectors copying #27437 DNN Module: Added TFLite StridedSllice (without strides but just Slice) and enable strides for TF importers #27273 Added fusion handler of conv+eltwise in case of multi-output node (i.e. Split) #27326 Added new ops import in TFLite parser: SUB, SQRT, DIV, NEG, SQUARED_DIFFERENCE, SUM #27307 Fxied scalars and 1d tensors support in TFLite parser #27307 Reduced mumber of NHWC<->NCHW conversions in TFLite parser #27307 Added checks before getting latest pin in Net::Impl::getLatestLayerPin #27353 Added OpenVINO NPU support #27363 Added more operations to CANN backend #24756 Objdetect module: Extend ArUcoDetector to run multiple dictionaries in an efficient manner #26934. Fixed rotated aruco marker board generation #26753 Fixed incorrect Aruco marker detection near image edge #26968 Fixed invalid vector access in QR de/encoder #26532 Fix QR code encoder with auto version #27244 Aded QRCode ECI encoding support #24426, #27486 Made ChAruco board consistency check optional #26824 Photo Module: Added 16-bit support to cv::fastNlMeansDenoising and updated tests #26831 Local decolor pipeline optimization #27041 Fixed Triangle Weights used by Debevec algorithm being non zero at extremes #27270 Fixed NaNs in HDR Triangle Weights and Tonemapping and Update LDR Ground Truth in tutorial #27396 VideoIO Module: Fixed invalid custom FFmpeg options handling provided with environment variable #26793 Fixed default cv::CAP_PROP_ORIENTATION_ATUO behaviour #26800 Improved camera opening performance when with DShow backed, if custom options are provided #26601 Added zoom support into Android native camera capture #26837 Fixed V4L frame size for non-BGR output #27193 Added Orbbec Gemini 330 camera support #27230 Fixed cv::VideoWriter failure on writing colorless images #27153 Fixed Android setCameraIndex issue #27419 Imgcodecs: Extended image I/O API with metadata support #27499 Added in-memory animation encoding and decoding #27013 Added hidden frame support for Animated PNG #27127 Added GIF decode and encode for imgcodecs #25691, #26971, #26859, #26738, #26930, #27081, #27138, #27296 Added animated WebP Support #25608, #27457 Added GDAL multi-channel support #27458 Fixed AVIF linkage on Windows #26762 Significantly improved PNG and Animated PNG files handing #26849, #26739, #26748, #26782, #26832, #26835, #26848, #26851, #26854, #26915, #27040, #27087, #27297 Added several fixes for libspng integration #27314 Fixed memory leak in JpegXL decoder #26787 Added support for cv::IMREAD_UNCHANGED and other ImreadFlags into JpegXL implementation #26788 Implemented imdecode() for JpegXL to directly read from memory #26844 Added lossless compression support for JpegXL #27384 Fixed cv::imread() implementation for 16-bit png with libspng back-end #27113 Highgui Module: displayOverlay doesn't disappear after timeout #27082 Fix closing of windows when using the Qt backend #27170 Fixed QT window resize regression #27282 G-API module: Workaround for successfull append of OpenVINO Execution Provider: Moved creation of 'Ort::Env' before it #26983 Adding AddRgbFeature(), and improving robustness in ComputeRgbDistance #26682 Added MS Media Foundation availability check in G-API too #27355 Video Module: Added trackers factory with pre-loaded dnn models #26875 HAL: Extracted HAL implementations as dedicated folder #27252. Implemented new HAL for RISC-V RVV 1.0 platforms, see all changes by query Refactored OpenVX implementation as HAL #26903, #26911, #26907. Partially refactored Intel IPP integration as HAL #26880, #27125, #27128, #27194, #27213, #27346. Further IPP conversion will be continued in the next releases Fixed HALs dependency from thre cv namespace #26878 Updated KleidiCV HAL for ARM to version 0.5 Extended FastCV HAL for Qualcomm platforms #27217, #27216, #27184, #27182, #27033 Added new HAL entries for cv::sum #27346, copyTo with mask #27162, cv::DFT and cv::DCT variations #26865, convert with scale #26804, cv::norm variations #26804, minMaxIdx with step support #26789, cv::calcHist #27332, cv::pyrUp #26958, more variations for cv::remap #27119 Python, Java and JavaScript bindings: Added conditional inclusion support to header parser #27325, #27393, #27478 Updated predefined_types.py #26826 Added bindings for animations #26813 Fix wrong python type hints for cv::imread #26890 Replaced tostring() and fromstring() call in tests and samples for compatibility with modern Python #26932, #26949 Replaced ndarray.ptp() with np.ptp() for NumPy 2.0 Compatibility #27133 Extended Java bindings generation in DNN #27228, #27260, Features2d #27245 Fixed std::vector handling in JS wrappers #27291 Added cv::VideoCapture buffered stream constructor into Java #27284, #27421 Extended bindings for cv::HoughLinesWithAccumulator #27377 Fixed Kotlin 2.0 internal error for unsafe coercions #26354 Platforms support: Fixed OpenBLAS detection on Linux #27029 Fixed compatibility with CMake 4 #27192 Fixed Android build with Vulkan support #26765 Fixed VSX intrinsics (Power) implementation #26750, #26786 Added CMake checks for getauxval and elf_aux_info for POWER architecture #26798 Fixed build for openBSD #26803 Added initial support for Nvidia Blackwell GPU arch in CUDA #26820 Fixed cv namespace dependency in Carotene HAL #26878 Fixed _DEBUG/NDEBUG handling across modules #26151 Fixed build for QNX 7.0 #26985 Switched to statically linked FastCV #26917, #27340 fixed build issues on Android #27345 Forced C++17 Standard for CUDA targets when CUDA Toolkit >=12.8 #27112 #27142 Fixed build for Windows ARM64EC #27416 Fixed filesystem support under Cygwin environment #27484 @ text @$NetBSD: patch-modules_videoio_src_cap__v4l.cpp,v 1.1 2025/02/07 21:57:08 wiz Exp $ Conditionalize settings not available in NetBSD's v4l2 emulation. Avoid non-standard integer types. --- modules/videoio/src/cap_v4l.cpp.orig 2025-07-02 07:54:13.000000000 +0000 +++ modules/videoio/src/cap_v4l.cpp @@@@ -215,6 +215,14 @@@@ make & enjoy! #include #include #include +#include +#include +#ifndef __u32 +#define __u32 uint32_t +#endif +#ifndef __s32 +#define __s32 int32_t +#endif #include #include @@@@ -241,24 +249,30 @@@@ typedef uint32_t __u32; #endif // https://github.com/opencv/opencv/issues/13335 +#ifdef V4L2_CID_CAMERA_CLASS_BASE #ifndef V4L2_CID_ISO_SENSITIVITY #define V4L2_CID_ISO_SENSITIVITY (V4L2_CID_CAMERA_CLASS_BASE+23) #endif +#endif // https://github.com/opencv/opencv/issues/13929 +#ifdef V4L2_CID_MPEG_BASE #ifndef V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT #define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT (V4L2_CID_MPEG_BASE+364) #endif #ifndef V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH #define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH (V4L2_CID_MPEG_BASE+365) #endif +#endif #ifndef V4L2_CID_ROTATE #define V4L2_CID_ROTATE (V4L2_CID_BASE+34) #endif +#ifdef V4L2_CID_CAMERA_CLASS_BASE #ifndef V4L2_CID_IRIS_ABSOLUTE #define V4L2_CID_IRIS_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+17) #endif +#endif #ifndef v4l2_fourcc_be #define v4l2_fourcc_be(a, b, c, d) (v4l2_fourcc(a, b, c, d) | (1U << 31)) @@@@ -1467,6 +1481,7 @@@@ void CvCaptureCAM_V4L::convertToRgb(cons case V4L2_PIX_FMT_RGB24: cv::cvtColor(cv::Mat(imageSize, CV_8UC3, start), frame, COLOR_RGB2BGR); return; +#ifdef V4L2_PIX_FMT_Y16 case V4L2_PIX_FMT_Y16: { // https://www.kernel.org/doc/html/v4.10/media/uapi/v4l/pixfmt-y16.html @@@@ -1531,6 +1546,7 @@@@ void CvCaptureCAM_V4L::convertToRgb(cons cv::cvtColor(cv::Mat(imageSize, CV_8UC1, start), frame, COLOR_BayerGB2BGR); return; } +#endif case V4L2_PIX_FMT_GREY: cv::cvtColor(cv::Mat(imageSize, CV_8UC1, start), frame, COLOR_GRAY2BGR); return; @@@@ -1650,8 +1666,10 @@@@ static inline int capPropertyToV4L2(int return -1; case cv::CAP_PROP_FOURCC: return -1; +#ifdef V4L2_CID_MPEG_VIDEO_B_FRAMES case cv::CAP_PROP_FRAME_COUNT: return V4L2_CID_MPEG_VIDEO_B_FRAMES; +#endif case cv::CAP_PROP_FORMAT: return -1; case cv::CAP_PROP_MODE: @@@@ -1666,8 +1684,10 @@@@ static inline int capPropertyToV4L2(int return V4L2_CID_HUE; case cv::CAP_PROP_GAIN: return V4L2_CID_GAIN; +#ifdef V4L2_CID_EXPOSURE_ABSOLUTE case cv::CAP_PROP_EXPOSURE: return V4L2_CID_EXPOSURE_ABSOLUTE; +#endif case cv::CAP_PROP_CONVERT_RGB: return -1; case cv::CAP_PROP_WHITE_BALANCE_BLUE_U: @@@@ -1678,8 +1698,10 @@@@ static inline int capPropertyToV4L2(int return -1; case cv::CAP_PROP_SHARPNESS: return V4L2_CID_SHARPNESS; +#ifdef V4L2_CID_EXPOSURE_AUTO case cv::CAP_PROP_AUTO_EXPOSURE: return V4L2_CID_EXPOSURE_AUTO; +#endif case cv::CAP_PROP_GAMMA: return V4L2_CID_GAMMA; case cv::CAP_PROP_TEMPERATURE: @@@@ -1690,34 +1712,54 @@@@ static inline int capPropertyToV4L2(int return -1; case cv::CAP_PROP_WHITE_BALANCE_RED_V: return V4L2_CID_RED_BALANCE; +#ifdef V4L2_CID_ZOOM_ABSOLUTE case cv::CAP_PROP_ZOOM: return V4L2_CID_ZOOM_ABSOLUTE; +#endif +#ifdef V4L2_CID_FOCUS_ABSOLUTE case cv::CAP_PROP_FOCUS: return V4L2_CID_FOCUS_ABSOLUTE; +#endif case cv::CAP_PROP_GUID: return -1; +#ifdef V4L2_CID_ISO_SENSITIVITY case cv::CAP_PROP_ISO_SPEED: return V4L2_CID_ISO_SENSITIVITY; +#endif case cv::CAP_PROP_BACKLIGHT: return V4L2_CID_BACKLIGHT_COMPENSATION; +#ifdef V4L2_CID_PAN_ABSOLUTE case cv::CAP_PROP_PAN: return V4L2_CID_PAN_ABSOLUTE; +#endif +#ifdef V4L2_CID_TILT_ABSOLUTE case cv::CAP_PROP_TILT: return V4L2_CID_TILT_ABSOLUTE; +#endif +#ifdef V4L2_CID_ROTATE case cv::CAP_PROP_ROLL: return V4L2_CID_ROTATE; +#endif +#ifdef V4L2_CID_IRIS_ABSOLUTE case cv::CAP_PROP_IRIS: return V4L2_CID_IRIS_ABSOLUTE; +#endif case cv::CAP_PROP_SETTINGS: return -1; case cv::CAP_PROP_BUFFERSIZE: return -1; +#ifdef V4L2_CID_FOCUS_AUTO case cv::CAP_PROP_AUTOFOCUS: return V4L2_CID_FOCUS_AUTO; +#endif +#ifdef V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT case cv::CAP_PROP_SAR_NUM: return V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT; +#endif +#ifdef V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH case cv::CAP_PROP_SAR_DEN: return V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH; +#endif case CAP_PROP_AUTO_WB: return V4L2_CID_AUTO_WHITE_BALANCE; case CAP_PROP_WB_TEMPERATURE: @ 1.1 log @opencv-contrib-face: update to 4.11.0. To match opencv. @ text @d1 1 a1 1 $NetBSD: patch-modules_videoio_src_cap__v4l.cpp,v 1.9 2021/10/16 07:16:29 adam Exp $ d6 1 a6 1 --- modules/videoio/src/cap_v4l.cpp.orig 2025-01-08 12:47:46.000000000 +0000 d54 1 a54 1 @@@@ -1471,6 +1485,7 @@@@ void CvCaptureCAM_V4L::convertToRgb(cons d62 1 a62 1 @@@@ -1535,6 +1550,7 @@@@ void CvCaptureCAM_V4L::convertToRgb(cons d69 2 a70 2 break; @@@@ -1654,8 +1670,10 @@@@ static inline int capPropertyToV4L2(int d81 1 a81 1 @@@@ -1670,8 +1688,10 @@@@ static inline int capPropertyToV4L2(int d92 1 a92 1 @@@@ -1682,8 +1702,10 @@@@ static inline int capPropertyToV4L2(int d103 1 a103 1 @@@@ -1694,34 +1716,54 @@@@ static inline int capPropertyToV4L2(int @