diff options
Diffstat (limited to 'platform/server/os_server.cpp')
-rw-r--r-- | platform/server/os_server.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/platform/server/os_server.cpp b/platform/server/os_server.cpp index 3b1be780d4..1c17780ad7 100644 --- a/platform/server/os_server.cpp +++ b/platform/server/os_server.cpp @@ -28,16 +28,17 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ #include "os_server.h" + #include "drivers/dummy/audio_driver_dummy.h" #include "drivers/dummy/rasterizer_dummy.h" #include "drivers/dummy/texture_loader_dummy.h" #include "print_string.h" #include "servers/visual/visual_server_raster.h" -#include <stdio.h> -#include <stdlib.h> #include "main/main.h" +#include <stdio.h> +#include <stdlib.h> #include <unistd.h> int OS_Server::get_video_driver_count() const { @@ -58,6 +59,10 @@ const char *OS_Server::get_audio_driver_name(int p_driver) const { return "Dummy"; } +int OS_Server::get_current_video_driver() const { + return video_driver_index; +} + void OS_Server::initialize_core() { crash_handler.initialize(); @@ -73,6 +78,8 @@ Error OS_Server::initialize(const VideoMode &p_desired, int p_video_driver, int RasterizerDummy::make_current(); + video_driver_index = p_video_driver; // unused in server platform, but should still be initialized + visual_server = memnew(VisualServerRaster); visual_server->init(); |