Commit graph

140 commits

Author SHA1 Message Date
Karroffel 2281942fb3 Added methods for opening dynamic libraries to OS 2017-03-29 23:05:15 +02:00
Andreas Haas c0b6756875
Input: Remove usage of platform dependent event IDs.
The ID property for InputEvents is set by `SceneTree` when sending the event down the tree.
So there's no need for the platform specific code to set this value when it will later be overriden anyway...
2017-03-26 15:59:32 +02:00
Rémi Verschelde 5dbf1809c6 A Whole New World (clang-format edition)
I can show you the code
Pretty, with proper whitespace
Tell me, coder, now when did
You last write readable code?

I can open your eyes
Make you see your bad indent
Force you to respect the style
The core devs agreed upon

A whole new world
A new fantastic code format
A de facto standard
With some sugar
Enforced with clang-format

A whole new world
A dazzling style we all dreamed of
And when we read it through
It's crystal clear
That now we're in a whole new world of code
2017-03-05 16:44:50 +01:00
Julian Murgia 94103c0c02 Add API to access battery power state
Done:
- X11, server (tested)
- Windows (developed, would be nice to retest)
- OSX (not tested)
Prepared (not developed):
- Android (code is here, but may not compile)
- iphone
- winrt
- bb10
- haiku
- javascript
2017-03-04 18:04:29 +01:00
Rémi Verschelde 2d3dd6f6ee Merge pull request #7854 from neikeq/pr-execute-iter
Replace misuse of list iteration
2017-02-26 20:23:10 +01:00
Rémi Verschelde ca805744fb Merge pull request #7848 from hpvb/fix-7839
Windows: Close audiodriver sooner on exit
2017-02-26 20:18:49 +01:00
Juan Linietsky de0045cf1b -renamed globals.h to global_config.cpp (this seems to have caused a few modified files)
-.pck and .zip exporting redone, seems to be working..
2017-02-21 00:06:30 -03:00
Ignacio Etcheverry 0cd309c5c7 Replace misuse of list iteration 2017-02-20 19:53:14 +01:00
Hein-Pieter van Braam 04e51859f0 Windows: Close audiodriver sooner on exit
In #7839 I see the same error that was fixed in #7833 occuring on the
Windows platform. This moves the audio driver closing to the same place
in OS_Windows::finalize() as it is in OS_X11::finalize()

