Browse Source

Enable high DPI on Apple retina display device by default.
High DPI mode can still be programmatically disabled via Engine parameter only.

Yao Wei Tjong 姚伟忠 9 years ago
parent
commit
d42723a45e

+ 0 - 1
Docs/GettingStarted.dox

@@ -405,7 +405,6 @@ The engine can be configured using the following command line options.
 -t           Enable triple buffering
 -w           Start in windowed mode
 -s           Enable resizing when in windowed mode
--hd          Enable high DPI, only supported by Apple platforms (OSX, iOS, and tvOS)
 -q           Enable quiet mode which does not log to standard output stream
 -b <length>  Sound buffer length in milliseconds
 -r <freq>    Sound mixing frequency in Hz

+ 1 - 1
Docs/Reference.dox

@@ -201,7 +201,7 @@ The full list of supported parameters, their datatypes and default values: (also
 - FullScreen (bool) Whether to create a full-screen window. Default true.
 - Borderless (bool) Whether to create the window as borderless. Default false.
 - WindowResizable (bool) Whether window is resizable. Default false.
-- HighDPI (bool) Whether window is high DPI. Default false. Currently only supported by Apple platforms (OSX, iOS, and tvOS).
+- HighDPI (bool) Whether window is high DPI. Default true. Currently only supported by Apple platforms (OSX, iOS, and tvOS).
 - TripleBuffer (bool) Whether to use triple-buffering. Default false.
 - VSync (bool) Whether to wait for vertical sync when presenting rendering window contents. Default false.
 - FlushGPU (bool) Whether to flush GPU command buffer each frame (Direct3D9) or limit the amount of buffered frames (Direct3D11) for less input latency. Ineffective on OpenGL. Default false.

+ 0 - 1
Source/Tools/Urho3DPlayer/Urho3DPlayer.cpp

@@ -84,7 +84,6 @@ void Urho3DPlayer::Setup()
             "-t           Enable triple buffering\n"
             "-w           Start in windowed mode\n"
             "-s           Enable resizing when in windowed mode\n"
-            "-hd          Enable high DPI, only supported by Apple platforms (OSX, iOS, and tvOS)\n"
             "-q           Enable quiet mode which does not log to standard output stream\n"
             "-b <length>  Sound buffer length in milliseconds\n"
             "-r <freq>    Sound mixing frequency in Hz\n"

+ 1 - 3
Source/Urho3D/Engine/Engine.cpp

@@ -372,7 +372,7 @@ bool Engine::Initialize(const VariantMap& parameters)
             GetParameter(parameters, EP_FULL_SCREEN, true).GetBool(),
             GetParameter(parameters, EP_BORDERLESS, false).GetBool(),
             GetParameter(parameters, EP_WINDOW_RESIZABLE, false).GetBool(),
-            GetParameter(parameters, EP_HIGH_DPI, false).GetBool(),
+            GetParameter(parameters, EP_HIGH_DPI, true).GetBool(),
             GetParameter(parameters, EP_VSYNC, false).GetBool(),
             GetParameter(parameters, EP_TRIPLE_BUFFER, false).GetBool(),
             GetParameter(parameters, EP_MULTI_SAMPLE, 1).GetInt()
@@ -821,8 +821,6 @@ VariantMap Engine::ParseParameters(const Vector<String>& arguments)
                 ret[EP_BORDERLESS] = true;
             else if (argument == "s")
                 ret[EP_WINDOW_RESIZABLE] = true;
-            else if (argument == "hd")
-                ret[EP_HIGH_DPI] = true;
             else if (argument == "q")
                 ret[EP_LOG_QUIET] = true;
             else if (argument == "log" && !value.Empty())