# Easy3DProcessing2D

| Support            | ![](assets/images/sample_programs/applies_to/cpp.svg)   |
|--------------------|---------------------------------------------------------|
| Required licenses  | **Easy3D** and **EasyOCR2**                             |
| Recommended images | The images from the folder `Sample Images/3D/DepthMaps` |
| Location           | `3D Processing/Easy3DProcessing2D`                      |

## Purpose

This sample program demonstrates how to:

- Load a depth map.
- Apply a 2D operator (an OCR in this sample) on the gray scale pixel values.

![](assets/images/sample_programs/3d_processing_easy3dprocessing2d.webp)

## Code highlights

1. Convert a depth map to an `EImage`.
   ```c++
   const EImageBW8& image2D = depthMap_.AsEImage();
   ```
2. Perform the operation `Read`.
   ```c++
   read_ = ocr2_.Read(image2D);
   ```
3. Draw the depth map, with blue color for undefined pixels.
   ```c++
   depthMap_.Draw(drawAdapter, zoom, zoom, 0.f, 0.f, EC24(0,0,255));
   ```
