OptrisOptrisDocumentation

Documentation/OTC SDK/OTC SDK — C++ API referencev12.0

optris::sdk::RegionStyle

How the region is drawn in the overlay. Carried over from Roi.

Public attributes

color

std::array< float, 4 > color = {1.0F,
                                0.0F,
                                0.0F,
                                1.0F}

outline RGBA, 0..1

text_color

std::array< float, 4 > text_color = {1.0F, 1.0F, 1.0F, 1.0F}

label RGBA

line_width

float line_width = 2.0F

outline width in pixels

marker_style

MarkerStyle marker_style = MarkerStyle::kCrosshair

spot marker shape

marker_size

float marker_size = 5.0F

marker size in pixels

show_label

bool show_label = false

draw the region's name and reading

show_aperture

bool show_aperture = false

Outline the pixels a point region's aperture actually sampled.

A debug aid, off by default: it draws one box per sampled pixel, so on a large aperture it is a lot of ink and on a shipping display it is noise. What it shows is the clipped set -- the pixels that survived both the owning region's geometry and the image bounds -- so a spot that landed on a corner visibly draws four boxes where its nominal window is twenty-five, which is the question this exists to answer.

Requires Region::want_samples, because the sampled set is what Region::samples holds and nothing records it otherwise. With want_samples off this draws nothing rather than guessing at the nominal window, which would show the wrong answer confidently. Ignored by every kind that is not a point.

label_anchor

LabelAnchor label_anchor = LabelAnchor::kNorth

which side it sits on

label_margin

float label_margin = 10.0F

gap between region and label, in pixels

font_size

float font_size = 0.0F

Label size in pixels; 0 lets the renderer choose one that suits the frame.