Commit graph

43 commits

Author SHA1 Message Date
Juan Linietsky 953cd03ea6 Use transparent framebuffer only when set to transparent, closes #21827 2019-01-27 15:47:17 -03:00
Juan Linietsky 7fa41f17a6 Makes screen texture work in GLES2 (2D for now), fixes #23604 2019-01-24 17:00:33 -03:00
Juan Linietsky 682fdf0f74 Use 16 bit indices on phones that dont support 32, fixes #19797 2019-01-18 17:30:12 -03:00
Juan Linietsky 7478f468b2 Fixes to 2D lights, closes #24750 2019-01-17 10:40:36 -03:00
Juan Linietsky ffcb5cd18c Ensure texture hints are obeyed, fixes #24875 2019-01-16 00:37:00 -03:00
Rémi Verschelde 72f501de13 GLES2: Fix typo in project setting
It used a different name than the equivalent GLES3 parameter.
2019-01-15 13:26:54 +01:00
Juan Linietsky ee3eadf345 Implement black margins in GLES2, which was missing, fixes #24556 2019-01-14 19:00:36 -03:00
Rémi Verschelde 02ffc59270 GLES2: Make Nvidia flicker workaround opt-in
It has a big impact on 2D and text rendering performance (cf. #24466)
so the solution seems worse than the bug it aims to work around.

It's now opt-in via "rendering/quality/2d/gles2_use_nvidia_rect_flicker_workaround"
for those who need it and have a simple enough game for the performance
drop not to be an issue.

Fixes #24466.
2019-01-14 19:02:07 +01:00
Juan Linietsky b3dc02b5df Was not properly re-setting light uniforms, fixes #24976 2019-01-14 12:04:26 -03:00
Juan Linietsky 6d8083ea65 Do not use the workaround for desktop nvidia on mobile and html5. 2019-01-14 11:24:00 -03:00
Daeil Kim ecf520b70e Change blend equation for canvasitems 2019-01-06 00:57:52 +09:00
Marcin Zawiejski 4e73274837
Fix negative size rectangle drawing
Fixes rectangle being drawn as it was a non-negative size in case it actually is. This can be observed e.g. when drawing a negative size selection rectangle (i.e. press mouse button and move cursor up and left).
2019-01-02 14:47:28 +01:00
Rémi Verschelde c7c87a0624
Merge pull request #24687 from DavidSichma/draw-rect-rot
fix draw_rect rotation
2019-01-01 19:01:18 +01:00
Rémi Verschelde b16c309f82 Update copyright statements to 2019
Happy new year to the wonderful Godot community!
2019-01-01 12:58:10 +01:00
David Sichma 9ba6849cf4 fix draw_rect rotation 2018-12-31 20:56:10 +01:00
Daeil Kim 8c99b6fb2f Change unshaded logic to match with GLES3 2018-12-30 02:02:37 +09:00
Juan Linietsky a366d45856 -Implented 2D Mesh support for GLES2
-Implemented 2D Skeleton deform for GLES2
-Implement Multimesh support for GLES2, closes #20524, closes #21839
2018-12-27 20:41:04 -03:00
Juan Linietsky f3cb236f9d Remove usage of VAO, which does not work in GLES2 2018-12-20 17:28:01 -03:00
Juan Linietsky 3bdd1ff387 Support lights and shadows in GLES2, fixes #21853 2018-12-20 10:10:30 -03:00
Juan Linietsky bec76cfa19 Change how rects are drawn (and also will help batching eventually), to workaround problem in #9913 2018-12-18 17:50:35 -03:00
Superwaitsum e5041ad0f5 Add some limits on the Editor Settings 2018-10-24 19:46:33 -05:00
Rémi Verschelde ac2a4771d5 GLES2: Implement pixel snap 2D option 2018-10-02 15:53:24 +02:00
Bastiaan Olij a6df366b23 Moving lens distortion shader into drivers and adding GLES2 support 2018-10-02 17:14:43 +10:00
Rémi Verschelde d95bbb8922 Fix warnings about set but unused variables [-Wunused-but-set-variable]
Fixes the following GCC 5 warnings:
```
drivers/gles2/rasterizer_canvas_gles2.cpp:814:8: warning: variable 'rt_size' set but not used [-Wunused-but-set-variable]
drivers/gles2/rasterizer_scene_gles2.cpp:2270:11: warning: variable 'vp_height' set but not used [-Wunused-but-set-variable]
drivers/gles2/rasterizer_scene_gles2.cpp:2673:22: warning: variable 'e' set but not used [-Wunused-but-set-variable]
drivers/gles2/rasterizer_scene_gles2.cpp:715:7: warning: variable 'no_cull' set but not used [-Wunused-but-set-variable]
drivers/gles2/shader_gles2.cpp:693:14: warning: variable 'cc' set but not used [-Wunused-but-set-variable]
drivers/gles3/rasterizer_canvas_gles3.cpp:1226:8: warning: variable 'rt_size' set but not used [-Wunused-but-set-variable]
drivers/gles3/rasterizer_scene_gles3.cpp:3039:10: warning: variable 'contrib' set but not used [-Wunused-but-set-variable]
drivers/gles3/rasterizer_scene_gles3.cpp:4504:32: warning: variable 'vp_height' set but not used [-Wunused-but-set-variable]
editor/editor_inspector.cpp:272:9: warning: variable 'guide_color' set but not used [-Wunused-but-set-variable]
editor/editor_themes.cpp:1067:14: warning: variable 'alpha3' set but not used [-Wunused-but-set-variable]
editor/editor_themes.cpp:263:8: warning: variable 'script_bg_color' set but not used [-Wunused-but-set-variable]
editor/plugins/collision_shape_2d_editor_plugin.cpp:326:11: warning: variable 'cpoint' set but not used [-Wunused-but-set-variable]
editor/plugins/mesh_editor_plugin.cpp:72:9: warning: variable 'size' set but not used [-Wunused-but-set-variable]
editor/plugins/shader_editor_plugin.cpp:471:12: warning: variable 'mpos' set but not used [-Wunused-but-set-variable]
editor/plugins/shader_editor_plugin.cpp:89:8: warning: variable 'basetype_color' set but not used [-Wunused-but-set-variable]
editor/plugins/shader_editor_plugin.cpp:90:8: warning: variable 'type_color' set but not used [-Wunused-but-set-variable]
editor/plugins/shader_editor_plugin.cpp:92:8: warning: variable 'string_color' set but not used [-Wunused-but-set-variable]
modules/visual_script/visual_script_editor.cpp:2521:7: warning: variable 'seq_connect' set but not used [-Wunused-but-set-variable]
platform/android/export/export.cpp:580:12: warning: variable 'styles_count' set but not used [-Wunused-but-set-variable]
platform/android/export/export.cpp:584:12: warning: variable 'styles_offset' set but not used [-Wunused-but-set-variable]
platform/osx/export/export.cpp:464:9: warning: variable 'zerr' set but not used [-Wunused-but-set-variable]
scene/2d/tile_map.cpp:260:10: warning: variable 'tcenter' set but not used [-Wunused-but-set-variable]
scene/3d/light.cpp:166:7: warning: variable 'editor_ok' set but not used [-Wunused-but-set-variable]
scene/3d/navigation.cpp:566:11: warning: variable 'closest_navmesh' set but not used [-Wunused-but-set-variable]
scene/gui/rich_text_label.cpp:869:8: warning: variable 'size' set but not used [-Wunused-but-set-variable]
scene/main/viewport.cpp:705:14: warning: variable 'xform' set but not used [-Wunused-but-set-variable]
scene/main/viewport.cpp:706:8: warning: variable 'ss' set but not used [-Wunused-but-set-variable]
scene/main/viewport.cpp:726:14: warning: variable 'xform' set but not used [-Wunused-but-set-variable]
scene/main/viewport.cpp:727:8: warning: variable 'ss' set but not used [-Wunused-but-set-variable]
scene/resources/material.cpp:430:7: warning: variable 'using_world' set but not used [-Wunused-but-set-variable]
servers/visual/shader_language.cpp:2026:7: warning: variable 'all_const' set but not used [-Wunused-but-set-variable]
servers/visual/visual_server_scene.cpp:1383:28: warning: variable 'z_max_cam' set but not used [-Wunused-but-set-variable]
```

Also fixes two [-Wunused-value] warnings:
```
scene/gui/text_edit.cpp:4405:20: warning: statement has no effect [-Wunused-value]
servers/visual/visual_server_scene.cpp:905:48: warning: value computed is not used [-Wunused-value]
```

Some of those are bugs and need further work, they are identified with
`// FIXME` comments.
2018-09-27 16:25:24 +02:00
Rémi Verschelde 1a16dabfb5
Merge pull request #21982 from luzpaz/misc-typos
Misc. typos
2018-09-13 10:59:00 +02:00
luz.paz 08bde5b2de Misc. typos
Found via `codespell -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po"`
2018-09-12 21:39:17 -04:00
Rémi Verschelde 277b24dfb7 Make core/ includes absolute, remove subfolders from include path
This allows more consistency in the manner we include core headers,
where previously there would be a mix of absolute, relative and
include path-dependent includes.
2018-09-12 09:52:22 +02:00
Rémi Verschelde 52466d57e9 Make some debug prints verbose-only, remove others 2018-08-24 14:59:01 +02:00
Thomas Herzog 0f59cc179c [GLES2] fix CanvasModulate not working
That's what happens when you forget about your debug
shortcuts.

Fixes #21025
2018-08-23 17:38:20 +02:00
Thomas Herzog da876907fd [GLES2] fix canvas_item sampler allocation 2018-08-23 16:46:43 +02:00
Marcin Zawiejski bd5ff205b2 Revert "Batch GLES2 draw calls"
This reverts commit f55039b194.

The GLES2 batching seems to require more testing and tweaking in order
to actually make the performance better on Android devices. It's been
proved with #21184 that the current implementation has it's drawbacks
therefore I suggest reverting the commit for now.
2018-08-20 02:10:14 +02:00
Thomas Herzog b4ce1e3005
Merge pull request #20965 from dragmz/gles2_batching
Batch GLES2 draw calls
2018-08-18 18:37:52 +02:00
Thomas Herzog 0ef85b55e0 [gles2] fix black bar artifacts 2018-08-15 17:12:21 +02:00
Marcin Zawiejski f55039b194 Batch GLES2 draw calls
Adds GLES2 draw calls batching for the same render list item that uses
multiple rasterizer commands (e.g. Label node; a node with multiple
GDScript draw_* calls).
2018-08-14 10:47:16 +02:00
Thomas Herzog 73fe08be2e GLES2 refactors
This commit unhacks some parts of the 3D rendering.

Most notably:

 - possibility to use negative texture units
   (no longer weird manual index allocation for user samplers)

 - refactoring of light code, now sorts in a different way,
   should yield better performance

 - fixes a crash while saving (because of "Illegal instruction" execution)
   when using a decent compiler (clang, it's clang. Thanks GCC for not telling me about UB).
2018-08-08 17:09:44 +02:00
karroffel b64171e79c add initial GLES2 3D renderer 2018-07-27 14:15:46 +02:00
Marcin Zawiejski 2d05ae39a2 fix disappearing lines in visual script editor 2018-07-23 09:07:32 +02:00
dragmz 00180ef264 remove redundant uniform set call 2018-07-22 15:42:43 +02:00
Juan Linietsky de910f8c26 Finally figured out how to implement AnimatedTexture properly. 2018-07-16 11:43:49 -03:00
toger5 b4b7ca89f5 fix clipping with v_flip fixes: #2929 2018-06-16 22:55:21 +02:00
Poommetee Ketson ff070de986 s/2017/2018/g for gles2, websocket, linux appdata 2018-03-21 16:07:51 +07:00
karroffel 8b82f4ad2e fix GLES2 line rendering
fixes #17147
2018-03-02 12:35:34 +01:00
karroffel eac4c984df add GLES 2 renderer for 2D
This commit adds a new rendering backend, GLES2, and adds a
project setting to enable it.

Currently this backend can only be used on the X11 platform,
but integrating into other platforms is planned.
2018-03-01 15:12:30 +01:00