Commit graph

2163 commits

Author SHA1 Message Date
Rémi Verschelde
f676d7509e
Merge pull request #34262 from clayjohn/default_point_size
Add a default POINT_SIZE
2019-12-12 06:45:31 +01:00
Bojidar Marinov
eec7702711
Flip cull mode when rendering flipped Light2D and LightOccluder2D
Fixes #32993
2019-12-11 23:28:35 +02:00
Rémi Verschelde
c320a82213 SCons: Add 'split_libmodules' option to workaround linker issue
The new 'split_libmodules=yes' option is useful to work around linker
command line size limitations when linking a huge number of objects.
We're currently over 64k chars when linking libmodules.a on Windows
with MinGW, which triggers issues as seen in #30892.

Even on Linux, we can also reach linker command line size limitations
by adding more custom modules.

We force this option to True for MinGW on Windows, which fixes #30892.

Additional changes to lib splitting:

- Fix linking of the split module libs with interdependent symbols,
  hacking our way into LINKCOM and SHLINKCOM to set the `--start-group`
  and `--end-group` flags.
- Fix Python 3 compatibility in `methods.split_lib()`.
- Drop seemingly obsolete condition for 'msys' on 'posix'.
- Drop the unnecessary 'split_drivers' as the drivers lib is no longer
  too big since we moved all thirdparty builds to modules.

Co-authored-by: Hein-Pieter van Braam-Stewart <hp@tmm.cx>
2019-12-11 15:40:28 +01:00
clayjohn
676f647c74 Add a default POINT_SIZE 2019-12-10 23:08:20 -08:00
Rémi Verschelde
435cced7d8
Merge pull request #34238 from clayjohn/GLES2-use-renderbuffer-post-process
Use renderbuffer depth for post-process buffers when appropriate
2019-12-10 17:16:40 +01:00
Fabio Alessandrelli
ab1bfb9007 NetSocket set_broadcast_enabled returns Error enum 2019-12-10 12:11:52 +01:00
clayjohn
fd31cebcbe Use renderbuffer depth for post-process buffers when appropriate 2019-12-09 22:19:11 -08:00
clayjohn
e8d652f160 Force 32 bit depth buffer for WebGL 2019-12-09 22:14:12 -08:00
Rémi Verschelde
cd07a34598 GLES3: Properly unbind buffers after draw commands
Patch provided by @oeleo1.

Fixes #34120.
2019-12-09 09:25:20 +01:00
Rémi Verschelde
fbfd56c247 GLES2: Fix uninitialized members in ShaderGLES2::Version
Fixes #34109.
2019-12-05 09:15:31 +01:00
Rémi Verschelde
745a8915fc Properly orphan polygon index buffer after binding (take 2)
Follow-up to #34088, patch by @oeleo1 from
https://github.com/godotengine/godot/issues/34065#issuecomment-561530896
2019-12-04 12:16:50 +01:00
clayjohn
b2dfbd77ec properly orphan polygon index buffer after binding 2019-12-03 07:54:25 -08:00
Rémi Verschelde
10bae7c05b
Merge pull request #33857 from nekomatata/polygon-2d-antialiasing
Fixed antialiased option for Polygon2D
2019-12-03 07:51:16 +01:00
Rémi Verschelde
65e6efaa3b
Merge pull request #33836 from clayjohn/blinn-fix
Fix Specular Blinn function
2019-12-03 07:50:37 +01:00
Rémi Verschelde
d53e3d3acc
Merge pull request #33985 from nekomatata/shadow_viewport
Disable shadow map sampling when shadows are not used in GLES3
2019-12-02 09:28:42 +01:00
PouleyKetchoupp
f5e81b894a Removed duplicated conditional in GLES2 2019-11-29 06:32:55 +01:00
PouleyKetchoupp
299b85c46f Disable shadow map sampling when shadows are not used in GLES3
Fixes #20742
2019-11-29 06:21:17 +01:00
PouleyKetchoupp
e6ebc43d72 Fixed antialiased option for Polygon2D / Line2D
Polygon2D:
The property wasn't used anymore after switching from canvas_item_add_polygon() to canvas_item_add_triangle_array() for drawing.

