GDS-Render v1.2.1
bounding_box Union Reference

Union describing a bounding box. More...

#include <bounding-box.h>

Collaboration diagram for bounding_box:
[legend]

Data Structures

struct  _vectors
 Location vectors of upper right and lower left bounding box points. More...
 

Data Fields

struct bounding_box::_vectors vectors
 
struct vector_2d vector_array [2]
 Array of vectors representing a bounding box. More...
 

Detailed Description

Union describing a bounding box.

Two ways of accessing a bounding box are possible.

Either, use the "named" vectors struct to specifically access the points

lower_left = box.vectors.lower_left;
upper right = box.vectors.upper_right;

or use the iterable vector array:

for (i = 0; i < 2; i++)
box.vector_array[i] = points[i];

Definition at line 55 of file bounding-box.h.

Field Documentation

◆ vector_array

struct vector_2d vector_array[2]

Array of vectors representing a bounding box.

Note
This is more convenient for iterating

Definition at line 70 of file bounding-box.h.

◆ vectors

struct bounding_box::_vectors vectors

The documentation for this union was generated from the following file: