Commit graph

1028 commits

Author SHA1 Message Date
Bastiaan Olij
179f483782 Fix issues when rendering panoramic sky in stereoscopic 2017-10-10 22:51:37 +11:00
Ferenc Arn
12596cb5bc Fix anisotropic GGX D function, and introduce and use anistropic GGX G function.
Also fixed isotropic GGX G function with Schlick approximation, and added a commented out version without the approximation.
Added references.
2017-10-09 12:29:05 -04:00
Rémi Verschelde
9f26733b44 Merge pull request #11827 from hi-ogawa/fix-shader-type-error
Fix type error in subsurface scattering shader code
2017-10-09 12:25:46 +02:00
Rémi Verschelde
e8b9cca614 Merge pull request #11810 from marcelofg55/osx_export_improv
OS X export code improvements
2017-10-09 12:20:39 +02:00
Hiroshi Ogawa
1967972f6e Track LightInstance::shadow_atlases so that it will be freed properly 2017-10-09 09:51:10 +09:00
Hiroshi Ogawa
2c966493c5 Fix front face definition 2017-10-09 09:18:32 +09:00
Hiroshi Ogawa
8cf5f615f5 Fix type error in subsurface scattering shader code 2017-10-04 19:47:45 +09:00
Juan Linietsky
b12455cde8 Avoid failed viewport when size is too smal, fixes #9891 2017-10-03 17:36:14 -03:00
Marcelo Fernandez
4b695c3bdf OS::execute can now read from stderr too when executing with a pipe 2017-10-03 15:09:04 -03:00
Ferenc Arn
f48b162a6b Various clean ups and cosmetic changes in scene.glsl.
Use self-documenting names for variables which are otherwise confusing. Also avoid recalculating certain terms.
2017-10-03 11:02:39 -04:00
Andreas Haas
132ba0ed97 Merge pull request #11568 from endragor/loggers
Extract logging logic
2017-10-02 23:51:26 +02:00
Andreas Haas
1e9465096d Merge pull request #11700 from tagcup/clearcoat_fix
Fix clearcoat without Schlick-GGX specular.
2017-10-02 22:51:51 +02:00
Poommetee Ketson
3f4e973a60 Merge pull request #11716 from marcelofg55/coreaudio_driver
Merged iphone and osx audio drivers into drivers/coreaudio
2017-10-02 23:37:55 +07:00
Leon Krause
36298186f4 Merge pull request #11774 from ISylvox/fix-msvc-build
Fixed MSVC build issue introduced by c864b78
2017-10-02 17:06:21 +02:00
Indah Sylvia
a20ddfdb63 Fixed MSVC build issue introduced by commit c864b782c0 2017-10-02 19:10:07 +07:00
Juan Linietsky
66987d6878 missing PI division on vertex shader 2017-10-02 09:09:32 -03:00
Juan Linietsky
1b358783ce Slight proposed fixes to PBR. 2017-10-01 21:51:11 -03:00
Juan Linietsky
c864b782c0 Using advise from Matias, left the 0-1 range for lights, divisiom by PI, and multiplied lights by PI internally. 2017-10-01 20:33:38 -03:00
Juan Linietsky
c9a925c4e0 Switched Burley/Lambert, and restored diffuse term to 0-1 range for compatibility. 2017-10-01 19:08:49 -03:00
Juan Linietsky
99a464ceb4 Merge pull request #11694 from tagcup/lambert_normalization
Ensure that Lambert is energy conserving.
2017-10-01 12:18:40 -03:00
Ferenc Arn
ece18153c6 Add missing N.L factor to Burley's contribution to radiance. 2017-10-01 10:20:57 -04:00
Ferenc Arn
dfaf071ae3 Fix environmental BRDF. 2017-09-30 20:28:30 -04:00
Marcelo Fernandez
12d40fa03f Merged iphone and osx audio drivers into drivers/coreaudio 2017-09-30 02:16:42 -03:00
Bastiaan Olij
cf56711a7e near and far are reserved for near and far pointers in MSVR 2017-09-30 10:43:34 +10:00
Juan Linietsky
d4e20555e8 Ability to set a custom FOV makes it possible to use sky on orthogonal view. Closes #9186 2017-09-29 18:56:52 -03:00
Ferenc Arn
3e09b9b335 Fix clearcoat without Schlick-GGX specular.
Fixes #11698.
2017-09-29 10:59:05 -04:00
Ferenc Arn
33c600fedc Ensure that Lambert is energy conserving.
Also remove the diffuse_color factor in Oren-Nayar (which was already taken care of below, oops).
2017-09-29 09:47:06 -04:00
Gilles Roudiere
2c5fa0947d Merge pull request #11672 from tagcup/fix_oren_nayar
Fix Oren-Nayar diffuse.
2017-09-29 13:47:38 +02:00
Ferenc Arn
8cb67b03a9 Fix Oren-Nayar diffuse. 2017-09-28 19:26:01 -04:00
Indah Sylvia
392a94686c Fixed typo: 'texure' to 'texture' 2017-09-29 04:40:01 +07:00
Juan Linietsky
4f39ce32b9 Fixes to light shaders, should work now.. 2017-09-27 21:45:47 -03:00
Ferenc Arn
ae78413bb1 Avoid pow in Burley diffuse. 2017-09-26 22:15:38 -04:00
Elliott Sales de Andrade
45a9a680a3 Use BoolVariable for third-party options. 2017-09-25 14:36:30 -04:00
Elliott Sales de Andrade
ffab67b8da Use BoolVariable in target/component/advanced options. 2017-09-25 14:36:02 -04:00
Ruslan Mustakov
1a2311e350 Extract logging logic
Previously logging logic was scattered over OS class implementations
with plenty of duplication. Major changes in this commit:

 - Extracted logging logic into a separate Logger hierarchy. It allows
   easy configuration of logging mechanism depending on compile-time or
   run-time configuration.

 - Implemented RotatedFileLogger which is usually used with StdLogger,
   providing persistency of logs. It is often important to be able to
   obtain logs of the game even in production to be able to understand
   what happened prior to some problem. On mobile there previously was
   no way to obtain the logs aside from having the device connected to
   your machine.

 - flush() is not performed in release mode for every logged line. It
   is only performed for errors.