Line2D:
Added the same property as for Polygon2D & fixed smooth line drawing to use indices correctly.

Fixes #26823
2019-11-28 22:57:27 +01:00
Rémi Verschelde
da880520ca
Merge pull request #33963 from clayjohn/GLES3-sky-mipmaps-on-mobile
Fix radiance map generation on mobile
2019-11-28 09:06:38 +01:00
clayjohn
192aacd5d7 Fix radiance map generation on mobile 2019-11-27 22:18:21 -08:00
George Marques
c51fe7f7cd
Use ANGLE multisample extensions for UWP 2019-11-26 13:55:19 -03:00
clayjohn
5ab3b61520 Restructure depth_internalformat code to work on mobile
This changes the code path so that `glRenderBufferStorage*` always uses
values appropriate for renderbuffers and `glTexImage2D` never uses an
internalformat meant for buffers.

Fixes #33825.
2019-11-23 18:08:19 -08:00
Rémi Verschelde
bb1d75f55e glTexImage2D: Fix confusion between format and internal format
The `format` parameter is similar to `internalFormat` but takes different
values, and especially only `GL_DEPTH_COMPONENT` for depth, without size
specifier.

Cf. https://www.khronos.org/registry/OpenGL-Refpages/es3.0/html/glTexImage2D.xhtml

Fixes a regression from #33278 and another occurrence.
2019-11-23 19:38:31 +01:00
clayjohn
334d41d7cc Fix Specular Blinn function 2019-11-22 22:03:26 -08:00
clayjohn
203fb1b348 Fix GL error by properly using float uniform 2019-11-21 07:44:09 -08:00
clayjohn
4d6737ec73 Fix bugs introduced by IBL fixes 2019-11-20 22:54:44 -08:00
Rémi Verschelde
083d088de3
Merge pull request #33583 from qarmin/fix_overflows_unitialized
Fix some overflows and unitialized variables
2019-11-20 21:31:12 +01:00
Rafał Mikrut
99d8626f4a Fix some overflows and unitialized variables 2019-11-20 16:22:16 +01:00
Rémi Verschelde
3be6e76f22
Merge pull request #33668 from clayjohn/Fix_environment_mapping_issues
Fix issues with environment mapping
2019-11-20 08:45:53 +01:00
clayjohn
cd40154890 Fix issues with environment mapping 2019-11-19 22:30:48 -08:00
Rémi Verschelde
7a0228fbba
Merge pull request #33720 from BastiaanOlij/fix_gles2_rgb8
Need to use GL_RGB8 and GL_RGBA8 as the internal format for GLES2
2019-11-19 11:12:03 +01:00
Bastiaan Olij
15cd81dc69 Need to use GL_RGB8 and GL_RGBA8 as the internal format for GLES2 2019-11-19 20:57:18 +11:00
Rémi Verschelde
6536105af2
Merge pull request #33527 from clayjohn/GLES2-bufferdata_optimization
Improve glBufferSubData usage where safe
2019-11-19 09:36:30 +01:00
clayjohn
14b06fc207 Fix negative light flickering 2019-11-17 22:18:54 -08:00
clayjohn
1253a33423 Improve glBufferSubData usage where safe 2019-11-11 16:38:41 -08:00
Rémi Verschelde
6b1628f9fc
Merge pull request #33517 from madmiraal/fix-_MSG-macros
Send *_MSG macros' explanations directly to the _err_print_error().
2019-11-11 13:27:51 +01:00
Rémi Verschelde
4b8feff594
Merge pull request #33518 from BastiaanOlij/msaa_ext_modes
Add MSAA mode for Quest
2019-11-11 11:46:50 +01:00
Bastiaan Olij
4e2343160c Add special external MSAA modes for GLES2 Rift S/Quest and OpenXR optimisation 2019-11-11 21:02:06 +11:00
Marcel Admiraal
d18b2e599d Remove all uses of ERR_EXPLAIN macros. 2019-11-11 10:24:04 +01:00
PouleyKetchoupp
90b6062ebb Handle missing file properly when checking for case mismatch
This was causing false alarms to be randomly reported on Windows for files that didn't exist.
2019-11-10 09:51:09 +01:00
Bastiaan Olij
add5eaca43 Make MSAA work with external texture 2019-11-08 23:27:48 +11:00
Bastiaan Olij
f7cba26a52 Revert "fix #33188 MSAA depth buffer not used for external texture"
This reverts commit 418b035dda.
2019-11-08 22:47:36 +11:00
Rémi Verschelde
a3ac7a94f0
Merge pull request #33291 from NeoSpark314/fix_#33188
fix #33188 MSAA depth buffer not used for external texture
2019-11-08 09:53:22 +01:00
Rémi Verschelde
47389c3a16 Partial revert of #32657, undoing line shifting by 0.5
As discussed in #32657, this can't be done here as lines can be used
with a canvas scale, and this breaks them.
A suggestion is to do the pixel shifting at matrix level instead.

