Fixing all wrong uses of RGB channels instead of the OpenCV BGR standard
This commit is contained in:
@@ -14,7 +14,7 @@ Whenever you work with video feeds you may eventually want to save your image pr
|
||||
+ What type of video files you can create with OpenCV
|
||||
+ How to extract a given color channel from a video
|
||||
|
||||
As a simple demonstration I'll just extract one of the RGB color channels of an input video file into a new video. You can control the flow of the application from its console line arguments:
|
||||
As a simple demonstration I'll just extract one of the BGR color channels of an input video file into a new video. You can control the flow of the application from its console line arguments:
|
||||
|
||||
.. container:: enumeratevisibleitemswithsquare
|
||||
|
||||
@@ -111,7 +111,7 @@ Afterwards, you use the :hgvideo:`isOpened() <videowriter-isopened>` function to
|
||||
outputVideo.write(res); //or
|
||||
outputVideo << res;
|
||||
|
||||
Extracting a color channel from an RGB image means to set to zero the RGB values of the other channels. You can either do this with image scanning operations or by using the split and merge operations. You first split the channels up into different images, set the other channels to zero images of the same size and type and finally merge them back:
|
||||
Extracting a color channel from an BGR image means to set to zero the BGR values of the other channels. You can either do this with image scanning operations or by using the split and merge operations. You first split the channels up into different images, set the other channels to zero images of the same size and type and finally merge them back:
|
||||
|
||||
.. code-block:: cpp
|
||||
|
||||
|
Reference in New Issue
Block a user