2017-09-25 16:19:21 +07:00
Juan Linietsky
81c9cfdc1b Added light affect parameter to baked AO 2017-09-23 23:10:34 -03:00
Juan Linietsky
d3ea92257d -Fixed redraw always on 3D viewprot bug
-Changed manipulation inertia default values. Do not touch them again or I'll cut your fingers and eat them.
2017-09-23 17:28:28 -03:00
Juan Linietsky
fbabef6da3 Fixes to rim parameter in shader 2017-09-23 08:27:48 -03:00
Juan Linietsky
bf371dcb32 Added proximity and distance fade to SpatialMaterial 2017-09-21 15:20:28 -03:00
letheed
5ad9be4c24 Rename pos to position in user facing methods and variables
Rename user facing methods and variables as well as the corresponding
C++ methods according to the folloming changes:

* pos -> position
* rot -> rotation
* loc -> location

C++ variables are left as is.
2017-09-20 13:11:10 +02:00
Rémi Verschelde
53bbc046ee Merge pull request #11252 from marcelofg55/fix_noaudio_crash
Fix crash when no audio driver is available
2017-09-17 22:48:22 +02:00
Marcelo Fernandez
3528b1e571 Fix x11 exported executables not getting the +x flag 2017-09-17 14:40:58 -03:00
Rémi Verschelde
07d18a0076 Merge pull request #11276 from hpvb/fix-11270
Only do 'drive' discovery on X11
2017-09-17 18:44:25 +02:00
Hein-Pieter van Braam
65af96eab0 Only do 'drive' discovery on X11
As it turns out older versions of the Android NDK have mntent.h but not
a complete implementation. If it did work it would most likely give the
wrong results on Android anyway.

This commit enables the UNIX drive discovery only for X11

We also missed '/run/media' (default for gnome desktops) in the list of
places to look for 'drives' on Linux. Add that to the list also.

