opencv/samples/cpp
Maksim Shabunin 7bdc618697
Merge pull request #26025 from mshabunin:cpp-videoio-highgui
 Potential conflicts with #25958
C-API cleanup: highgui, videoio #26025

  Merge with: opencv/opencv_contrib#3780

This PR removes usage of C-API from highgui and videoio modules. Only source code is affected, tests were not using obsolete API.

It should be possible to backport these changes to 4.x branch preserving removed public headers and source files (`*_c.h` and `*_c.cpp`).


#### Checklist

I tried to verify as many backends as possible, though these checks were not as thorough as I'd like them to be. Below is the checklist covering all modified backends with their statuses.

> 🔹 - small changes
> 🟢 - consider working
>  - considered untested

##### highgui

Pass | Backend | Local check | CI check
-----|---------|-------------|---------
🟢 | GTK2 | build + test, plugin build | build + test  
🟢 | GTK3 | build + test, plugin build | build + test
🟢 | QT | build + test, plugin build |
 | Wayland 🔹 | |
🟢 | WIN32 🔹 | | build + test
🟢 | Cocoa 🔹 | | build + test
 | WinRT | | 

##### videoio 

Pass | Backend | Local check | CI check
-----|---------|-------------|---------
🟢 | Android Camera/MediaNDK 🔹 | | build
🟢 | Aravis | build |
🟢 | AVFoundation OSX | | build + test
 | AVFoundation iOS | | build
🟢 | DC1394 | build |
🟢 | DShow 🔹 | | build
🟢 | FFMpeg | build, plugin build | build + test
🟢 | GPhoto 🔹 | build |
🟢 | GStreamer | build, plugin build | build + test
🟢 | Images | build | build + test
🟢 | MSMF 🔹 | | build + test
🟢 | OpenNI | build |
🟢 | PVAPI | build |
🟢 | V4L | build + test | build
🟢 | XIMEA | build |
🟢 | XINE 🔹 | build |

#### Notes

