struct RotatableExtent
Defined at line 1075 of file fidling/gen/sdk/fidl/fuchsia.ui.observation.geometry/fuchsia.ui.observation.geometry/cpp/fidl/fuchsia.ui.observation.geometry/cpp/wire_types.h
A view bounding box, described in another view's coordinate system.
Concretely, |RotatableExtent| describes the origin, size, and rotation angle
about the origin, for a view's bounding box.
Note: For describing a view's bounding box in the view's own coordinate
system, see |AlignedExtent|.
We use "V" to refer to the view being described, and "W" to refer to the
view where V is being described.
Note that while |angle| can be arbitrary, typical usage is axis aligned.
To find the bounding box of V in W in clockwise order, starting with
|origin|, where |angle| is 0, 90, 180, or 270, and using o=origin, w=width,
h=height, a=angle:
a= 0: (o.x, o.y), (o.x + w, o.y), (o.x + w, o.y + h), (o.x, o.y + h)
a= 90: (o.x, o.y), (o.x, o.y - w), (o.x + h, o.y - w), (o.x + h, o.y)
a=180: (o.x, o.y), (o.x - w, o.y), (o.x - w, o.y - h), (o.x, o.y - h)
a=270: (o.x, o.y), (o.x, o.y + w), (o.x - h, o.y + w), (o.x - h, o.y)
A formula based on sin a and cos a is readily obtained, but floating point
computation may give only approximate results.
Public Members
PointF origin
float width
float height
float angle_degrees