This example requires a browser that supports the HTML5 <canvas> feature.

Querying World, View and Canvas-space origins

Querying node World, View and Canvas-space origins via a "rendered" event.

For each of these teapots we're listening to "rendered" events on their scene nodes, which report their centre points in various coordinate systems, along with the Model, View and Projection matrices that are applied to them.

Using the Canvas space centers, we can then float a DIV over each teapot on the canvas to report its center points.

Log

teapot1

Canvas: 820, 350
Proj : 21, 0
Camera : 0.5, 0, 0.9
View : 20, 0, -36
World : -20, 0, 1
teapot2

Canvas: 1084, 681
Proj : 22, -19
Camera : 0.6, -0.5, 0.6
View : 20.8, -12.1, -20.1
World : -20.8, -12.1, -14.9
teapot3

Canvas: 718, 222
Proj : 20, 19
Camera : 0.3, 0.3, 0.9
View : 19.2, 12.1, -51.9
World : -19.2, 12.1, 16.9