BananaForScale

A real-size banana, 185 mm tip to stem, stood beside a device's model for scale. The model is bundled with the app, built from a CC0 drawing by scripts/models/banana_for_scale.py: Y up, in meters, standing on y = 0 with its labeled front facing +Z, like the flasher's models.

Properties

Link copied to clipboard
const val MODEL: String

The bundled model, as a compose resource path.

Functions

Link copied to clipboard
fun beside(device: GlbBounds, banana: GlbBounds): FloatArray

Where the banana goes in device's coordinates: on its left, on its lowest point, centered front to back.

Link copied to clipboard
fun besideOnSurface(device: GlbBounds, pose: RestPose, banana: GlbBounds): FloatArray

Where the banana stands on a surface beside a device whose footprint is centered on the origin in pose, clear of it however far the device is turned about the surface's up.

Link copied to clipboard

bounds grown about their center for the orbit camera to frame by. Side by side the two are wider than tall, and framed by their longest side on a portrait screen the device runs off its edge.

Link copied to clipboard
fun stage(device: ByteArray, deviceBounds: GlbBounds, deviceCopyright: String?, banana: ByteArray): StagedModel?

device with banana standing beside it as one GLB, framed by both and carrying both notices. The device's own coordinates are unchanged, so its display glass stays where it was read. Null when the files cannot be merged.

Link copied to clipboard
fun union(device: GlbBounds, banana: GlbBounds, translation: FloatArray): GlbBounds

device and the banana moved by translation, together.