![]() |
tinyimg 1.0.0
Lightweight image manipulation library for Cloudflare Workers
|
Public Attributes | |
| uint32_t | width |
| uint32_t | height |
| TinyImageFit | mode |
| TinyImageGravity | gravity |
| float | focus_x |
| Where the interesting part is, 0 through 1 across each axis. | |
| float | focus_y |
| uint8_t | focused |
| TinyResampleFilter | filter |
| TinyResampleFilter TinyPlanOp::[struct].__unnamed0__.fit filter |
Weights the fit's scale samples through.
| float TinyPlanOp::[struct].__unnamed0__.fit focus_x |
Where the interesting part is, 0 through 1 across each axis.
Only read when focused is set, and only meaningful for the two computed gravities. It exists so tiny_plan_resolve stays a function of the plan alone: the question "where are the faces" needs pixels, and resolution happens before any pixel is read, so tiny_plan_run answers it first and writes the answer here. A fit op that reaches resolution without one falls back to the center.
| float TinyPlanOp::[struct].__unnamed0__.fit focus_y |
The vertical position; see focus_x.
| uint8_t TinyPlanOp::[struct].__unnamed0__.fit focused |
| TinyImageGravity TinyPlanOp::[struct].__unnamed0__.fit gravity |
Which part a crop keeps, or where a pad puts the image.
| uint32_t TinyPlanOp::[struct].__unnamed0__.fit height |
Target height.
| TinyImageFit TinyPlanOp::[struct].__unnamed0__.fit mode |
How the aspect mismatch is absorbed and the scale clamped.
| uint32_t TinyPlanOp::[struct].__unnamed0__.fit width |
Target width.