{ "schema_version": 1, "buffer_size_wh": [ 640, 480 ], "convention": { "input": "normalized landmark (u, v) in [0, 1] relative to the camera buffer as delivered (sensor orientation), u to the right, v down", "pixel_scale": "x = u * buffer_width, y = v * buffer_height; continuous coordinates, no half-pixel offset, no clamping", "origin": "top-left corner of the image, x increases to the right, y increases downward (both buffer and display)", "rotation": "rotation_deg is the clockwise rotation applied to the buffer to make it upright (Android ImageInfo.rotationDegrees meaning); 90: (x, y) -> (H - y, x); 180: (x, y) -> (W - x, H - y); 270: (x, y) -> (y, W - x); output size swaps for 90 and 270", "mirroring": "applied AFTER rotation, as a horizontal flip of the rotated display image: x -> output_width - x (front-camera preview)" }, "cases": [ { "rotation_deg": 0, "mirrored": false, "output_size_wh": [ 640, 480 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 640.0, 0.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 0.0, 480.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 640.0, 480.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 320.0, 240.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 160.0, 360.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 64.0, 96.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 576.0, 168.0 ] } ] }, { "rotation_deg": 0, "mirrored": true, "output_size_wh": [ 640, 480 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 640.0, 0.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 640.0, 480.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 0.0, 480.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 320.0, 240.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 480.0, 360.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 576.0, 96.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 64.0, 168.0 ] } ] }, { "rotation_deg": 90, "mirrored": false, "output_size_wh": [ 480, 640 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 480.0, 0.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 480.0, 640.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 0.0, 640.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 240.0, 320.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 120.0, 160.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 384.0, 64.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 312.0, 576.0 ] } ] }, { "rotation_deg": 90, "mirrored": true, "output_size_wh": [ 480, 640 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 0.0, 640.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 480.0, 0.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 480.0, 640.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 240.0, 320.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 360.0, 160.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 96.0, 64.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 168.0, 576.0 ] } ] }, { "rotation_deg": 180, "mirrored": false, "output_size_wh": [ 640, 480 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 640.0, 480.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 0.0, 480.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 640.0, 0.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 320.0, 240.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 480.0, 120.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 576.0, 384.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 64.0, 312.0 ] } ] }, { "rotation_deg": 180, "mirrored": true, "output_size_wh": [ 640, 480 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 0.0, 480.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 640.0, 480.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 640.0, 0.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 320.0, 240.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 160.0, 120.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 64.0, 384.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 576.0, 312.0 ] } ] }, { "rotation_deg": 270, "mirrored": false, "output_size_wh": [ 480, 640 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 0.0, 640.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 480.0, 640.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 480.0, 0.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 240.0, 320.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 360.0, 480.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 96.0, 576.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 168.0, 64.0 ] } ] }, { "rotation_deg": 270, "mirrored": true, "output_size_wh": [ 480, 640 ], "points": [ { "normalized": [ 0.0, 0.0 ], "pixel": [ 480.0, 640.0 ] }, { "normalized": [ 1.0, 0.0 ], "pixel": [ 480.0, 0.0 ] }, { "normalized": [ 0.0, 1.0 ], "pixel": [ 0.0, 640.0 ] }, { "normalized": [ 1.0, 1.0 ], "pixel": [ 0.0, 0.0 ] }, { "normalized": [ 0.5, 0.5 ], "pixel": [ 240.0, 320.0 ] }, { "normalized": [ 0.25, 0.75 ], "pixel": [ 120.0, 480.0 ] }, { "normalized": [ 0.1, 0.2 ], "pixel": [ 384.0, 576.0 ] }, { "normalized": [ 0.9, 0.35 ], "pixel": [ 312.0, 64.0 ] } ] } ] }