derive from GLKViewController
this handles resizing the view/framebuffer much better fixes #130, #131, #133, #118
This commit is contained in:
@@ -34,12 +34,12 @@ void Transform::cancelAnimations() {
|
||||
animations.clear();
|
||||
}
|
||||
|
||||
void Transform::resize(uint16_t w, uint16_t h, uint16_t fb_w, uint16_t fb_h) {
|
||||
void Transform::resize(uint16_t w, uint16_t h, float ratio, uint16_t fb_w, uint16_t fb_h) {
|
||||
width = w;
|
||||
height = h;
|
||||
pixelRatio = ratio;
|
||||
fb_width = fb_w;
|
||||
fb_height = fb_h;
|
||||
pixelRatio = (float)fb_w / (float)w;
|
||||
}
|
||||
|
||||
void Transform::moveBy(double dx, double dy, double duration) {
|
||||
|
||||
Reference in New Issue
Block a user