Fixes #33393.
Fixes #33421.
2019-11-07 15:43:04 +01:00
Holger Dammertz
418b035dda fix #33188 MSAA depth buffer not used for external texture
When rendering to an external texture and MSAA was active (as happened
in the Oculus Mobile ARVR plugin) no MSAA was rendered as the correct
depth buffer and multisample texture target was not used.
This also fixes https://github.com/GodotVR/godot_oculus_mobile/issues/54
2019-11-04 20:14:52 +01:00
Rémi Verschelde
c1b0800784
Merge pull request #33278 from clayjohn/GLES2-depth-format
Fix depth format on Android in GLES2
2019-11-03 07:56:38 +01:00
clayjohn
bc32779542 Fix depth format on Android in GLES2 2019-11-02 21:58:30 -07:00
Rémi Verschelde
d89f24b6c9
Merge pull request #33259 from Chaosus/remove_gles2_switch_op
Removed switch operator from GLES2 shader back-end
2019-11-02 19:28:18 +01:00
Yuri Roubinsky
6b7f8558d9 Removed switch operator from GLES2 shader back-end 2019-11-02 12:43:32 +03:00
Rafał Mikrut
9ddb3265e1 Fix some crashes, overflows and using variables without values 2019-11-01 16:16:31 +01:00
clayjohn
033ae8a543 When framebuffer allocation fails for MSAA in GLES2 revert to normal without ERR_FAIL 2019-10-30 07:45:09 -07:00
Rémi Verschelde
63c5cd7eb8
Merge pull request #33104 from qarmin/fix_some_crashes
Fix some crashes and using null pointers
2019-10-28 08:37:59 +01:00
Rémi Verschelde
826ffc26c9
Merge pull request #33097 from clayjohn/GLES2-HTML-sampler_limit
Fixed using compressed textures and add work around for firefox webgl mesa sampler limit
2019-10-28 08:19:37 +01:00
Rafał Mikrut
e53e1c566a Fix some crashes and using null pointers 2019-10-28 08:07:29 +01:00
clayjohn
7b3d098b2b Fixed using compressed textures and add work around for firefox webgl mesa sampler limit 2019-10-27 23:53:52 -07:00
clayjohn
51db564811 use proper texture in Android MSAA 2019-10-27 16:50:15 -07:00
Rémi Verschelde
ad685960da
Merge pull request #32617 from Faless/fix/fopen_close_exec
Disable file descriptor sharing with subprocs.
2019-10-26 23:11:41 +02:00
Rémi Verschelde
3eb8bd08ec
Merge pull request #32657 from ptrojahn/lines
Fix draw_rect
2019-10-26 23:09:24 +02:00
Rémi Verschelde
3556876c08
Merge pull request #33093 from clayjohn/GLES2-HTML-shadows
Fix shadow mapping with RGBA textures on html
2019-10-26 22:07:46 +02:00
clayjohn
6ec7686a0c Fix shadow mapping with RGBA textures on html 2019-10-26 10:17:22 -07:00
Rémi Verschelde
dba22e9788
Merge pull request #33059 from akien-mga/webgl2-resize-non-po2
WebGL 2.0: Force decompressing non power-of-2 textures with repeat/mipmap
2019-10-26 18:05:37 +02:00
Fabio Alessandrelli
d780570faf Use WSAConnect instead of connect on Windows.
The misterious windows networking stack...
Using connect instead of WSAConnect causes socket error 10022 under
certain conditions.
See: https://github.com/godotengine/webrtc-native/ (issue 6)
Having to guess, code path for connect is different then WSAConnect with
NULL extra parameters.
The only reference about weird error with this code mentions something
called "Windows Filtering Platform" but windows internals are, as
always, obscure.

