diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2018-09-11 18:13:45 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2018-09-12 09:52:22 +0200 |
commit | 277b24dfb7acdb42589b931252bbe7be81c7536e (patch) | |
tree | 248dc6dfca0e27c3b03533b45753a16d186d2811 /drivers | |
parent | cc71012266f880dcf3b37e40d5f90d9ce8b7a432 (diff) |
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.
Diffstat (limited to 'drivers')
75 files changed, 198 insertions, 164 deletions
diff --git a/drivers/alsa/audio_driver_alsa.cpp b/drivers/alsa/audio_driver_alsa.cpp index 1f53d52951..50697b8834 100644 --- a/drivers/alsa/audio_driver_alsa.cpp +++ b/drivers/alsa/audio_driver_alsa.cpp @@ -32,8 +32,8 @@ #ifdef ALSA_ENABLED -#include "os/os.h" -#include "project_settings.h" +#include "core/os/os.h" +#include "core/project_settings.h" #include <errno.h> diff --git a/drivers/alsamidi/alsa_midi.cpp b/drivers/alsamidi/alsa_midi.cpp index 599470d7e0..33ad7e3f17 100644 --- a/drivers/alsamidi/alsa_midi.cpp +++ b/drivers/alsamidi/alsa_midi.cpp @@ -30,11 +30,12 @@ #ifdef ALSAMIDI_ENABLED -#include <errno.h> - #include "alsa_midi.h" -#include "os/os.h" -#include "print_string.h" + +#include "core/os/os.h" +#include "core/print_string.h" + +#include <errno.h> static int get_message_size(uint8_t message) { switch (message & 0xF0) { diff --git a/drivers/alsamidi/alsa_midi.h b/drivers/alsamidi/alsa_midi.h index 90e458a365..5741036166 100644 --- a/drivers/alsamidi/alsa_midi.h +++ b/drivers/alsamidi/alsa_midi.h @@ -33,13 +33,13 @@ #ifndef ALSA_MIDI_H #define ALSA_MIDI_H -#include <alsa/asoundlib.h> -#include <stdio.h> - +#include "core/os/midi_driver.h" #include "core/os/mutex.h" #include "core/os/thread.h" #include "core/vector.h" -#include "os/midi_driver.h" + +#include <alsa/asoundlib.h> +#include <stdio.h> class MIDIDriverALSAMidi : public MIDIDriver { diff --git a/drivers/convex_decomp/b2d_decompose.h b/drivers/convex_decomp/b2d_decompose.h index b21792047e..f6b08b957c 100644 --- a/drivers/convex_decomp/b2d_decompose.h +++ b/drivers/convex_decomp/b2d_decompose.h @@ -31,8 +31,9 @@ #ifndef B2D_DECOMPOSE_H #define B2D_DECOMPOSE_H -#include "vector.h" -#include "vector2.h" +#include "core/math/vector2.h" +#include "core/vector.h" + Vector<Vector<Vector2> > b2d_decompose(const Vector<Vector2> &p_polygon); #endif // B2D_DECOMPOSE_H diff --git a/drivers/coreaudio/audio_driver_coreaudio.cpp b/drivers/coreaudio/audio_driver_coreaudio.cpp index 45d62e797f..09e50e4aaa 100644 --- a/drivers/coreaudio/audio_driver_coreaudio.cpp +++ b/drivers/coreaudio/audio_driver_coreaudio.cpp @@ -31,8 +31,9 @@ #ifdef COREAUDIO_ENABLED #include "audio_driver_coreaudio.h" + +#include "core/os/os.h" #include "core/project_settings.h" -#include "os/os.h" #define kOutputBus 0 #define kInputBus 1 diff --git a/drivers/coremidi/core_midi.cpp b/drivers/coremidi/core_midi.cpp index 6d4624e05b..e8106c4543 100644 --- a/drivers/coremidi/core_midi.cpp +++ b/drivers/coremidi/core_midi.cpp @@ -31,7 +31,8 @@ #ifdef COREMIDI_ENABLED #include "core_midi.h" -#include "print_string.h" + +#include "core/print_string.h" #include <CoreAudio/HostTime.h> #include <CoreServices/CoreServices.h> diff --git a/drivers/coremidi/core_midi.h b/drivers/coremidi/core_midi.h index c6b443764f..ea6b0fcb06 100644 --- a/drivers/coremidi/core_midi.h +++ b/drivers/coremidi/core_midi.h @@ -33,12 +33,11 @@ #ifndef CORE_MIDI_H #define CORE_MIDI_H -#include <stdio.h> +#include "core/os/midi_driver.h" +#include "core/vector.h" #include <CoreMIDI/CoreMIDI.h> - -#include "core/vector.h" -#include "os/midi_driver.h" +#include <stdio.h> class MIDIDriverCoreMidi : public MIDIDriver { diff --git a/drivers/dummy/rasterizer_dummy.h b/drivers/dummy/rasterizer_dummy.h index 0381d3f0c1..bb4511ecc3 100644 --- a/drivers/dummy/rasterizer_dummy.h +++ b/drivers/dummy/rasterizer_dummy.h @@ -27,16 +27,16 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #ifndef RASTERIZER_DUMMY_H #define RASTERIZER_DUMMY_H -#include "camera_matrix.h" +#include "core/math/camera_matrix.h" +#include "core/self_list.h" #include "scene/resources/mesh.h" #include "servers/visual/rasterizer.h" #include "servers/visual_server.h" -#include "self_list.h" - class RasterizerSceneDummy : public RasterizerScene { public: /* SHADOW ATLAS API */ diff --git a/drivers/dummy/texture_loader_dummy.cpp b/drivers/dummy/texture_loader_dummy.cpp index b099019d17..8153fbd10b 100644 --- a/drivers/dummy/texture_loader_dummy.cpp +++ b/drivers/dummy/texture_loader_dummy.cpp @@ -29,8 +29,10 @@ /*************************************************************************/ #include "texture_loader_dummy.h" + #include "core/os/file_access.h" -#include "print_string.h" +#include "core/print_string.h" + #include <string.h> RES ResourceFormatDummyTexture::load(const String &p_path, const String &p_original_path, Error *r_error) { diff --git a/drivers/gl_context/context_gl.h b/drivers/gl_context/context_gl.h index 60781a3453..37f334454b 100644 --- a/drivers/gl_context/context_gl.h +++ b/drivers/gl_context/context_gl.h @@ -33,7 +33,7 @@ #if defined(OPENGL_ENABLED) || defined(GLES_ENABLED) -#include "typedefs.h" +#include "core/typedefs.h" /** @author Juan Linietsky <reduzio@gmail.com> diff --git a/drivers/gles2/rasterizer_canvas_gles2.cpp b/drivers/gles2/rasterizer_canvas_gles2.cpp index 9a9ede761a..f28fd59a0c 100644 --- a/drivers/gles2/rasterizer_canvas_gles2.cpp +++ b/drivers/gles2/rasterizer_canvas_gles2.cpp @@ -27,11 +27,14 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #include "rasterizer_canvas_gles2.h" -#include "os/os.h" -#include "project_settings.h" + +#include "core/os/os.h" +#include "core/project_settings.h" #include "rasterizer_scene_gles2.h" #include "servers/visual/visual_server_raster.h" + #ifndef GLES_OVER_GL #define glClearDepth glClearDepthf #endif diff --git a/drivers/gles2/rasterizer_gles2.cpp b/drivers/gles2/rasterizer_gles2.cpp index efeab48ea2..bd03bd71f6 100644 --- a/drivers/gles2/rasterizer_gles2.cpp +++ b/drivers/gles2/rasterizer_gles2.cpp @@ -27,12 +27,12 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #include "rasterizer_gles2.h" +#include "core/os/os.h" +#include "core/project_settings.h" #include "gl_context/context_gl.h" -#include "os/os.h" -#include "project_settings.h" -#include <string.h> #define _EXT_DEBUG_OUTPUT_SYNCHRONOUS_ARB 0x8242 #define _EXT_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_ARB 0x8243 diff --git a/drivers/gles2/rasterizer_gles2.h b/drivers/gles2/rasterizer_gles2.h index 98c73b776b..c76d5f7f20 100644 --- a/drivers/gles2/rasterizer_gles2.h +++ b/drivers/gles2/rasterizer_gles2.h @@ -27,6 +27,7 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #ifndef RASTERIZERGLES2_H #define RASTERIZERGLES2_H diff --git a/drivers/gles2/rasterizer_scene_gles2.cpp b/drivers/gles2/rasterizer_scene_gles2.cpp index e21998d55e..ca9f6dcbf8 100644 --- a/drivers/gles2/rasterizer_scene_gles2.cpp +++ b/drivers/gles2/rasterizer_scene_gles2.cpp @@ -27,16 +27,17 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #include "rasterizer_scene_gles2.h" -#include "math/transform.h" -#include "math_funcs.h" -#include "os/os.h" -#include "project_settings.h" + +#include "core/math/math_funcs.h" +#include "core/math/transform.h" +#include "core/os/os.h" +#include "core/project_settings.h" +#include "core/vmap.h" #include "rasterizer_canvas_gles2.h" #include "servers/visual/visual_server_raster.h" -#include "vmap.h" - #ifndef GLES_OVER_GL #define glClearDepth glClearDepthf #endif diff --git a/drivers/gles2/rasterizer_scene_gles2.h b/drivers/gles2/rasterizer_scene_gles2.h index 72dbe14387..c5d28e55f4 100644 --- a/drivers/gles2/rasterizer_scene_gles2.h +++ b/drivers/gles2/rasterizer_scene_gles2.h @@ -27,6 +27,7 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #ifndef RASTERIZERSCENEGLES2_H #define RASTERIZERSCENEGLES2_H diff --git a/drivers/gles2/rasterizer_storage_gles2.cpp b/drivers/gles2/rasterizer_storage_gles2.cpp index 5b5ab987d1..090882a723 100644 --- a/drivers/gles2/rasterizer_storage_gles2.cpp +++ b/drivers/gles2/rasterizer_storage_gles2.cpp @@ -27,14 +27,13 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #include "rasterizer_storage_gles2.h" -#include "project_settings.h" +#include "core/math/transform.h" +#include "core/project_settings.h" #include "rasterizer_canvas_gles2.h" #include "rasterizer_scene_gles2.h" - -#include "math/transform.h" - #include "servers/visual/shader_language.h" GLuint RasterizerStorageGLES2::system_fbo = 0; diff --git a/drivers/gles2/rasterizer_storage_gles2.h b/drivers/gles2/rasterizer_storage_gles2.h index 88783d7160..e42eb67d3d 100644 --- a/drivers/gles2/rasterizer_storage_gles2.h +++ b/drivers/gles2/rasterizer_storage_gles2.h @@ -27,11 +27,12 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #ifndef RASTERIZERSTORAGEGLES2_H #define RASTERIZERSTORAGEGLES2_H -#include "dvector.h" -#include "self_list.h" +#include "core/dvector.h" +#include "core/self_list.h" #include "servers/visual/rasterizer.h" #include "servers/visual/shader_language.h" #include "shader_compiler_gles2.h" diff --git a/drivers/gles2/shader_compiler_gles2.cpp b/drivers/gles2/shader_compiler_gles2.cpp index 1c87b3ffb5..83b61dc288 100644 --- a/drivers/gles2/shader_compiler_gles2.cpp +++ b/drivers/gles2/shader_compiler_gles2.cpp @@ -27,11 +27,12 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #include "shader_compiler_gles2.h" -#include "os/os.h" -#include "string_buffer.h" -#include "string_builder.h" +#include "core/os/os.h" +#include "core/string_buffer.h" +#include "core/string_builder.h" #define SL ShaderLanguage diff --git a/drivers/gles2/shader_compiler_gles2.h b/drivers/gles2/shader_compiler_gles2.h index 804ead2172..5e9e295204 100644 --- a/drivers/gles2/shader_compiler_gles2.h +++ b/drivers/gles2/shader_compiler_gles2.h @@ -27,16 +27,16 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #ifndef SHADERCOMPILERGLES2_H #define SHADERCOMPILERGLES2_H -#include "pair.h" +#include "core/pair.h" +#include "core/string_builder.h" #include "servers/visual/shader_language.h" #include "servers/visual/shader_types.h" #include "servers/visual_server.h" -#include "string_builder.h" - class ShaderCompilerGLES2 { public: struct IdentifierActions { diff --git a/drivers/gles2/shader_gles2.cpp b/drivers/gles2/shader_gles2.cpp index 3b2a29d3ee..5a50ce8ae5 100644 --- a/drivers/gles2/shader_gles2.cpp +++ b/drivers/gles2/shader_gles2.cpp @@ -27,12 +27,12 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ -#include "shader_gles2.h" -#include "memory.h" -#include "print_string.h" -#include "string_builder.h" +#include "shader_gles2.h" +#include "core/os/memory.h" +#include "core/print_string.h" +#include "core/string_builder.h" #include "rasterizer_gles2.h" #include "rasterizer_storage_gles2.h" diff --git a/drivers/gles2/shader_gles2.h b/drivers/gles2/shader_gles2.h index cb515c199c..8e274b4f57 100644 --- a/drivers/gles2/shader_gles2.h +++ b/drivers/gles2/shader_gles2.h @@ -27,11 +27,11 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ + #ifndef SHADER_GLES2_H #define SHADER_GLES2_H -#include <stdio.h> - +// This must come first to avoid windows.h mess #include "platform_config.h" #ifndef GLES2_INCLUDE_H #include <GLES2/gl2.h> @@ -39,14 +39,15 @@ #include GLES2_INCLUDE_H #endif -#include "camera_matrix.h" -#include "hash_map.h" -#include "map.h" -#include "variant.h" - +#include "core/hash_map.h" +#include "core/map.h" +#include "core/math/camera_matrix.h" #include "core/pair.h" +#include "core/variant.h" #include "servers/visual/shader_language.h" +#include <stdio.h> + class RasterizerStorageGLES2; class ShaderGLES2 { diff --git a/drivers/gles3/rasterizer_canvas_gles3.cpp b/drivers/gles3/rasterizer_canvas_gles3.cpp index 33e9e5f772..c9bdc6f5c3 100644 --- a/drivers/gles3/rasterizer_canvas_gles3.cpp +++ b/drivers/gles3/rasterizer_canvas_gles3.cpp @@ -29,10 +29,12 @@ /*************************************************************************/ #include "rasterizer_canvas_gles3.h" -#include "os/os.h" -#include "project_settings.h" + +#include "core/os/os.h" +#include "core/project_settings.h" #include "rasterizer_scene_gles3.h" #include "servers/visual/visual_server_raster.h" + #ifndef GLES_OVER_GL #define glClearDepth glClearDepthf #endif diff --git a/drivers/gles3/rasterizer_canvas_gles3.h b/drivers/gles3/rasterizer_canvas_gles3.h index c7f2e54efb..bc4ea80328 100644 --- a/drivers/gles3/rasterizer_canvas_gles3.h +++ b/drivers/gles3/rasterizer_canvas_gles3.h @@ -33,6 +33,7 @@ #include "rasterizer_storage_gles3.h" #include "servers/visual/rasterizer.h" + #include "shaders/canvas_shadow.glsl.gen.h" class RasterizerSceneGLES3; diff --git a/drivers/gles3/rasterizer_gles3.cpp b/drivers/gles3/rasterizer_gles3.cpp index e4824695d5..d3f6dcd497 100644 --- a/drivers/gles3/rasterizer_gles3.cpp +++ b/drivers/gles3/rasterizer_gles3.cpp @@ -30,11 +30,9 @@ #include "rasterizer_gles3.h" +#include "core/os/os.h" +#include "core/project_settings.h" #include "gl_context/context_gl.h" -#include "os/os.h" -#include "project_settings.h" - -#include <string.h> RasterizerStorage *RasterizerGLES3::get_storage() { diff --git a/drivers/gles3/rasterizer_scene_gles3.cpp b/drivers/gles3/rasterizer_scene_gles3.cpp index 88f14890ef..947729f6f6 100644 --- a/drivers/gles3/rasterizer_scene_gles3.cpp +++ b/drivers/gles3/rasterizer_scene_gles3.cpp @@ -29,9 +29,10 @@ /*************************************************************************/ #include "rasterizer_scene_gles3.h" -#include "math_funcs.h" -#include "os/os.h" -#include "project_settings.h" + +#include "core/math/math_funcs.h" +#include "core/os/os.h" +#include "core/project_settings.h" #include "rasterizer_canvas_gles3.h" #include "servers/visual/visual_server_raster.h" diff --git a/drivers/gles3/rasterizer_storage_gles3.cpp b/drivers/gles3/rasterizer_storage_gles3.cpp index 83f731f610..c05f4cfbe3 100644 --- a/drivers/gles3/rasterizer_storage_gles3.cpp +++ b/drivers/gles3/rasterizer_storage_gles3.cpp @@ -29,8 +29,9 @@ /*************************************************************************/ #include "rasterizer_storage_gles3.h" -#include "engine.h" -#include "project_settings.h" + +#include "core/engine.h" +#include "core/project_settings.h" #include "rasterizer_canvas_gles3.h" #include "rasterizer_scene_gles3.h" diff --git a/drivers/gles3/rasterizer_storage_gles3.h b/drivers/gles3/rasterizer_storage_gles3.h index b74dd77e26..33f0853d60 100644 --- a/drivers/gles3/rasterizer_storage_gles3.h +++ b/drivers/gles3/rasterizer_storage_gles3.h @@ -31,11 +31,12 @@ #ifndef RASTERIZERSTORAGEGLES3_H #define RASTERIZERSTORAGEGLES3_H -#include "self_list.h" +#include "core/self_list.h" #include "servers/visual/rasterizer.h" #include "servers/visual/shader_language.h" #include "shader_compiler_gles3.h" #include "shader_gles3.h" + #include "shaders/blend_shape.glsl.gen.h" #include "shaders/canvas.glsl.gen.h" #include "shaders/copy.glsl.gen.h" diff --git a/drivers/gles3/shader_compiler_gles3.cpp b/drivers/gles3/shader_compiler_gles3.cpp index a78a392cbd..11c84e7db8 100644 --- a/drivers/gles3/shader_compiler_gles3.cpp +++ b/drivers/gles3/shader_compiler_gles3.cpp @@ -30,7 +30,7 @@ #include "shader_compiler_gles3.h" -#include "os/os.h" +#include "core/os/os.h" #define SL ShaderLanguage diff --git a/drivers/gles3/shader_compiler_gles3.h b/drivers/gles3/shader_compiler_gles3.h index 7a32057741..1f903b8935 100644 --- a/drivers/gles3/shader_compiler_gles3.h +++ b/drivers/gles3/shader_compiler_gles3.h @@ -31,7 +31,7 @@ #ifndef SHADERCOMPILERGLES3_H #define SHADERCOMPILERGLES3_H -#include "pair.h" +#include "core/pair.h" #include "servers/visual/shader_language.h" #include "servers/visual/shader_types.h" #include "servers/visual_server.h" diff --git a/drivers/gles3/shader_gles3.cpp b/drivers/gles3/shader_gles3.cpp index 007600bb42..2a3b8a9b91 100644 --- a/drivers/gles3/shader_gles3.cpp +++ b/drivers/gles3/shader_gles3.cpp @@ -30,7 +30,7 @@ #include "shader_gles3.h" -#include "print_string.h" +#include "core/print_string.h" //#define DEBUG_OPENGL diff --git a/drivers/gles3/shader_gles3.h b/drivers/gles3/shader_gles3.h index 996655615e..ca74317218 100644 --- a/drivers/gles3/shader_gles3.h +++ b/drivers/gles3/shader_gles3.h @@ -31,7 +31,10 @@ #ifndef SHADER_GLES3_H #define SHADER_GLES3_H -#include <stdio.h> +#include "core/hash_map.h" +#include "core/map.h" +#include "core/math/camera_matrix.h" +#include "core/variant.h" #include "platform_config.h" #ifndef GLES3_INCLUDE_H @@ -40,10 +43,7 @@ #include GLES3_INCLUDE_H #endif -#include "camera_matrix.h" -#include "hash_map.h" -#include "map.h" -#include "variant.h" +#include <stdio.h> /** @author Juan Linietsky <reduzio@gmail.com> diff --git a/drivers/png/image_loader_png.cpp b/drivers/png/image_loader_png.cpp index b08688892e..04acb9387e 100644 --- a/drivers/png/image_loader_png.cpp +++ b/drivers/png/image_loader_png.cpp @@ -30,8 +30,8 @@ #include "image_loader_png.h" -#include "os/os.h" -#include "print_string.h" +#include "core/os/os.h" +#include "core/print_string.h" #include <string.h> diff --git a/drivers/png/image_loader_png.h b/drivers/png/image_loader_png.h index 48f48e6bea..5dff7e3902 100644 --- a/drivers/png/image_loader_png.h +++ b/drivers/png/image_loader_png.h @@ -31,7 +31,7 @@ #ifndef IMAGE_LOADER_PNG_H #define IMAGE_LOADER_PNG_H -#include "io/image_loader.h" +#include "core/io/image_loader.h" #include <png.h> diff --git a/drivers/png/resource_saver_png.cpp b/drivers/png/resource_saver_png.cpp index 270ae36e1e..c5729f70b2 100644 --- a/drivers/png/resource_saver_png.cpp +++ b/drivers/png/resource_saver_png.cpp @@ -31,8 +31,8 @@ #include "resource_saver_png.h" #include "core/image.h" -#include "os/file_access.h" -#include "project_settings.h" +#include "core/os/file_access.h" +#include "core/project_settings.h" #include "scene/resources/texture.h" #include <png.h> diff --git a/drivers/png/resource_saver_png.h b/drivers/png/resource_saver_png.h index 109b4801da..34950f6723 100644 --- a/drivers/png/resource_saver_png.h +++ b/drivers/png/resource_saver_png.h @@ -31,8 +31,8 @@ #ifndef RESOURCE_SAVER_PNG_H #define RESOURCE_SAVER_PNG_H -#include "image.h" -#include "io/resource_saver.h" +#include "core/image.h" +#include "core/io/resource_saver.h" class ResourceSaverPNG : public ResourceFormatSaver { public: diff --git a/drivers/pulseaudio/audio_driver_pulseaudio.cpp b/drivers/pulseaudio/audio_driver_pulseaudio.cpp index 744b3a35e6..7578fbc0a0 100644 --- a/drivers/pulseaudio/audio_driver_pulseaudio.cpp +++ b/drivers/pulseaudio/audio_driver_pulseaudio.cpp @@ -32,10 +32,8 @@ #ifdef PULSEAUDIO_ENABLED -#include <pulse/pulseaudio.h> - -#include "os/os.h" -#include "project_settings.h" +#include "core/os/os.h" +#include "core/project_settings.h" void AudioDriverPulseAudio::pa_state_cb(pa_context *c, void *userdata) { AudioDriverPulseAudio *ad = (AudioDriverPulseAudio *)userdata; diff --git a/drivers/rtaudio/audio_driver_rtaudio.cpp b/drivers/rtaudio/audio_driver_rtaudio.cpp index 69830b542b..10ba0663f2 100644 --- a/drivers/rtaudio/audio_driver_rtaudio.cpp +++ b/drivers/rtaudio/audio_driver_rtaudio.cpp @@ -30,8 +30,8 @@ #include "audio_driver_rtaudio.h" -#include "os/os.h" -#include "project_settings.h" +#include "core/os/os.h" +#include "core/project_settings.h" #ifdef RTAUDIO_ENABLED diff --git a/drivers/unix/dir_access_unix.cpp b/drivers/unix/dir_access_unix.cpp index 5a4be6df4f..81861f8c7b 100644 --- a/drivers/unix/dir_access_unix.cpp +++ b/drivers/unix/dir_access_unix.cpp @@ -32,18 +32,19 @@ #if defined(UNIX_ENABLED) || defined(LIBC_FILEIO_ENABLED) -#ifndef ANDROID_ENABLED -#include <sys/statvfs.h> -#endif - #include "core/list.h" -#include "os/memory.h" -#include "print_string.h" +#include "core/os/memory.h" +#include "core/print_string.h" + #include <errno.h> #include <stdio.h> #include <stdlib.h> #include <string.h> +#ifndef ANDROID_ENABLED +#include <sys/statvfs.h> +#endif + #ifdef HAVE_MNTENT #include <mntent.h> #endif diff --git a/drivers/unix/dir_access_unix.h b/drivers/unix/dir_access_unix.h index a55acdbd34..26978930bd 100644 --- a/drivers/unix/dir_access_unix.h +++ b/drivers/unix/dir_access_unix.h @@ -33,16 +33,17 @@ #if defined(UNIX_ENABLED) || defined(LIBC_FILEIO_ENABLED) +#include "core/os/dir_access.h" + #include <dirent.h> #include <sys/stat.h> #include <sys/types.h> #include <unistd.h> -#include "os/dir_access.h" - /** @author Juan Linietsky <reduzio@gmail.com> */ + class DirAccessUnix : public DirAccess { DIR *dir_stream; diff --git a/drivers/unix/file_access_unix.cpp b/drivers/unix/file_access_unix.cpp index ca16c6fcae..3b97b95f7c 100644 --- a/drivers/unix/file_access_unix.cpp +++ b/drivers/unix/file_access_unix.cpp @@ -33,7 +33,8 @@ #if defined(UNIX_ENABLED) || defined(LIBC_FILEIO_ENABLED) #include "core/os/os.h" -#include "print_string.h" +#include "core/print_string.h" + #include <sys/stat.h> #include <sys/types.h> diff --git a/drivers/unix/file_access_unix.h b/drivers/unix/file_access_unix.h index 88bb39fbd1..d4a4f8230c 100644 --- a/drivers/unix/file_access_unix.h +++ b/drivers/unix/file_access_unix.h @@ -31,8 +31,9 @@ #ifndef FILE_ACCESS_UNIX_H #define FILE_ACCESS_UNIX_H -#include "os/file_access.h" -#include "os/memory.h" +#include "core/os/file_access.h" +#include "core/os/memory.h" + #include <stdio.h> #if defined(UNIX_ENABLED) || defined(LIBC_FILEIO_ENABLED) diff --git a/drivers/unix/ip_unix.h b/drivers/unix/ip_unix.h index d3d1ccfa85..83535045b1 100644 --- a/drivers/unix/ip_unix.h +++ b/drivers/unix/ip_unix.h @@ -31,7 +31,7 @@ #ifndef IP_UNIX_H #define IP_UNIX_H -#include "io/ip.h" +#include "core/io/ip.h" #if defined(UNIX_ENABLED) || defined(WINDOWS_ENABLED) diff --git a/drivers/unix/mutex_posix.cpp b/drivers/unix/mutex_posix.cpp index 1f13720f1e..e0004c5730 100644 --- a/drivers/unix/mutex_posix.cpp +++ b/drivers/unix/mutex_posix.cpp @@ -29,7 +29,8 @@ /*************************************************************************/ #include "mutex_posix.h" -#include "os/memory.h" + +#include "core/os/memory.h" #if defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED) diff --git a/drivers/unix/mutex_posix.h b/drivers/unix/mutex_posix.h index a4de1603f3..80d85eee61 100644 --- a/drivers/unix/mutex_posix.h +++ b/drivers/unix/mutex_posix.h @@ -33,7 +33,8 @@ #if defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED) -#include "os/mutex.h" +#include "core/os/mutex.h" + #include <pthread.h> class MutexPosix : public Mutex { diff --git a/drivers/unix/os_unix.cpp b/drivers/unix/os_unix.cpp index 05dfd69f58..6dba6923c3 100644 --- a/drivers/unix/os_unix.cpp +++ b/drivers/unix/os_unix.cpp @@ -32,20 +32,18 @@ #ifdef UNIX_ENABLED -#include "servers/visual_server.h" - #include "core/os/thread_dummy.h" -#include "mutex_posix.h" -#include "rw_lock_posix.h" -#include "semaphore_posix.h" -#include "thread_posix.h" - -//#include "core/io/file_access_buffered_fa.h" -#include "dir_access_unix.h" -#include "file_access_unix.h" -#include "packet_peer_udp_posix.h" -#include "stream_peer_tcp_posix.h" -#include "tcp_server_posix.h" +#include "core/project_settings.h" +#include "drivers/unix/dir_access_unix.h" +#include "drivers/unix/file_access_unix.h" +#include "drivers/unix/mutex_posix.h" +#include "drivers/unix/packet_peer_udp_posix.h" +#include "drivers/unix/rw_lock_posix.h" +#include "drivers/unix/semaphore_posix.h" +#include "drivers/unix/stream_peer_tcp_posix.h" +#include "drivers/unix/tcp_server_posix.h" +#include "drivers/unix/thread_posix.h" +#include "servers/visual_server.h" #ifdef __APPLE__ #include <mach-o/dyld.h> @@ -55,7 +53,7 @@ #include <sys/param.h> #include <sys/sysctl.h> #endif -#include "project_settings.h" + #include <assert.h> #include <dlfcn.h> #include <errno.h> diff --git a/drivers/unix/os_unix.h b/drivers/unix/os_unix.h index 95b74d23ff..f4abfa2dd4 100644 --- a/drivers/unix/os_unix.h +++ b/drivers/unix/os_unix.h @@ -37,8 +37,8 @@ #ifdef UNIX_ENABLED +#include "core/os/os.h" #include "drivers/unix/ip_unix.h" -#include "os/os.h" class OS_Unix : public OS { diff --git a/drivers/unix/packet_peer_udp_posix.h b/drivers/unix/packet_peer_udp_posix.h index 7f72a9bfc9..d366d88b77 100644 --- a/drivers/unix/packet_peer_udp_posix.h +++ b/drivers/unix/packet_peer_udp_posix.h @@ -33,8 +33,8 @@ #ifdef UNIX_ENABLED -#include "io/packet_peer_udp.h" -#include "ring_buffer.h" +#include "core/io/packet_peer_udp.h" +#include "core/ring_buffer.h" class PacketPeerUDPPosix : public PacketPeerUDP { diff --git a/drivers/unix/rw_lock_posix.cpp b/drivers/unix/rw_lock_posix.cpp index 4df965cabb..27b19c30d5 100644 --- a/drivers/unix/rw_lock_posix.cpp +++ b/drivers/unix/rw_lock_posix.cpp @@ -32,8 +32,8 @@ #include "rw_lock_posix.h" -#include "error_macros.h" -#include "os/memory.h" +#include "core/error_macros.h" +#include "core/os/memory.h" #include <stdio.h> void RWLockPosix::read_lock() { diff --git a/drivers/unix/rw_lock_posix.h b/drivers/unix/rw_lock_posix.h index 617b9705da..897b617f98 100644 --- a/drivers/unix/rw_lock_posix.h +++ b/drivers/unix/rw_lock_posix.h @@ -33,7 +33,7 @@ #if defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED) -#include "os/rw_lock.h" +#include "core/os/rw_lock.h" #include <pthread.h> class RWLockPosix : public RWLock { diff --git a/drivers/unix/semaphore_posix.cpp b/drivers/unix/semaphore_posix.cpp index 5cabfe4937..26c2aeab28 100644 --- a/drivers/unix/semaphore_posix.cpp +++ b/drivers/unix/semaphore_posix.cpp @@ -32,7 +32,7 @@ #if defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED) -#include "os/memory.h" +#include "core/os/memory.h" #include <errno.h> #include <stdio.h> diff --git a/drivers/unix/semaphore_posix.h b/drivers/unix/semaphore_posix.h index 283174bb2e..025b87c0d7 100644 --- a/drivers/unix/semaphore_posix.h +++ b/drivers/unix/semaphore_posix.h @@ -31,7 +31,7 @@ #ifndef SEMAPHORE_POSIX_H #define SEMAPHORE_POSIX_H -#include "os/semaphore.h" +#include "core/os/semaphore.h" #if defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED) diff --git a/drivers/unix/stream_peer_tcp_posix.h b/drivers/unix/stream_peer_tcp_posix.h index bcebe57771..05c48432db 100644 --- a/drivers/unix/stream_peer_tcp_posix.h +++ b/drivers/unix/stream_peer_tcp_posix.h @@ -33,9 +33,9 @@ #ifndef STREAM_PEER_TCP_POSIX_H #define STREAM_PEER_TCP_POSIX_H +#include "core/error_list.h" #include "core/io/ip_address.h" #include "core/io/stream_peer_tcp.h" -#include "error_list.h" class StreamPeerTCPPosix : public StreamPeerTCP { diff --git a/drivers/unix/syslog_logger.cpp b/drivers/unix/syslog_logger.cpp index 727672458c..c7b4daf4ad 100644 --- a/drivers/unix/syslog_logger.cpp +++ b/drivers/unix/syslog_logger.cpp @@ -31,7 +31,7 @@ #ifdef UNIX_ENABLED #include "syslog_logger.h" -#include "print_string.h" +#include "core/print_string.h" #include <syslog.h> void SyslogLogger::logv(const char *p_format, va_list p_list, bool p_err) { diff --git a/drivers/unix/syslog_logger.h b/drivers/unix/syslog_logger.h index 40bf26cee1..745264ab6f 100644 --- a/drivers/unix/syslog_logger.h +++ b/drivers/unix/syslog_logger.h @@ -33,7 +33,7 @@ #ifdef UNIX_ENABLED -#include "io/logger.h" +#include "core/io/logger.h" class SyslogLogger : public Logger { public: @@ -45,4 +45,4 @@ public: #endif -#endif
\ No newline at end of file +#endif diff --git a/drivers/unix/thread_posix.cpp b/drivers/unix/thread_posix.cpp index a73b40a6f2..fcefe0a3b3 100644 --- a/drivers/unix/thread_posix.cpp +++ b/drivers/unix/thread_posix.cpp @@ -29,7 +29,7 @@ /*************************************************************************/ #include "thread_posix.h" -#include "script_language.h" +#include "core/script_language.h" #if (defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED)) && !defined(NO_THREADS) @@ -37,8 +37,8 @@ #include <pthread_np.h> #endif +#include "core/os/memory.h" #include "core/safe_refcount.h" -#include "os/memory.h" static pthread_key_t _create_thread_id_key() { pthread_key_t key; diff --git a/drivers/unix/thread_posix.h b/drivers/unix/thread_posix.h index ea2de61bd5..20d103232e 100644 --- a/drivers/unix/thread_posix.h +++ b/drivers/unix/thread_posix.h @@ -37,7 +37,7 @@ #if (defined(UNIX_ENABLED) || defined(PTHREAD_ENABLED)) && !defined(NO_THREADS) -#include "os/thread.h" +#include "core/os/thread.h" #include <pthread.h> #include <sys/types.h> diff --git a/drivers/wasapi/audio_driver_wasapi.cpp b/drivers/wasapi/audio_driver_wasapi.cpp index 43577a090f..3d4979175b 100644 --- a/drivers/wasapi/audio_driver_wasapi.cpp +++ b/drivers/wasapi/audio_driver_wasapi.cpp @@ -32,8 +32,8 @@ #include "audio_driver_wasapi.h" -#include "os/os.h" -#include "project_settings.h" +#include "core/os/os.h" +#include "core/project_settings.h" #include <functiondiscoverykeys.h> diff --git a/drivers/windows/dir_access_windows.cpp b/drivers/windows/dir_access_windows.cpp index cf4d82fb07..589e9e0870 100644 --- a/drivers/windows/dir_access_windows.cpp +++ b/drivers/windows/dir_access_windows.cpp @@ -32,9 +32,9 @@ #include "dir_access_windows.h" -#include "os/memory.h" +#include "core/os/memory.h" +#include "core/print_string.h" -#include "print_string.h" #include <stdio.h> #include <wchar.h> #include <windows.h> diff --git a/drivers/windows/dir_access_windows.h b/drivers/windows/dir_access_windows.h index b18c8f5b5d..9f5d0b6d93 100644 --- a/drivers/windows/dir_access_windows.h +++ b/drivers/windows/dir_access_windows.h @@ -33,7 +33,7 @@ #ifdef WINDOWS_ENABLED -#include "os/dir_access.h" +#include "core/os/dir_access.h" /** @author Juan Linietsky <reduz@gmail.com> diff --git a/drivers/windows/file_access_windows.h b/drivers/windows/file_access_windows.h index 0462c1e942..6f985e68b4 100644 --- a/drivers/windows/file_access_windows.h +++ b/drivers/windows/file_access_windows.h @@ -33,13 +33,15 @@ #ifdef WINDOWS_ENABLED -#include "os/file_access.h" -#include "os/memory.h" +#include "core/os/file_access.h" +#include "core/os/memory.h" + #include <stdio.h> /** @author Juan Linietsky <reduzio@gmail.com> */ + class FileAccessWindows : public FileAccess { FILE *f; diff --git a/drivers/windows/mutex_windows.cpp b/drivers/windows/mutex_windows.cpp index 359a79209c..9fc6485be3 100644 --- a/drivers/windows/mutex_windows.cpp +++ b/drivers/windows/mutex_windows.cpp @@ -29,7 +29,8 @@ /*************************************************************************/ #include "mutex_windows.h" -#include "os/memory.h" + +#include "core/os/memory.h" #ifdef WINDOWS_ENABLED diff --git a/drivers/windows/mutex_windows.h b/drivers/windows/mutex_windows.h index 4dff2c2456..5c3a8eb331 100644 --- a/drivers/windows/mutex_windows.h +++ b/drivers/windows/mutex_windows.h @@ -33,11 +33,14 @@ #ifdef WINDOWS_ENABLED -#include "os/mutex.h" +#include "core/os/mutex.h" + #include <windows.h> + /** @author Juan Linietsky <reduzio@gmail.com> */ + class MutexWindows : public Mutex { #ifdef WINDOWS_USE_MUTEX diff --git a/drivers/windows/packet_peer_udp_winsock.cpp b/drivers/windows/packet_peer_udp_winsock.cpp index 609096d02e..66221774b2 100644 --- a/drivers/windows/packet_peer_udp_winsock.cpp +++ b/drivers/windows/packet_peer_udp_winsock.cpp @@ -35,6 +35,7 @@ #include <winsock2.h> #include <ws2tcpip.h> +// Must be included after Windows headers or hell breaks loose #include "drivers/unix/socket_helpers.h" int PacketPeerUDPWinsock::get_available_packet_count() const { diff --git a/drivers/windows/packet_peer_udp_winsock.h b/drivers/windows/packet_peer_udp_winsock.h index 8d575c2033..91087af7cb 100644 --- a/drivers/windows/packet_peer_udp_winsock.h +++ b/drivers/windows/packet_peer_udp_winsock.h @@ -33,8 +33,8 @@ #ifndef PACKET_PEER_UDP_WINSOCK_H #define PACKET_PEER_UDP_WINSOCK_H -#include "io/packet_peer_udp.h" -#include "ring_buffer.h" +#include "core/io/packet_peer_udp.h" +#include "core/ring_buffer.h" class PacketPeerUDPWinsock : public PacketPeerUDP { diff --git a/drivers/windows/rw_lock_windows.cpp b/drivers/windows/rw_lock_windows.cpp index 29c24d3d02..ef00141928 100644 --- a/drivers/windows/rw_lock_windows.cpp +++ b/drivers/windows/rw_lock_windows.cpp @@ -32,8 +32,9 @@ #include "rw_lock_windows.h" -#include "error_macros.h" -#include "os/memory.h" +#include "core/error_macros.h" +#include "core/os/memory.h" + #include <stdio.h> void RWLockWindows::read_lock() { diff --git a/drivers/windows/rw_lock_windows.h b/drivers/windows/rw_lock_windows.h index fdce28574a..742a0930d4 100644 --- a/drivers/windows/rw_lock_windows.h +++ b/drivers/windows/rw_lock_windows.h @@ -33,7 +33,8 @@ #if defined(WINDOWS_ENABLED) -#include "os/rw_lock.h" +#include "core/os/rw_lock.h" + #include <windows.h> class RWLockWindows : public RWLock { diff --git a/drivers/windows/semaphore_windows.cpp b/drivers/windows/semaphore_windows.cpp index 25fced93ce..34dd387705 100644 --- a/drivers/windows/semaphore_windows.cpp +++ b/drivers/windows/semaphore_windows.cpp @@ -32,7 +32,7 @@ #if defined(WINDOWS_ENABLED) -#include "os/memory.h" +#include "core/os/memory.h" Error SemaphoreWindows::wait() { diff --git a/drivers/windows/semaphore_windows.h b/drivers/windows/semaphore_windows.h index e099ee437a..1e2f9c152e 100644 --- a/drivers/windows/semaphore_windows.h +++ b/drivers/windows/semaphore_windows.h @@ -31,14 +31,16 @@ #ifndef SEMAPHORE_WINDOWS_H #define SEMAPHORE_WINDOWS_H -#include "os/semaphore.h" +#include "core/os/semaphore.h" #ifdef WINDOWS_ENABLED #include <windows.h> + /** @author Juan Linietsky <reduzio@gmail.com> */ + class SemaphoreWindows : public Semaphore { mutable HANDLE semaphore; diff --git a/drivers/windows/shell_windows.h b/drivers/windows/shell_windows.h index 41cc6b72a2..98972a9bb1 100644 --- a/drivers/windows/shell_windows.h +++ b/drivers/windows/shell_windows.h @@ -31,12 +31,14 @@ #ifndef SHELL_WINDOWS_H #define SHELL_WINDOWS_H -#include "os/shell.h" +#include "core/os/shell.h" #ifdef WINDOWS_ENABLED + /** @author Juan Linietsky <reduzio@gmail.com> */ + class ShellWindows : public Shell { public: virtual void execute(String p_path); diff --git a/drivers/windows/stream_peer_tcp_winsock.h b/drivers/windows/stream_peer_tcp_winsock.h index a0177d374e..4a50e2f678 100644 --- a/drivers/windows/stream_peer_tcp_winsock.h +++ b/drivers/windows/stream_peer_tcp_winsock.h @@ -33,7 +33,7 @@ #ifndef STREAM_PEER_TCP_WINSOCK_H #define STREAM_PEER_TCP_WINSOCK_H -#include "error_list.h" +#include "core/error_list.h" #include "core/io/ip_address.h" #include "core/io/stream_peer_tcp.h" diff --git a/drivers/windows/thread_windows.cpp b/drivers/windows/thread_windows.cpp index 5e0b017a5c..52dcfacdf8 100644 --- a/drivers/windows/thread_windows.cpp +++ b/drivers/windows/thread_windows.cpp @@ -32,7 +32,7 @@ #if defined(WINDOWS_ENABLED) && !defined(UWP_ENABLED) -#include "os/memory.h" +#include "core/os/memory.h" Thread::ID ThreadWindows::get_id() const { diff --git a/drivers/windows/thread_windows.h b/drivers/windows/thread_windows.h index d7a8389d9e..5d2838e54f 100644 --- a/drivers/windows/thread_windows.h +++ b/drivers/windows/thread_windows.h @@ -31,16 +31,17 @@ #ifndef THREAD_WINDOWS_H #define THREAD_WINDOWS_H -/** - @author Juan Linietsky <reduzio@gmail.com> -*/ - #ifdef WINDOWS_ENABLED -#include "os/thread.h" -#include "script_language.h" +#include "core/os/thread.h" +#include "core/script_language.h" + #include <windows.h> +/** + @author Juan Linietsky <reduzio@gmail.com> +*/ + class ThreadWindows : public Thread { ThreadCreateCallback callback; diff --git a/drivers/winmidi/win_midi.cpp b/drivers/winmidi/win_midi.cpp index 63f7f13685..1d4bf1a1e2 100644 --- a/drivers/winmidi/win_midi.cpp +++ b/drivers/winmidi/win_midi.cpp @@ -31,7 +31,8 @@ #ifdef WINMIDI_ENABLED #include "win_midi.h" -#include "print_string.h" + +#include "core/print_string.h" void MIDIDriverWinMidi::read(HMIDIIN hMidiIn, UINT wMsg, DWORD_PTR dwInstance, DWORD_PTR dwParam1, DWORD_PTR dwParam2) { diff --git a/drivers/winmidi/win_midi.h b/drivers/winmidi/win_midi.h index 1cf9b19b5d..87a349d5d1 100644 --- a/drivers/winmidi/win_midi.h +++ b/drivers/winmidi/win_midi.h @@ -33,14 +33,14 @@ #ifndef WIN_MIDI_H #define WIN_MIDI_H +#include "core/os/midi_driver.h" +#include "core/vector.h" + #include <stdio.h> #include <windows.h> #include <mmsystem.h> -#include "core/vector.h" -#include "os/midi_driver.h" - class MIDIDriverWinMidi : public MIDIDriver { Vector<HMIDIIN> connected_sources; diff --git a/drivers/xaudio2/audio_driver_xaudio2.cpp b/drivers/xaudio2/audio_driver_xaudio2.cpp index a1002ef4f9..452a1105ca 100644 --- a/drivers/xaudio2/audio_driver_xaudio2.cpp +++ b/drivers/xaudio2/audio_driver_xaudio2.cpp @@ -30,8 +30,8 @@ #include "audio_driver_xaudio2.h" -#include "os/os.h" -#include "project_settings.h" +#include "core/os/os.h" +#include "core/project_settings.h" const char *AudioDriverXAudio2::get_name() const { return "XAudio2"; |