This fixes #7839
2017-02-19 20:45:17 +01:00
Rémi Verschelde 3cab47adba Merge pull request #7782 from SaracenOne/windows_relative_cursor_fix
Fix relative cursor data in CAPTURED mouse mode on Windows.
2017-02-12 23:26:19 +01:00
Rémi Verschelde 43d947f54b Merge pull request #7771 from Limb/winaudiodriver
Close out audio drivers when exiting on Windows.
2017-02-12 23:24:09 +01:00
Rémi Verschelde dc5f978f28 Merge pull request #7770 from Limb/removedx9
Removed DX9 Rasterizer in windows
2017-02-12 23:23:34 +01:00
Saracen 523b69771b Fix glitches when sampling relative cursor data in CAPTURED mouse mode on Windows. 2017-02-11 03:54:36 +00:00
Kenneth Lorthioir bd893f346a Close out audio drivers when exiting.
Prevents a crash when closing the project manager.
2017-02-09 10:40:13 -05:00
Kenneth Lorthioir 091202589c Removed DX9 Rasterizer in windows.
This doesn't seem to be needed anymore and the code to free the unused
rasterizer was throwing a memory violation since it was getting set to a
value somehow.
2017-02-09 10:27:40 -05:00
Kenneth Lorthioir 6961ed21bb Fixed compilation issues with Visual Studio 2017-02-08 18:14:52 -05:00
Ilija Boshkov 1005a56e5a Added focus tracking in X11 and Windows classes, added new confined mouse mode (#7162) 2017-01-25 19:21:41 +01:00
Rémi Verschelde 0a9aee6b1d Merge pull request #7558 from Faless/fix_windows_output
Fix gibberish output for windows/mingw.
2017-01-16 19:28:03 +01:00
Rémi Verschelde 7b059965e8 Adapt platforms to AudioServer refactoring
Fixes compilation on Windows and likely other platforms (at least
as far as AudioServer changes were concerned), though they were
not tested.
2017-01-16 19:19:45 +01:00
Fabio Alessandrelli 3df934acad Fix gibberish output for windows/mingw.
%ls should be used instead of %s or %S to speficy narrow/wide charstring
in wprintf fwprintf

Fixes #6252
2017-01-16 18:56:28 +01:00
Juan Linietsky b400c69cd4 Oops! Audio engine has vanished :D 2017-01-15 16:07:51 -03:00
Rémi Verschelde 93ab45b6b5 Style: Fix whole-line commented code
They do not play well with clang-format which aligns the `//` part
with the rest of the code block, thus producing badly indented commented code.
2017-01-14 14:52:23 +01:00
Juan Linietsky a97551902e rename Input.get_mouse_speed() to Input.get_last_mouse_speed() 2017-01-13 19:24:28 -03:00
Andreas Haas d963fa9a01
More fixes to Joypad renaming.
Windows did not compile anymore because DI8DEVTYPE_JOYPAD obviously isn't defined in the directx headers ^^
I also did the same renaming as in #7473 for the windows platform and reverted the changes in the gamepad
mappings.
2017-01-08 23:52:49 +01:00
Juan Linietsky 547a57777b renamed joystick to joypad everywhere around source code! 2017-01-08 17:06:33 -03:00
Rémi Verschelde 6323779596 Windows: Define _WIN32_WINRT to 0x0600 (Vista)
Passed as a compiler define to be sure it is always define before windows.h
is loaded. This means that Godot officially requires Vista API or later, it will
not work on Windows XP or earlier.

Also fix a bogus check for Windows 7 API.
2017-01-08 20:41:26 +01:00
Juan Linietsky 263d5fcff8 Added missing readers writers lock to windows, should compile and run again.. 2017-01-08 11:13:12 -03:00
Juan Linietsky aa60e02cf6 fixes compilation in windows? 2017-01-08 10:20:23 -03:00
Juan Linietsky 2ab83e1abb Memory pool vectors (DVector) have been enormously simplified in code, and renamed to PoolVector 2017-01-07 18:26:38 -03:00
Juan Linietsky 53ce643e52 -Changed memory functions, Memory::alloc_static*, simplified them, made them aligned to 16
-Changed Vector<> template to fit this.
2017-01-06 10:15:44 -03:00
Juan Linietsky 495d059a74 Merge branch 'master' of https://github.com/godotengine/godot 2017-01-05 09:18:03 -03:00
Juan Linietsky 0f7af4ea51 -Changed most project settings in the engine, so they have major and minor categories.
-Changed SectionedPropertyEditor to support this
-Renamed Globals singleton to GlobalConfig, makes more sense.
-Changed the logic behind persisten global settings, instead of the persist checkbox, a revert button is now available
2017-01-05 09:16:00 -03:00
BastiaanOlij 55d425807f First set of changes to fix compilation errors and initialise the gles3 renderer for Mac OS X. Still broken at this point. 2017-01-04 23:34:02 +11:00
Rémi Verschelde 3f3f5a5359 Merge remote-tracking branch 'origin/gles3' into gles3-on-master
Various merge conflicts have been fixed manually and some mistakes
might have been made - time will tell :)
2017-01-02 21:52:26 +01:00
Rémi Verschelde c7bc44d5ad Welcome in 2017, dear changelog reader!
That year should bring the long-awaited OpenGL ES 3.0 compatible renderer
with state-of-the-art rendering techniques tuned to work as low as middle
end handheld devices - without compromising with the possibilities given
for higher end desktop games of course. Great times ahead for the Godot
community and the gamers that will play our games!
2017-01-01 22:03:33 +01:00
reduz 72b844c349 Godot works on Windows again.. 2016-12-21 02:29:58 -03:00
Rémi Verschelde f28ff8a208 Fix console output for MinGW compilers
Reworked patch from @jay3d (#7116).
2016-11-28 15:12:54 +01:00
ISylvox b5c383fd61 vsnc --> vsync 2016-11-08 21:06:57 +07:00
George Marques 414d58e6c0
Fix the hiding of mouse cursor before interaction
Fix part of #6633
2016-10-20 20:01:28 -02:00
George Marques f3102160a1
Isolate XAudio2 driver
Now it's possible to compile for Windows platform if wanted. It's
supported only for Windows 8 or later, so it's not enabled by default.
2016-10-17 20:42:12 -02:00
Rémi Verschelde f63bf12193 Drop nedmalloc which is apparently not used anymore 2016-10-14 18:21:23 +02:00
Juan Linietsky 1527cf8c0d 2D Shaders are working again using the new syntax, though all is buggy in general 2016-10-10 18:31:01 -03:00
Juan Linietsky 22d83bc9f6 Begining of GLES3 renderer:
-Most 2D drawing is implemented
-Missing shaders
-Missing all 3D
-Editor needs to be set on update always to be used, otherwise it does not refresh
-Large parts of editor not working
2016-10-03 21:35:16 +02:00
Rémi Verschelde 90f4e76a46 Merge pull request #6479 from RandomShaper/improve-debug-focus
Improve debug focus behavior
2016-10-03 11:36:01 +02:00
Marc Gilleron 0c09de3ef1 Windows: prevent huge prints from crashing the engine 2016-09-29 03:15:12 +02:00
Pedro J. Estébanez 66dac878ac Improve debug focus behavior
Fix focusing debugged game on Windows
Add re-focusing editor on continue
2016-09-14 04:02:18 +02:00
Mario Schlack f0b6a242cc Hide the mouse cursor when MOUSE_MODE_CAPTURED is activated. 2016-08-29 13:14:38 +08:00
Rémi Verschelde fd659e869b Windows: Make alert message box use MB_TASKMODAL
This flag pauses the current running thread, allowing for the user to see the
alert and acknowledge it before the thread continues (and e.g. crashes :)).

Thanks to @SuperUserNameMan for finding it.
Ref: https://msdn.microsoft.com/en-us/library/windows/desktop/ms645505(v=vs.85).aspx
2016-07-26 15:16:45 +02:00
George Marques 7be70c5a3c
Avoid changing position when the window is fullscreen 2016-07-24 12:07:59 -03:00
Rémi Verschelde b623acb718 Merge pull request #5841 from vnen/fix-windows-wheel
Fix mouse wheel event position on Windows
2016-07-21 17:31:24 +02:00