
Published OpenCV 5.0.0 — a major release of the open-source computer vision and image processing library. The release took place on June 6, 2026 and is already marked as current in the project's GitHub repository. OpenCV is distributed under the license Apache-2.0.
The essence of the release is the transition of OpenCV from a "classic computer vision library" to a more modern platform for CV/AI tasks: the project has cleaned up the old API, revamped the neural network inference module, expanded ONNX support, added groundwork for VLM/LLM scenarios, and updated the 3D/calibration stack. Developers describe OpenCV 5.0 as a branch now also considered stable, with new functionality primarily being integrated there.
Key changes
A new DNN inference engine.
The dnn module has introduced a new engine that coexists with the old one. It performs better with dynamic tensor shapes, subgraphs, and modern ONNX capabilities. It claims coverage of over 80% of the ONNX specification, while OpenCV 4.x covered less than 23%.
This is likely the main change of the release: OpenCV is trying to become not just a wrapper around models, but a fully embedded inference engine for modern neural networks.Engine selection when loading a model.
In cv::dnn::readNet() and related functions, an ENGINE_AUTO parameter has been introduced. By default, OpenCV first tries the new engine and falls back to the classic one on failure. This behavior can also be controlled through the OPENCV_FORCE_DNN_ENGINE environment variable: to use the old engine, new engine, automatic mode, or ONNX Runtime. Old projects are not required to fully switch to the new engine immediately, but new models can be gradually transitioned to it.Integration with ONNX Runtime.
OpenCV can now be built with ONNX Runtime included. In this case, OpenCV uses its own ONNX parser to build the ORT graph, so it does not require the full ONNX package. Build parameters include -DWITH_ONNXRUNTIME=ON and -DDOWNLOAD_ONNXRUNTIME=ON; for NVIDIA GPUs — -DDOWNLOAD_ONNXRUNTIME_GPU=ON. This feature will be useful for those who need GPU inference right now, because the new OpenCV DNN engine currently works only on CPUs.Support for vision-language models.
The new DNN engine includes tokenizers, attention layers, decoding blocks, post-processing, and a KV cache necessary to run VLM models 'out of the box'. The library has historically been associated with image processing and is now venturing into models that work simultaneously with both images and text.GPU support for the new DNN engine is not ready yet.
The new engine in OpenCV 5.0 works only on CPU. Native GPU support is promised to be added in future releases; for now, it is recommended to use the classic engine or a build with ONNX Runtime and NVIDIA execution providers for GPU. OpenCV 5.0 on its own has not yet replaced specialized runtimes for server or desktop CUDA inference.Old parsers for Darknet and Caffe have been removed.
Developers removed Darknet and Caffe parsers since the majority of models have already been converted to ONNX. TFLite still remains through the classic engine, while migration to the new engine is planned for later. OpenCV is abandoning old formats and focusing on ONNX as the main model exchange format.A major cleanup of the outdated API.
The C API for OpenCV 1.x has been removed: functions like cvCreateMat() and old structures like CvMat are no longer part of the main API. Support for OpenVX has also been removed, and the G-API module has been moved to opencv_contrib, along with the classic ML module. This is a breaking change for old projects, but it has been long overdue: the library is shedding the technical debt accumulated over decades.Features2D has been renamed to Features.
The module has been expanded to include modern feature vectors from neural networks. The main repository retains SIFT, ORB, FAST, GoodFeaturesToTrack, and MSER, while deprecated detectors and descriptors have been moved to opencv_contrib. New additions include ALIKED, DISK, and the LightGlue matcher. OpenCV is clearly adapting to modern pipelines, where image features are increasingly extracted not by traditional algorithms, but by neural networks.New data types in Core.
Added CV_16BF / cv::bfloat, CV_32U, CV_64U, CV_64S, and CV_Bool. Support for N-dimensional arrays, 1D arrays, and 0D scalars has also been improved. LAPACK is now always available: if the external library is not present, OpenCV builds a minimal built-in subset. These changes are important for DNN, numerical algorithms, and compatibility with modern data formats, where bfloat16 and extended types are increasingly common.Image processing has been accelerated.
In imgproc, warpAffine, warpPerspective, and remap have been reworked. Performance improvements are claimed to range from 10% to over 300% depending on the platform, image size, data type, and operation flags.
This is no longer about AI modules — such optimizations are directly important for classical tasks: video streams, stabilization, projection transformations, and data preparation before inference.Text output has been improved.
The old text rendering mechanism has been replaced with an STB-based TrueType engine featuring the built-in variable font Rubik. Custom fonts can be added, and there is broad Unicode support. However, complex scripts like Arabic and Devanagari still display incorrectly without Harfbuzz, and colored emojis are not supported. OpenCV is becoming more convenient for generating annotations, debug images, and visualizations without external libraries.3D and camera calibration have been updated.
calib3d has been divided into geometry, calib, stereo, and ptcloud. USAC has become the standard backend for robust estimation of homography, essential/fundamental matrix, PnP, and other tasks. A multi-camera calibration pipeline has been added, along with initial support for processing meshes and point clouds, including TSDF, ICP, import and export of .ply and .obj. This is a crucial step for robotics, SLAM, AR/VR, and multi-camera systems, where single 2D processing has long been insufficient.Examples and documentation have been revamped.
Obsolete examples have been removed, and the remaining ones have been updated. DNN examples now use a shared collection of models that can be downloaded with the script download_models.py. Experimental examples for VLM and LDM have been added, and documentation has received a modern theme, quick search, light/dark mode, and improved navigation. For such a large library, this is not just a cosmetic change: proper documentation and working examples directly affect whether developers can effectively transition to OpenCV 5.x.
As a result, OpenCV 5.0 is not just another release with optimizations, but a significant update across the board: less legacy from the OpenCV 1.x era and more focus on ONNX, neural network inference, modern features, 3D processing, and heterogeneous acceleration. However, transitioning from older projects may require adjustments due to the removal of the C API and the relocation of some modules to opencv_contrib.
Source: linux.org.ru