This fixes #11270
2017-09-14 23:04:30 +02:00
Wilson E. Alvarez
072e379ffe Renamed function arguments to keep them consistent between declaration and implementation 2017-09-14 13:49:15 -04:00
Marcelo Fernandez
7a4c0ff35e Fix crash when no audio driver is available 2017-09-13 20:54:55 -03:00
Rémi Verschelde
cc7c892bca Merge pull request #11160 from marcelofg55/drive_funcs_x11
Implemented DirAccess get_drive and get_drive_count for Linux
2017-09-13 20:04:54 +02:00
Rémi Verschelde
e73e00d369 Style: Apply clang-format to @reduz's changes
[ci skip]
2017-09-13 09:13:34 +02:00
Marcelo Fernandez
e5f905a735 Implemented DirAccess get_drive and get_drive_count for Linux 2017-09-12 23:43:08 -03:00
Marcelo Fernandez
730d36f350 Fixed issues with surround sound on audio server 2017-09-12 15:13:28 -03:00
Rémi Verschelde
8b76199b4b Merge pull request #10897 from themindoverall/fix_box_select
Fix draw_rect when width or height < 0
2017-09-12 15:36:23 +02:00
Juan Linietsky
1c5376ae59 Many fixes to visual script, changed virtuals override for a proper selector. 2017-09-12 07:58:54 -03:00
Rémi Verschelde
aabbd00284 Merge pull request #10908 from hpvb/fix-unused-variables
Fix unused variable warnings
2017-09-12 12:55:53 +02:00
Rémi Verschelde
cf941fdc35 Merge pull request #11026 from hpvb/fix-assign-in-if
Remove assignment and declarations in if statements
2017-09-12 11:57:49 +02:00
Rémi Verschelde
2b50dc5d4f Merge pull request #11057 from hpvb/fix-various-warnings
Fix various assorted warnings
2017-09-12 11:39:47 +02:00
Rémi Verschelde
3941e01a57 Merge pull request #11041 from hpvb/fix-clang-format-error
Fix serveral recent new clang-format errors

[ci skip]
2017-09-12 11:16:36 +02:00
supagu
e7c5706f71 DirAccess constructor sets current_dir to an absolute path 2017-09-10 20:03:26 +09:30
Hein-Pieter van Braam
b2a38854fd Fix unused variable warnings
The forth in my quest to make Godot 3.x compile with -Werror on GCC7
2017-09-08 15:03:53 +02:00
Hein-Pieter van Braam
8230bf0a2f Remove assignment and declarations in if statements
After discussing with @reduz and @akien-mga it was decided that we do
not allow assignments or declarations in if statements. This PR removes
the instances of this I could find by automated means.
2017-09-08 14:59:15 +02:00
Hein-Pieter van Braam
67a706fc1b Fix various assorted warnings
Fix various warnings that don't have enough instances to merit
individual commits. Also fixes a potential bug in audio_server.cpp.
2017-09-08 14:57:48 +02:00
Juan Linietsky
5ca3af3371 Ability to use a sky for reflection together with a background color. 2017-09-07 20:45:37 -03:00
Juan Linietsky
c023a132d0 Fixed orthogonal projection in all effects and post processes 2017-09-07 20:16:33 -03:00
Hein-Pieter van Braam
5e18967d77 Fix serveral recent new clang-format errors 2017-09-08 00:20:16 +02:00
Juan Linietsky
eedb39091a Several fixes to directional shadows, closes #10926
Added option to change directional light range mode, between optimized and stable. For Orthogonal, you might need to use optimized.
2017-09-07 18:00:47 -03:00
Juan Linietsky
b19b7aebf7 Merge pull request #11027 from hpvb/fix-11022
Fix EOF in wav file importer
2017-09-07 07:53:56 -03:00
Juan Linietsky
8047127bc6 Force redraw when HDR auto exposure is enable in all frames, fixes #10784 2017-09-06 23:02:06 -03:00
Juan Linietsky
dd854768da -Fix folow surface in subsurface scattering, closes #10696
-Fixed filter kernels of subsurface scattering so quality settings make more sense
2017-09-06 21:45:02 -03:00
Hein-Pieter van Braam
cbedb54408 Fix EOF in wav file importer
In #10973 I reset the state of the stream in get_pos() assuming that the
ftell failing would cause proper error checking. This is not how this
class was designed, however. This commit fixes the get_8() method to
not return unitialized data on eof, and removes the wrong error resets
added in #10973.

