Skip to content

Commit

Permalink
Fix overriding requested fbo sizes
Browse files Browse the repository at this point in the history
  • Loading branch information
Shinmera committed Oct 20, 2019
1 parent a707d20 commit a58159a
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions pipeline.lisp
Expand Up @@ -61,8 +61,11 @@
do (multiple-value-bind (width height) (texspec-real-size texspec width height) do (multiple-value-bind (width height) (texspec-real-size texspec width height)
(resize texture width height))) (resize texture width height)))
(loop for pass across (passes pipeline) (loop for pass across (passes pipeline)
do (setf (width (framebuffer pass)) width) for binding = (first (attachments (framebuffer pass)))
(setf (height (framebuffer pass)) height))) when binding ;; We have to do it like this to prevent updating FBOs with
;; texspecs that are not window-size.
do (setf (width (framebuffer pass)) (width (second binding)))
(setf (height (framebuffer pass)) (height (second binding)))))


(defmethod normalized-texspec ((texspec list)) (defmethod normalized-texspec ((texspec list))
(assert (= 0 (getf texspec :level 0))) (assert (= 0 (getf texspec :level 0)))
Expand Down

0 comments on commit a58159a

Please sign in to comment.