(camera)
| 875 | // getLayoutCamera :: gl-plot3d_coords -> plotly_coords |
| 876 | // inverse of getCameraArrays |
| 877 | function getLayoutCamera(camera) { |
| 878 | return { |
| 879 | up: {x: camera.up[0], y: camera.up[1], z: camera.up[2]}, |
| 880 | center: {x: camera.center[0], y: camera.center[1], z: camera.center[2]}, |
| 881 | eye: {x: camera.eye[0], y: camera.eye[1], z: camera.eye[2]}, |
| 882 | projection: {type: (camera._ortho === true) ? 'orthographic' : 'perspective'} |
| 883 | }; |
| 884 | } |
| 885 | |
| 886 | // get camera position in plotly coords from 'gl-plot3d' coords |
| 887 | proto.getCamera = function() { |
no outgoing calls
no test coverage detected
searching dependent graphs…