This fixes #11022
2017-09-07 00:26:17 +02:00
Juan Linietsky
ddadc782ba Fix frame selection in 2D particles, closes #10668 2017-09-06 08:31:11 -03:00
supagu
f4994e750d Further symlink fixes 2017-09-06 18:09:27 +09:30
Juan Linietsky
e192c1a7d3 Fix directional vertex shaded light which was using normal instead of light color, closes #10608 2017-09-05 17:31:09 -03:00
Juan Linietsky
7eb8760477 Added support for for, break and continue. Closes #10560, closes #10661 2017-09-05 15:25:34 -03:00
Rémi Verschelde
54e81c7955 Merge pull request #10990 from MednauN/unshaded-fix
Fix unshaded materials render
2017-09-05 15:51:35 +02:00
Evgeny Zuev
094237eca0 Fix unshaded materials render 2017-09-05 12:19:15 +07:00
Juan Linietsky
2802dced84 Automatically redraw when shaders using TIME are visible, fixes #10554 2017-09-05 00:30:39 -03:00
Juan Linietsky
e611ff5f01 Fix opaque pre pass, closes #10472 2017-09-04 20:27:45 -03:00
Rémi Verschelde
44adf75cd5 Merge pull request #10986 from hpvb/fix-unix-file-open
Fix UNIX file open
2017-09-05 01:18:53 +02:00
Hein-Pieter van Braam
5fed954a1b Fix UNIX file open
In #10973 I refactored FileAccessUnix::_open() but I accidentally made
it impossible to create new files.

This fixes that and fixes #10984
2017-09-05 01:14:14 +02:00
Rémi Verschelde
27feafbe12 Merge pull request #10973 from hpvb/fix-file-access-unix
Make UNIX file access more correct
2017-09-05 00:33:20 +02:00
Rémi Verschelde
77d5013f94 Merge pull request #10974 from henkz1/gles-10963
Don't compare float to int
2017-09-05 00:12:43 +02:00
Rémi Verschelde
e0801111c4 Merge pull request #10883 from supagu/symlink2
Another take at fixing symlinks
2017-09-04 23:27:32 +02:00
Hein-Pieter van Braam
a7c2ff5c94 Make UNIX file access more correct
Check for errors in the POSIX recommended ways.
2017-09-04 22:23:29 +02:00
Henrik Andersson
e0a19a77e5 Don't compare float to int 2017-09-04 22:21:55 +02:00
Juan Linietsky
281fb4e4fb Added transmission shader parameter. 2017-09-03 10:30:37 -03:00
Fabian Mathews
dccdef1327 Another take at fixing symlinks 2017-09-03 13:46:05 +09:30
Chris Serino
3d6ccda188 Fix draw_rect when width or height < 0. Fixes #10849 2017-09-02 11:58:04 -05:00
Rémi Verschelde
8e75e7311b Merge pull request #10858 from letheed/add-shadow_filter-variant
add shadow_filter variant PCF7
2017-09-02 12:13:01 +02:00
Hein-Pieter van Braam
9c63ab99f0 Fix use of unitialized variables
The second in my quest to make Godot 3.x compile with -Werror on GCC7
2017-09-02 01:59:26 +02:00
Rémi Verschelde
dac150108a Merge pull request #10846 from hpvb/fix-sign-compare
Fix signed and unsigned comparisons
2017-09-01 21:52:55 +02:00
Rémi Verschelde
3694c58d3c Merge pull request #10775 from marcelofg55/buffersize_fixes
Corrections to audio buffer size calculations
2017-09-01 21:41:24 +02:00
Juan Linietsky
6fa6149517 Fix some argument ordering, closes #10010 2017-09-01 15:01:17 -03:00
Juan Linietsky
8f30c52a37 Removed ontop property, added a material rendering priority system. Fixes #9935, closes #10135 2017-09-01 13:01:08 -03:00
Marcelo Fernandez
f231eadc9e Corrections to audio buffer size calculations 2017-09-01 11:12:13 -03:00
Poommetee Ketson
ed606ded52 Fix files header 2017-09-01 21:07:55 +07:00
letheed
3a188015be add shadow_filter variant PCF7 2017-09-01 15:01:24 +02:00
Hein-Pieter van Braam
f9467ec1ea Fix signed and unsigned comparisons
The first in my quest to make Godot 3.x compile with -Werror on GCC7
2017-09-01 08:13:12 +02:00
Juan Linietsky
51066fcde7 Merge pull request #10305 from H4kor/gles3
Fixes a bug in multimesh_instance_get_color
2017-08-31 08:44:22 -03:00
Rémi Verschelde
82208c1e8b Merge pull request #10417 from bojidar-bg/x-fix-tilemap-transpose
Implement texture UV transpose in the gles3 renderer
2017-08-31 13:17:39 +02:00
Rémi Verschelde
f1e3dec442 Merge pull request #10624 from letheed/master
Fix shadow filter pcf5 implemented as pcf7
2017-08-31 11:01:57 +02:00
Juan Linietsky
a1d7c496b9 Improved default directional shadow params, added bias split scale, closes #9828 2017-08-30 08:08:44 -03:00