The Mixed Reality Forums here are no longer being used or maintained.
There are a few other places we would like to direct you to for support, both from Microsoft and from the community.
The first way we want to connect with you is our mixed reality developer program, which you can sign up for at https://aka.ms/IWantMR.
For technical questions, please use Stack Overflow, and tag your questions using either hololens or windows-mixed-reality.
If you want to join in discussions, please do so in the HoloDevelopers Slack, which you can join by going to https://aka.ms/holodevelopers, or in our Microsoft Tech Communities forums at https://techcommunity.microsoft.com/t5/mixed-reality/ct-p/MicrosoftMixedReality.
And always feel free to hit us up on Twitter @MxdRealityDev.
Ignore Scaling UWP App In Hololens.
Windows 10 automatically applies a scale factor to UWP apps, to give a similar effective pixel size across multiple devices (https://blogs.technet.microsoft.com/supportingwindows/2015/12/08/display-scaling-in-windows-10/).
When running my UWP app on the Hololens it applies a 150% scale factor.
I want to ignore this, as I want my UI to look the same across any screen of the same resolution (1280x720). Is this possible?
Some people suggest using TrySetDisableLayoutScaling (https://docs.microsoft.com/en-us/uwp/api/windows.ui.viewmanagement.applicationviewscaling) but this only seems to work for Xbox.
I could make different UIs for per device family, that take into account the different scale factors, but that is not ideal.
I posted it here, rather than stackoverflow, as I would expect this is an issue people have encountered before? Any help would be greatly appreciated!
Best Answer
-
Optionsjames_ashley ✭✭✭✭
Hi @Mag,
I'm sure you've read through this, but MS uses "effective pixels" on purpose because it provides the best reading experience. They're basically making the call for you, so that reading text on a 2D window inside HoloLens about 6 ft away is similar to reading a monitor about a foot and a half away from your face or reading from your TV on an XBox app across the room. If you really need it, creating a special View just for HoloLens would be the only way to achieve your goal. Sorry. https://developer.microsoft.com/en-us/windows/mixed-reality/updating_your_existing_universal_app_for_hololens
James Ashley
VS 2017 v5.3.3, Unity 2017.3.0f3, MRTK 2017.1.2, W10 17063
Microsoft MVP, Freelance HoloLens/MR Developer
www.imaginativeuniversal.com5
Answers
Hi @Mag,
I'm sure you've read through this, but MS uses "effective pixels" on purpose because it provides the best reading experience. They're basically making the call for you, so that reading text on a 2D window inside HoloLens about 6 ft away is similar to reading a monitor about a foot and a half away from your face or reading from your TV on an XBox app across the room. If you really need it, creating a special View just for HoloLens would be the only way to achieve your goal. Sorry. https://developer.microsoft.com/en-us/windows/mixed-reality/updating_your_existing_universal_app_for_hololens
James Ashley
VS 2017 v5.3.3, Unity 2017.3.0f3, MRTK 2017.1.2, W10 17063
Microsoft MVP, Freelance HoloLens/MR Developer
www.imaginativeuniversal.com
Yeah this is what I expected, I posted a similar question to StackOverflow: https://stackoverflow.com/q/47452892/3209889
I have also raised an issue with Microsoft to support disabling Layout Scaling on Hololens: https://wpdev.uservoice.com/forums/110705-universal-windows-platform/suggestions/32441581-disable-layout-scaling-for-hololens-trysetdisabl