This might be something to try and report to Microsoft if anyone has the
time to spare with the likely outcome of being ignored.
2019-10-25 18:13:51 +02:00
Rémi Verschelde
69003457b3 WebGL 2.0: Force decompressing non power-of-2 textures with repeat/mipmap
While OpenGL ES 3.0 and WebGL 2.0 both support non power-of-2 (NPOT)
textures in their specification, the situation seems to be less clear
about *compressed* NPOT textures using repeat or mipmap flags.

At least Chrome on Linux doesn't seem to support this combination,
and a variety of mobile hardware have similar limitations.

As a workaround, we force decompressing such textures when running on
WebGL 2.0, at the cost of loading time and memory usage.

Fixes #33058.
2019-10-25 13:01:10 +02:00
bruvzg
7b64340eb0
Fix compilation warnings in macOS build, enable warnings=extra werror=yes for macOS CI. 2019-10-24 20:37:56 +03:00
clayjohn
071bf81750 only render depth with alpha prepass on prepass 2019-10-11 22:34:10 -07:00
Paul Trojahn
bdaedb601c Fix draw_rect
OpenGL uses the diamond exit rule to rasterize lines. If we don't shift
the points down and to the right by 0.5, the line can sometimes miss a
pixel when it shouldn't. The final fragment of a line isn't drawn. By
drawing the lines clockwise, we can avoid a missing pixel in the rectangle.
See section 3.4.1 in the OpenGL 1.5 specification.
Fixes #32279
2019-10-11 10:26:53 +02:00
Rémi Verschelde
a39aeade5b
Merge pull request #32170 from puthre/ninepatch-fix
GLES2 & GLES3 Fixes ninepatch margins for high resolution textures.
2019-10-09 08:33:56 +02:00
Rémi Verschelde
02d75f99b9
Merge pull request #32616 from Faless/net/fix_close_exec
Disable socket descriptor sharing with subprocs.
2019-10-08 07:32:11 +02:00
Rémi Verschelde
e43155b44f
Merge pull request #32454 from jeronimo-schreyer/disable_unix_socket
Optional Unix Socket disable for devices that do not support it
2019-10-08 06:40:17 +02:00
Valentin Zagura
100d05cbec GLES3 Fixes for ninepatch margins when patch size is smaller than the patch texture resolution
Scaled ninepatch margins in screen space to be relative of the ninepatch size when the patch size is smaller than the patch texture resolution.
2019-10-07 13:19:27 +01:00
Fabio Alessandrelli
ad9a5ee6f1 Disable file descriptor sharing with subprocs.
On Unix systems, file descriptors are usually shared among child
processes.
This means, that if we spawn a subprocess (or we fork) like we do in
the editor any open file descriptor will leak to the new process.
This PR sets the close-on-exec flag when opening a file, which causes
the file descriptor to not be shared with the child process.
2019-10-07 11:57:44 +02:00
Fabio Alessandrelli
9c91b2051a Disable socket descriptor sharing with subprocs.
On Unix systems, sockets are like file descriptors, and file descriptors
are usually shared among child processes.
This means, that if we spawn a subprocess (or we fork) like we do in the
editor, open file descriptors will leak to the new process.
This causes issue with sockets as they might remain open and bound
(listening) when the original process closes.
2019-10-07 11:53:01 +02:00
Rémi Verschelde
234289de2b
Merge pull request #32613 from clayjohn/GLES2-canvas-bg-mode
Add canvas background mode to GLES2
2019-10-07 08:57:44 +02:00
clayjohn
77939c6e2e add canvas background mode to GLES2 2019-10-06 23:26:11 -07:00
clayjohn
cea1f13176 fix current issues with post-processing 2019-10-06 12:07:31 -07:00
Rémi Verschelde
0deccd4a65
Merge pull request #32510 from clayjohn/GLES2-fix-black-editor-and-crash
Remove glViewport call as it wasnt needed and caused crash GLES2
2019-10-03 08:16:19 +02:00
Rémi Verschelde
ce336e7e72
Merge pull request #32505 from clayjohn/GLES2-fix-probe-crash
Fix reflection probe crash in GLES2 with post-processing
2019-10-03 07:55:08 +02:00
clayjohn
a152816c52 remove glViewport call as it wasnt needed and caused crash 2019-10-02 20:21:41 -07:00
clayjohn
07fd9719bf Fix reflection probe crash in GLES2 with post-processing 2019-10-02 14:35:10 -07:00
Rémi Verschelde
642a258d54
Merge pull request #32492 from akien-mga/fix-ip-uwp
IP: Fix build error on UWP
2019-10-02 21:03:59 +02:00
Rémi Verschelde
3f32ac11cc IP: Fix build error on UWP
Fixes this error:
```
drivers\unix\ip_unix.cpp(155): error C2593: 'operator =' is ambiguous
.\core/ustring.h(177): note: could be 'void String::operator =(const CharType *)'
.\core/ustring.h(176): note: or       'void String::operator =(const char *)'
drivers\unix\ip_unix.cpp(155): note: while trying to match the argument list '(String, int)'
```
2019-10-02 13:38:02 +02:00
Yuri Roubinsky
1472fca951 Removed unnecessary shader error log messages 2019-10-02 12:37:22 +03:00
clayjohn
afaa68628a updated defaults and documentation for GLES2 glow 2019-10-01 07:55:04 -07:00
Kanabenki
add91724e6 Fix casting to uint64_t when returning unix system time 2019-10-01 11:44:26 +02:00
Jairo
fe068b61ad Optional Unix Socket disable for devices that do not support it 2019-09-30 21:15:50 -03:00
clayjohn
82f63633d1 Implement DOF blur, Glow, and BCS in GLES2 2019-09-30 08:04:31 -07:00
Ruslan Mullayanov
b4c927b514 Added an exit code to the blocking mode of OS::execute
Updated documentation accordingly.

