RegionFreeHand

Support

Required licenses

Any

Recommended images

Any

Location

Image Processing/RegionFreeHand

Purpose

This sample program demonstrates how to:

  • Create an ERegion using the ERegionFreeHandPainter.

Code highlights

  1. Set the size of the canvas (painting area) for subsequent painting.

    painter_.SetCanvasSize(width, height);
    
  2. Set the painter brush. It can be a region of any shape you desire.

    painter_.SetBrush(region);
    
  3. Apply the brush to the canvas at the given coordinates.

    painter_.Paint(x, y);
    
  4. Retrieve the painted region from the painter.

    ERegion region = painter_.RetrieveRegion();
    
  5. Clear the canvas for later reuse.

    painter_.ClearCanvas();