RGB Model
Building the Cantata Workspace
- Read the image $DIP/data/istec-map-color.viff and display it using
operators
User defined and
Display Image.
- Read the header information of the color image and verify that it
has three elements and RGB as its color model. Use operators
Data Object Info
and
File Viewer
- Extract the red band (element 0) of the color image by using the operator
Extract. Remember
that you don't need to specify any width or height dimensions as you are
only extracting in the elements dimension. Display this image. It is a
grey-level image showing the intensity of the red component of the RGB
image.
- To display this image as shades of red you need to create an RGB
image (3 elements) with elements 1 (Green) and 2 (Blue)
with value zero. Use the operator
Pad.
- Repeat the same for the green and blue components.
- Use the operator
Add to add different color bands.
Exercises
- Create three synthetic images of a circle, where each one has its center
in a different position. Combine these three images into an RGB image
and display it. You will see the 8 colors which are the vertices of the
RGB cube model.
Hint: use operators
Circle Image,
Inset and
Set Attribute
.
DIP Feedback Form