Fixes #31881.
2019-09-26 08:12:07 +02:00
Rémi Verschelde
dec10dd776
Merge pull request #32051 from qarmin/some_error_explanation
Added some obvious errors explanations
2019-09-25 11:51:54 +02:00
qarmin
17732fe698 Added some obvious errors explanations 2019-09-25 10:28:50 +02:00
Rémi Verschelde
823c3def72 Fix copyright headers and style issues 2019-09-24 11:52:06 +02:00
Rémi Verschelde
f1146c261d
Merge pull request #31751 from clayjohn/GLES3-Viewport-crash-canvas
Throw error when canvas background is used without sample buffer
2019-09-23 15:35:31 +02:00
Rémi Verschelde
159470df08
Merge pull request #32275 from godotengine/skin_support
Added skin support and simplified APIs to override bone position + glTF 2.0 import fixes
2019-09-23 15:02:15 +02:00
Rémi Verschelde
393a0152ea
Merge pull request #32055 from qarmin/some_code_fixes
Changed some code found by Clang Tidy and Coverity
2019-09-23 10:00:31 +02:00
Rémi Verschelde
7174677fc8
Merge pull request #32259 from NeoSpark314/fix_stereo_cubemap_gles2
fix gles2 broken panorama sky on oculus quest
2019-09-22 21:18:06 +02:00
Holger Dammertz
94b0240767 fix gles2 broken panorama sky on oculus quest
This fixes an issue that was fixed for gles3 in #31419 but not applied
to gles2. The fix consists of using a constant scale for cube_normal of -1.0
instead of -1000000. It results in broken panorama rendering on the
oculus quest (see https://github.com/GodotVR/godot_oculus_mobile/issues/29)
2019-09-22 18:53:38 +02:00
qarmin
50be65bf43 Changed some code found by Clang Tidy and Coverity 2019-09-22 18:45:08 +02:00
lawnjelly
f5365aa0e1 Fix GLES2 skinning where VERTEX_TEXTURE not supported
Although the backup USE_SKELETON_SOFTWARE skinning path is currently used when float texture is not supported, the default skinning path still fails when float texture is supported but GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS is 0, i.e. the device cannot read from texture during vertex shader. This PR adds the logic to activate the SKELETON_SOFTWARE path if either of these cases occur, preventing crashes on devices which have this combination of features.
2019-09-22 15:38:20 +01:00
Rémi Verschelde
e23cb2c715
Merge pull request #32004 from raphael10241024/fix_shader_uniform
Fix gles3 shader uniform vec3 error
2019-09-19 20:09:04 +02:00
Rémi Verschelde
28265fb526
Merge pull request #31202 from azagaya/light-data
Create shadow_vec for altering shadow computation
2019-09-19 20:03:04 +02:00
Juan Linietsky
d81ddaf33e Added skin support and simplified APIs to override bone position. 2019-09-18 19:46:32 -03:00
Valentin Zagura
6ee84f53a9 GLES2 Fixes for ninepatch margins when patch size is smaller than the patch texture resolution..
Scaled ninepatch margins in screen space to be relative of the ninepatch size when the patch size is smaller than the patch texture resolution.
2019-09-17 09:51:54 +01:00
clayjohn
e65d2184b9 throw error when user tries to use Canvas background without sample buffer 2019-09-15 21:07:07 -07:00
Chaosus
1333ea2a2d Implement shader array support for varyings 2019-09-14 18:23:25 +03:00
azagaya
b835868067 Create shadow_vec for altering shadow computation
In 2.1 and 3.0, light_vec could be modified for altering shadow_computations.
But it broke shadows when rotating light. shadow_vec would do the same, but without breaking
shadows in rotated lights if not used.

Add inverse light transformation to shadow vec, so it's not affected when rotating lights;

Added usage define for shadow vec.

For shadow vec working properly when rotating a light, it's needed to multiply it by light_matrix normalized. Added usage define in order to don't do that if shadow_vec not used.
2019-09-06 13:55:49 -03:00
RaphaelHunter
b8bb5e90ea fix gles3 shader uniform vec3 error, close #30930 2019-09-06 14:06:20 +08:00
Rémi Verschelde
2beea262be
Merge pull request #31571 from NeoSpark314/tonemapping_none_option
Don't clamp color to [0, 1] in Linear tonemapping
2019-09-02 18:41:53 +02:00
Andrii Doroshenko (Xrayez)
cd99157e2e Provide error messages when PNG save fails 2019-09-01 14:16:17 +03:00
Holger Dammertz
aa3ef8893b Removed clamping of the Linear tonemapping when KEEP_3D_LINEAR
Changed the behaviour of the Linear tonemapping operator to not clamp to [0, 1] range
in the case when KEEP_3D_LINEAR is defined. This allows to render values > 1.0 in
floating point texture targets (via Viewport) for further processing or saving high
dynamic range data into files. This only works when no color conversion is active.
2019-08-29 18:14:19 +02:00
Rémi Verschelde
ebbf63a87c
Merge pull request #31746 from clayjohn/skip-vertex-transform-gles2
Fix skip_vertex_transform bug in GLES2 CPUParticles
2019-08-29 08:37:12 +02:00
clayjohn
97f66900bb Fix skip_vertex_transform bug in GLES2 CPUParticles 2019-08-28 11:57:33 -07:00
Rémi Verschelde
816ddd7817
Merge pull request #31556 from Chaosus/gles2_inverse
Implemented inverse shader function to GLES2
2019-08-26 13:52:03 +02:00
Yuri Roubinski
982becfa39 Fix hint range step for integer in shaders 2019-08-25 15:11:04 +03:00
Yuri Roubinski
4dda253ee0 Implements switch to shaders 2019-08-23 14:43:09 +03:00
Yuri Roubinski
4dcee2035a Implemented inverse shader function to GLES2 2019-08-22 08:22:49 +03:00
Rémi Verschelde
e797ae4704 FileAccessWindows: Add errno include for MinGW
Apparently MSVC is happy with ENOENT without it, but MinGW seems to
require it.
Follow-up to #31499.
2019-08-21 10:52:57 +02:00
Rémi Verschelde
7b37321ae3
Merge pull request #31499 from nekomatata/fix-new-project-metadata
Setting project metadata doesn't fail when project_metadata.cfg doesn't exist
2019-08-21 08:54:32 +02:00
PouleyKetchoupp
b49226e085 Support for file not found in ConfigFile::Load and handle a few specific cases
EditorSettings::set_project_metadata: creates project_metadata.cfg if it doesn't exist
EditorPlugin::get_config: removed (not used)

Fixes #31444
2019-08-21 08:32:55 +02:00
Rémi Verschelde
f21371d7f4
Merge pull request #31419 from NeoSpark314/fix_oculusquest_panorama
changed the constant scale of cube_normal to -1.0 instead of -1000000…
2019-08-20 13:39:26 +02:00
Rémi Verschelde
cce148b024
Merge pull request #31473 from Chaosus/shader_bug
Fix ternary operator shader compiler expression
2019-08-19 10:15:22 +02:00
Yuri Roubinski
9abf5578ee Fix ternary operator shader compiler expression 2019-08-19 08:40:54 +03:00
clayjohn
99de3906ba check if skeleton texture is already allocated before reallocating 2019-08-18 22:02:57 -07:00
Holger Dammertz
8fb80788df changed the constant scale of cube_normal to -1.0 instead of -1000000.0; this fixes a rendering issue on oculus quest and does not change the computation as the vector is normalized afterwards.
Adapted the comment above the code to reflect the change made as it already mentioned that z could be set to 1.
2019-08-17 14:01:55 +02:00
Rémi Verschelde
d3153c28f0 Replace last occurrences of 'ERR_EXPLAIN' with 'ERR_FAIL_*_MSG'
The last remaining ERR_EXPLAIN call is in FreeType code and makes sense as is
(conditionally defines the error message).

There are a few ERR_EXPLAINC calls for C-strings where String is not included
which can stay as is to avoid adding additional _MSGC macros just for that.

Part of #31244.
2019-08-17 13:31:22 +02:00
Braden Bodily
71d71d55b5 Replace 'ERR_EXPLAIN' with 'ERR_FAIL_*_MSG' in 'core/' and 'editor/'
Condensed some if and ERR statements. Added dots to end of error messages

Couldn't figure out EXPLAINC. These files gave me trouble: core/error_macros.h, core/io/file_access_buffered_fa.h (where is it?),
core/os/memory.cpp,
drivers/png/png_driver_common.cpp,
drivers/xaudio2/audio_driver_xaudio2.cpp (where is it?)
2019-08-17 12:33:15 +02:00
Rémi Verschelde
afecc0bc22
Merge pull request #31309 from raphael10241024/fix_dof
DOF can effect transparent objects now,
2019-08-16 23:20:22 +02:00
Rémi Verschelde
6c607c3564
Merge pull request #31266 from IAmActuallyCthulhu/pr/remove-redundant-author-comments
Remove redundant author doc comments
2019-08-14 13:45:54 +02:00
Yuri Roubinski
a525e3c5ce Implemented do/while loops for shaders 2019-08-13 18:39:55 +03:00
IAmActuallyCthulhu
82b9557803
Remove redundant author doc comments 2019-08-12 04:26:38 -05:00
RaphaelHunter
5ff4b13271 DOF can effect transparent objects now, close #28240 2019-08-12 15:49:02 +08:00
Rémi Verschelde
0e823cffbc
Merge pull request #31270 from nekomatata/fix-vertex-color-init-gles3
Fixed vertex color initialization with default value in GLES3
2019-08-12 09:28:40 +02:00
Rémi Verschelde
ef91119502
Merge pull request #31271 from raphael10241024/gles2_shader
Fix GLES2 canvas shader uniform error
2019-08-12 08:32:06 +02:00
PouleyKetchoupp
e852b3a271 Fixed vertex color initialization with default value in gles3
Fixes #30275, #31250
2019-08-11 17:51:47 +02:00
clayjohn
049dd309fe check for unsigned_short support for gles2 depth buffer allocation 2019-08-10 09:56:42 -07:00
RaphaelHunter
48f28c68bc fix gles2 canvas shader uniform error,close #31201 2019-08-10 21:52:51 +08:00
Rémi Verschelde
d2a67c9c1f
Merge pull request #30714 from Calinou/invert-default-fog-height
Invert and adjust the default fog height values
2019-08-08 17:20:32 +02:00
Hugo Locurcio
d1a35b5a97
Invert and adjust the default fog height values
This makes height fog appear at the bottom of the scene
(instead of the top), which is generally the expected result.

This also tweaks the fog height setting hint to be more flexible.

This closes #30709.
2019-08-07 18:21:44 +02:00
Rémi Verschelde
7b514d920d
Merge pull request #31099 from Chaosus/shader_local_const
Implemented local shader constants
2019-08-07 15:14:35 +02:00
Rémi Verschelde
ba541bceca
Merge pull request #31077 from qarmin/coverity_bugs
Change some code proposed by Coverity and Cppcheck
2019-08-07 13:49:33 +02:00
Rémi Verschelde
af935af38d
Merge pull request #30468 from SaracenOne/expose_audio_capture
Exposes capture methods to AudioServer + documentation
2019-08-07 13:27:25 +02:00
qarmin
e0b5b21863 Add some code changes/fixes proposed by Coverity and Clang Tidy 2019-08-07 12:54:30 +02:00
Rémi Verschelde
7464074cb8
Merge pull request #30987 from clayjohn/GLES2-light-negative
Implement negative for OmniLights and SpotLights in GLES2
2019-08-05 19:21:13 +02:00
Yuri Roubinski
b24b3497d6 Implemented local shader constants 2019-08-05 10:35:53 +03:00
Rémi Verschelde
d9bba94d60
Merge pull request #31053 from aaronfranke/vector2i-cleanup
Some minor Vector2i usage cleanup
2019-08-05 08:08:57 +02:00
Yuri Roubinski
393f142495 Fix GLES2 rendering 2019-08-03 21:21:29 +03:00
Aaron Franke
1a06496f45
Some Vector2i usage cleanup
Replace casting Vector2 -> Vector2i -> Vector2 with a simple call to .floor(), and some minor fixes.
2019-08-03 01:11:05 -07:00
Chaosus
8b4c538ab2 Expose several GLES3 built-ins to GLES2 2019-07-31 19:00:10 +03:00
clayjohn
96c3004855 allow omnilights and spotlights to use negative in GLES2 2019-07-30 23:44:22 -07:00
Rémi Verschelde
51b2d86685
Merge pull request #30977 from clayjohn/GLES3-screen-uv
Properly pass SCREEN_PIXEL_SIZE to canvas light shader
2019-07-31 07:45:41 +02:00
clayjohn
518f0fb190 properly pass SCREEN_PIEXEL_SIZE to canvas light shader 2019-07-30 13:45:11 -07:00
Rémi Verschelde
73d2a99761
Merge pull request #30911 from hadrien-psydk/optimize_dir_access_unix_get_next_lnk
Optimize DirAccessUnix::get_next() for some file systems (with link support)
2019-07-30 00:12:30 +02:00