Table of Contents

CadLabelClass

from OpenCAD2D import CadLabelClass

class CadLabelClass(System.Object) ยท CadLabelClass in the .NET reference

The classes CadRender.DrawLabels sorts what a picture shows into: a number from 1 to 5 for each pixel that holds something, 0 for the ground. The numbers are fixed and are the category ids of a COCO file made from the same picture.

Properties and fields

Background

.NET

Background: ClassVar[int]

The class of a pixel nothing is drawn on: 0.

Blocks

.NET

Blocks: ClassVar[int]

The class of an INSERT's whole drawing, where blocks are asked for: 5.

Count

.NET

Count: ClassVar[int]

The most classes, ground included: the number after the last class.

Dimensions

.NET

Dimensions: ClassVar[int]

The class of the lines and arrowheads of a dimension: 2.

Hatches

.NET

Hatches: ClassVar[int]

The class of hatches, solids and traces, and of the frame of a wipeout: 4.

Lines

.NET

Lines: ClassVar[int]

The class of lines, arcs, circles, polylines, splines and everything else that is drawn as a curve: 3.

Words

.NET

Words: ClassVar[int]

The class of text: 1.

Methods

NameOf

.NET

@staticmethod
def NameOf(id: int) -> str

Gets the name of a class: the ground is "background", then "words", "dimensions", "lines", "hatches" and "blocks", the names of the categories of a COCO file.