Options
All
  • Public
  • Public/Protected
  • All
Menu

Class LabeledBox

Hierarchy

Implements

Index

Constructors

constructor

Accessors

area

  • get area(): number
  • Returns number

bottom

  • get bottom(): number
  • Returns number

height

  • get height(): number
  • Returns number

label

  • get label(): number
  • Returns number

left

  • get left(): number
  • Returns number

right

  • get right(): number
  • Returns number

top

  • get top(): number
  • Returns number

width

  • get width(): number
  • Returns number

x

  • get x(): number
  • Returns number

y

  • get y(): number
  • Returns number

Methods

calibrate

  • calibrate(region: Box): Box<any>
  • Parameters

    Returns Box<any>

clipAtImageBorders

  • clipAtImageBorders(imgWidth: number, imgHeight: number): Box<LabeledBox>
  • Parameters

    • imgWidth: number
    • imgHeight: number

    Returns Box<LabeledBox>

floor

  • Returns Box<LabeledBox>

pad

  • Parameters

    • padX: number
    • padY: number

    Returns Box<LabeledBox>

padAtBorders

  • padAtBorders(imageHeight: number, imageWidth: number): object
  • Parameters

    • imageHeight: number
    • imageWidth: number

    Returns object

rescale

round

  • Returns Box<LabeledBox>

shift

  • Parameters

    • sx: number
    • sy: number

    Returns Box<LabeledBox>

toSquare

Static assertIsValidBox

  • assertIsValidBox(box: any, callee: string, allowNegativeDimensions?: boolean): void
  • Parameters

    • box: any
    • callee: string
    • Default value allowNegativeDimensions: boolean = false

    Returns void

Static assertIsValidLabeledBox

  • assertIsValidLabeledBox(box: any, callee: string): void
  • Parameters

    • box: any
    • callee: string

    Returns void

Static isRect

  • isRect(rect: any): boolean
  • Parameters

    • rect: any

    Returns boolean

Generated using TypeDoc