[Commits] [wesnoth/wesnoth] 835b17: Allow render_target_setter to restore the last tar...
GitHub
noreply at github.com
Mon Jul 24 07:13:31 UTC 2017
Branch: refs/heads/accelerated_rendering
Home: https://github.com/wesnoth/wesnoth
Commit: 835b17f48294696fcae3b8f2962c11795cd496d1
https://github.com/wesnoth/wesnoth/commit/835b17f48294696fcae3b8f2962c11795cd496d1
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-07-24 (Mon, 24 Jul 2017)
Changed paths:
M src/sdl/render_utils.hpp
Log Message:
-----------
Allow render_target_setter to restore the last target when destroyed
Commit: a8283f457c8fc43c7f94c9cbd56ecd4b0633fa09
https://github.com/wesnoth/wesnoth/commit/a8283f457c8fc43c7f94c9cbd56ecd4b0633fa09
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-07-24 (Mon, 24 Jul 2017)
Changed paths:
M src/gui/widgets/styled_widget.cpp
M src/gui/widgets/styled_widget.hpp
Log Message:
-----------
GUI2/Styled Widget: enabled the virtual init function
I need this for some upcoming changes to the minimap widget that require an initialization
step on after canvas creation.
Commit: c7ca8ebfa82a11b3aa4917388ee684761ed6e27e
https://github.com/wesnoth/wesnoth/commit/c7ca8ebfa82a11b3aa4917388ee684761ed6e27e
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-07-24 (Mon, 24 Jul 2017)
Changed paths:
M src/minimap.cpp
M src/minimap.hpp
Log Message:
-----------
Added new minimap drawing method that works wholly with textures
I've left the old getMinimap function alone and added a new function that will eventually replace it
that utilizes texture rendering to a given texture instead of relying on surface blits and scaling.
This has the benefit of, well, reducing surface ops, for one, as well as removing the need to create
a new texture from the minimap surface every time it's updated.
Commit: 386e46dab6b18ca237743223fd1c68a16e6dbe8b
https://github.com/wesnoth/wesnoth/commit/386e46dab6b18ca237743223fd1c68a16e6dbe8b
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-07-24 (Mon, 24 Jul 2017)
Changed paths:
M src/gui/core/canvas.cpp
M src/gui/core/canvas.hpp
Log Message:
-----------
GUI2/Canvas: allow the default draw routine (shape drawing) to be overridden
Previously widgets that wanted to implement custom drawing behavior overrode styled_widget::impl_draw_background
or impl_draw_foreground. Those functions in the base class simply called the canvas render methods. Some widgets
such as the minimap ignored that rendered the contents on their own.
This new method allows rendering directly to the canvas's texture, meaning all the caching and sizing is already
handled by the canvas and doesn't need to be done by the widget; everything's always the right size and redrawn
when necessary.
Commit: ba478ed8c7c210a69bd7fffe83edd7ce1c3e9d06
https://github.com/wesnoth/wesnoth/commit/ba478ed8c7c210a69bd7fffe83edd7ce1c3e9d06
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-07-24 (Mon, 24 Jul 2017)
Changed paths:
M src/gui/core/canvas.cpp
Log Message:
-----------
GUI2/CanvasL fixup 4ed729cf9c (use initializer list for move ctor)
Commit: 7c462efc2e9a1f4c8328119c0a7091b197cfd6de
https://github.com/wesnoth/wesnoth/commit/7c462efc2e9a1f4c8328119c0a7091b197cfd6de
Author: Charles Dang <exodia339 at gmail.com>
Date: 2017-07-24 (Mon, 24 Jul 2017)
Changed paths:
M src/gui/widgets/minimap.cpp
M src/gui/widgets/minimap.hpp
Log Message:
-----------
GUI2/Minimap: refactored drawing code
Instead of using the minimap surface method (which was getting converted from surface to texture every
draw cycle since the caching mechanism the canvas implemented wasn't available and the weird custom
cache the widget implemented itself didn't seem to do actually do anything) we use the new render-to-
canvas-texture method which is a lot cleaner and should be a lot faster. This also means we no longer
override styled_widget::impl_draw_background.
Do note I might use the design of the removed cache here to add some age functionality to the
font::pango_text cache.
Compare: https://github.com/wesnoth/wesnoth/compare/1ab8fd22bda6...7c462efc2e9a
More information about the Commits
mailing list