- local linux build checks performed using [this framework](https://github.com/mshabunin/opencv-videoio-build-check)
- minor extra changes made in both `cap_avfoundation*.mm` to make them slightly more synchronized - it would be better to combine them into a single one in the future
- configurations with plugins have been build but not tested
- **moved unrelated changes to separate PRs** ~two issues have been fixed in separate commits:~
  - ~imgproc: missing `cv::hal::` color conversion functions has been used in MediaSDK backend~
  - ~videoio/V4L: wrong color conversion mode caused bad colors for NV12 camera input format (RGB instead of BGR)~

It would be nice to check following functionality manually:
- [ ] OSX: camera input
- [ ] iOS: camera and file input
- [ ] WinRT: build, some testing
- [x] Linux/Wayland: build
2024-09-09 16:42:44 +03:00
..
example_cmake build: suppress the warning 2022-07-12 19:42:39 +09:00
snippets Merge pull request #25515 from gursimarsingh:improved_edge_detection_sample 2024-09-06 12:47:04 +03:00
tutorial_code Merge pull request #26025 from mshabunin:cpp-videoio-highgui 2024-09-09 16:42:44 +03:00
3calibration.cpp Merge branch 4.x 2023-01-28 17:31:32 +00:00
application_trace.cpp Update Samples 2019-09-05 01:10:51 +03:00
aruco_dict_utils.cpp Merge pull request #23018 from stopmosk:move-aruco-tutorial 2024-02-26 14:57:46 +03:00
asift.cpp calib3d module in opencv is split into 3 modules: 3d, calib and stereo. 2020-12-01 23:42:15 +03:00
audio_spectrogram.cpp Merge pull request #20934 from SinM9:spectrogram_samples 2021-12-14 17:33:26 +00:00
barcode.cpp Merge pull request #23666 from mshabunin:barcode-move 2023-06-14 22:21:38 +03:00
bgfg_segm.cpp samples: use findFile() in "cpp" 2018-11-16 18:08:22 +00:00
calibration.cpp Merge branch 4.x 2023-07-05 15:51:10 +03:00
CMakeLists.txt Merge pull request #25017 from kaingwade:ml_to_contrib 2024-02-27 15:54:08 +03:00
connected_components.cpp samples: use findFile() in "cpp" 2018-11-16 18:08:22 +00:00
cout_mat.cpp using argv[0] represent binary executable files' name in help() function 2020-02-28 20:36:56 +08:00
delaunay2.cpp using argv[0] represent binary executable files' name in help() function 2020-02-28 20:36:56 +08:00
demhist.cpp Update Samples 2019-09-05 01:10:51 +03:00
detect_mser.cpp Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-03-04 20:49:09 +00:00
digits_lenet.cpp add OpenCV sample for digit and text recongnition, and provide multiple OCR models. 2020-08-22 01:02:13 +08:00
drawing.cpp Merge pull request #25415 from gursimarsingh:improved_drawing_cpp_sample 2024-04-16 12:48:18 +03:00
essential_mat_reconstr.cpp 5.x: cleanup compatibility code (2021-10) 2021-10-20 17:40:04 +00:00
fback.cpp using argv[0] represent binary executable files' name in help() function 2020-02-28 20:36:56 +08:00
filestorage.cpp samples: use findFile() in "cpp" 2018-11-16 18:08:22 +00:00
flann_search_dataset.cpp Merge pull request #17643 from pemmanuelviel:pev--new-flann-demo 2020-08-10 13:26:40 +00:00
floodfill.cpp Merge pull request #25252 from gursimarsingh:cpp_samples_cleanup 2024-07-11 15:07:21 +03:00
geometry.cpp Merge pull request #25304 from gursimarsingh:geometry_sample_cpp 2024-04-16 10:13:34 +03:00
grabcut.cpp Updated grabcut example to show the background in a transparant way 2021-07-14 22:02:27 +02:00
image_alignment.cpp using argv[0] represent binary executable files' name in help() function 2020-02-28 20:36:56 +08:00
imagelist_creator.cpp update cpp samples and tutorials 2016-06-26 20:55:00 +03:00
intelligent_scissors.cpp Merge pull request #16853 from SimpleVlad:note 2020-03-19 21:39:54 +00:00
lkdemo.cpp Merge pull request #9618 from vipinanand4:goodFeaturesToTrack_added_gradiantSize 2017-09-22 14:04:43 +00:00
morphology2.cpp using argv[0] represent binary executable files' name in help() function 2020-02-28 20:36:56 +08:00
multiview_calibration_sample.cpp Merge pull request #22363 from ivashmak:multiview-calib 2023-03-23 15:42:41 +03:00
npr_demo.cpp samples: use findFile() in "cpp" 2018-11-16 18:08:22 +00:00
opencv_version.cpp Minor refactoring in several C++ samples: 2018-03-06 14:23:20 +03:00
pca.cpp Merge pull request #23108 from crackwitz:issue-23107 2023-01-09 09:55:31 +00:00
qrcode.cpp added graphicalCodeDetector, remove QRCodeDetectorBase 2023-06-08 14:50:58 +03:00
select3dobj.cpp Merge branch 4.x 2022-08-21 15:27:31 +00:00
simd_basic.cpp Clean up the Universal Intrinsic API. 2023-10-13 19:23:30 +08:00
stereo_calib.cpp Merge branch 4.x 2023-07-05 15:51:10 +03:00
stereo_match.cpp calib3d module in opencv is split into 3 modules: 3d, calib and stereo. 2020-12-01 23:42:15 +03:00
stitching_detailed.cpp Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-04-24 19:02:39 +00:00
videocapture_audio_combination.cpp Merge pull request #19721 from MaximMilashchenko:Audio 2021-10-20 16:18:24 +03:00
videocapture_audio.cpp Merge pull request #19721 from MaximMilashchenko:Audio 2021-10-20 16:18:24 +03:00
videocapture_basic.cpp Update videocapture_basic.cpp 2020-04-24 11:42:45 +03:00
videocapture_camera.cpp samples: videocapture_camera use VideoCapture with 0 index 2018-07-03 15:44:53 +03:00
videocapture_depth.cpp Merge pull request #25410 from kaingwade:add_videocapture_depth_sample 2024-07-03 17:44:13 +03:00
videocapture_gphoto2_autofocus.cpp FIx misc. source and comment typos 2019-08-15 13:09:52 +03:00
videocapture_gstreamer_pipeline.cpp videoio(doc): add 'videoio_hwaccel' group, fix typos 2021-03-07 04:47:22 +00:00
videocapture_image_sequence.cpp Merge pull request #13188 from alalek:samples_rename 2018-11-17 00:35:05 +03:00
videocapture_microphone.cpp Merge pull request #19721 from MaximMilashchenko:Audio 2021-10-20 16:18:24 +03:00
videocapture_starter.cpp Merge pull request #22149 from seanm:sprintf 2022-06-25 06:48:22 +03:00
videowriter_basic.cpp Merge pull request #25252 from gursimarsingh:cpp_samples_cleanup 2024-07-11 15:07:21 +03:00