summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2014-10-04 11:05:49 +0200
committerSean Harmer <sean.harmer@kdab.com>2014-10-04 13:02:15 +0200
commitd18ece748ee3e220e7f328bae1678929148b4900 (patch)
treece82ddd81daabe54e45e4f58932f5bc13771166c /examples
parent45c2adc1789f0080d9eba5fd7ef53251d2be0490 (diff)
Use the window aspect ratio for the camera in the shadow map example
Change-Id: I2115f3248afc47358440a7471fd5fc811550c763 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/shadow-map-qml/main.qml2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/shadow-map-qml/main.qml b/examples/shadow-map-qml/main.qml
index 0996edf26..4882a1bc2 100644
--- a/examples/shadow-map-qml/main.qml
+++ b/examples/shadow-map-qml/main.qml
@@ -58,7 +58,7 @@ Entity {
lens: CameraLens {
projectionType: CameraLens.PerspectiveProjection
fieldOfView: 45
- aspectRatio: 2
+ aspectRatio: _window.width / _window.height
nearPlane: 0.1
farPlane: 1000.0
}