Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Unity Bugs

Discussion in 'Windows' started by Nihil688, Jan 21, 2016.

  1. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Hello,

    We've been hitting bumps with windows universal builds recently.

    To test we updated our phone Lumia 920 to Windows 10 which is available to developers in order to
    test the Universal build and our builds has been laggy even on empty scenes.

    We're making sure we're building with the Master setting on and still we've been getting very low framerate.
    Tested with 5.3.1f1 p1,p2 and p3.

    Recently we've been getting the following error and can't build at all:

    Severity Code Description Project File Line Suppression State
    Error Error : DEP0001 : Unexpected Error: Install failed. Please contact your software vendor. (Exception from HRESULT: 0x80073CF9) Name of the game
     
  2. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    To Anyone having the following error:

    Error Error : DEP0001 : Unexpected Error: Install failed. Please contact your software vendor. (Exception from HRESULT: 0x80073CF9) Name of the game


    Don't add spaces in the product name

    As for the slowness in 5.3 not sure yet, any help would be appreciated as In-app was introduced in 5.3
     
  3. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Hey, did you try using a profiler to identify what's slow?
     
  4. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    The profiler doesn't work on Windows 10 yet as far as I can see, since the device choice is greyed out
     
  5. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    There is a restriction on games running on Windows Store that you cannot profile the game that's running on Local machine due to the fact that it's running in a Sandbox. You should be able to attach the profiler from the editor that's running on another machine, though.

    Check this out:

    http://docs.unity3d.com/Manual/windowsstore-profiler.html
     
  6. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    This doesn't work as I'm getting the following error

    Code (CSharp):
    1. Exception: Failed to build Visual Studio project using arguments 'C:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe "C:\xxx.sln" /nologo /maxcpucount /p:Configuration=Release /p:Platform=x86 /p:SolutionDir="C:\\Unity Projects\\xxx\\Build\\Windows 10\\" /t:Build /clp:Verbosity=minimal'.
    2. Output:  UnityInstallationDir "C:\Program Files\Unity\Editor".
    3.   UnityWSAPlayerDir "C:\Program Files\Unity\Editor\Data\PlaybackEngines\MetroSupport".
    4.   UnityProjectDir "C:\xxx".
    5.   Copying unprocessed assemblies...
    6.   Running AssemblyConverter...
    7.   AssemblyConverter done.
    8.   xxx-> C:\xxx.exe
    9. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(1854,5): warning APPX0105: Cannot import the key file 'WSATestCertificate.pfx'. The key file may be password protected. To correct this, try to import the certificate manually into the current user's personal certificate store. [C:\xxx.csproj]
    10. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(1854,5): warning APPX0107: The certificate specified is not valid for signing. For more information about valid certificates, see http://go.microsoft.com/fwlink/?LinkID=241478. [C:\xxx.csproj]
    11.  xxx-> C:\xxx.appx
    12. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(2465,5): error APPX0105: Cannot import the key file 'WSATestCertificate.pfx'. The key file may be password protected. To correct this, try to import the certificate manually into the current user's personal certificate store. [C:\xxx.csproj]
    13. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\AppxPackage\Microsoft.AppXPackage.Targets(2465,5): error APPX0107: The certificate specified is not valid for signing. For more information about valid certificates, see http://go.microsoft.com/fwlink/?LinkID=241478. [C:\\xxx\xxx.csproj]
    14.  
    15.  
    16. ApplicationLauncherImpl.RunMSBuild (System.String args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ApplicationLauncher.cs:294)
    17. ApplicationLauncherImpl.Build () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ApplicationLauncher.cs:179)
    18. ApplicationLauncher.BuildAndRun (BuildLaunchPlayerArgs args, WSASDK wsaSDK) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ApplicationLauncher.cs:56)
    19. ApplicationLauncher.BuildAndRun (BuildLaunchPlayerArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ApplicationLauncher.cs:46)
    20. UnityEditor.Metro.BuildPostprocessor.LaunchPlayer (BuildLaunchPlayerArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:95)
    21. UnityEditor.PostprocessBuildPlayer.Launch (BuildTarget target, System.String path, System.String productName, BuildOptions options) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/PostprocessBuildPlayer.cs:282)
    22. UnityEditor.HostView:OnGUI()
    23.  
    https://www.dropbox.com/s/azwv6amfelb3gwp/Screenshot 2016-01-21 17.18.41.png?dl=0

    PS: Nor does connecting with IP ( says it can't connect )
     
    Last edited: Jan 21, 2016
  7. Tomas1856

    Tomas1856

    Unity Technologies

    Joined:
    Sep 21, 2012
    Posts:
    3,647
    Recreate the certificate via PlayerSettings (Windows Store Apps) and try again, the current certificate you have is invalid.
     
  8. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    I had done that, I tried again and same error
     
  9. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    I found at times that the firewall sometimes blocks the profiler connection. Could you try disabling it on the machine you're running it on?
     
  10. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    My firewall is setup properly for things like that as we're running a public server as well, but I disabled for this test anyway and didn't work.

    I did try going back to 5.3.1f1 instead of p3 and that actually managed to get a connection through IP but I'm still getting roughly 30 fps in an empty scene where my target is 60 and when I add one or two low poly objects the fps drops by 10 each time

    PS: Quality setting is set to good
     
  11. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Are you clearing your camera to the procedural skybox or solid color? It's not clear whether that framerate is on a phone or a PC. What does the profiler say?
     
  12. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    It's clearing on a skybox. On PC, Samsung S6 and iPhone 5S we're getting 60fps at all times.
    On Lumia 920 which is a windows phone upgraded to Windows 10 we're getting max 30 fps on a scene where we have nothing but a quad and some low res UI and when we start adding some low poly meshes the fps drops immediately whilst on every other device it stays at 60fps without any change.

    Edit: We checked on an Android Hudl as well which is much older than any of the above and it's maximum fps 50 on an empty scene and with a scene full of assets at 20 fps.
     
    Last edited: Jan 22, 2016
  13. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    What does the profiler say?

    I'd try switching to clearing to solid color as a test: that will tell you whether the skybox is the culprit (I've have seen it be so several times).

    I'd also check to confirm that antialiasing and anisotropic filtering is disabled. They are both super expensive on mobile devices.
     
  14. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Profiler Image: https://www.dropbox.com/s/lvospkc7wu9vzuh/Screenshot 2016-01-22 12.20.16.png?dl=0

    It doesn't really say much, if it's a bug within unity for the Universal builds then the profiler won't help.

    When I set it to clear with color on an empty scene I get up to 40 fps now but same results when I get a simple quad with mobile diffuse on it.

    With antialiasing and anisotropic filtering off I get +1 maybe +2 fps but nothing more. The scene is pretty empty so these optimizations make small differences. Even ambient source is set to color and not skybox.
     
  15. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    I wouldn't be so quick to say it's Unity's bug. What's exactly in the scene? Profiler is saying that CPU waits for the GPU to finish rendering 58 ms every frame. It must be drawing something if it's taking that long.
     
  16. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    A quad and 5 low poly models around 100 polys each with standard material with one texture in them, one directional light in the scene with or without shadows.

    If it's running at +15 fps on a device that's 2-3 years older then it can't be my setup, it must be something with the build
     
  17. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    You could use VS2015 graphics analysis tool to see where the GPU is spending the time. You can do that by pressing Debug -> Graphics -> Start Diagnostics, then wait for the game to load until you see bad performance and press Capture Frame. Once frame is captured, stop debugging, press on the frame to view more info. In the main window, there will be Frame Analysis tab, in which there's one button: "Run Analysis for frame n.". Press that. It will take a few minutes, and produce a nice report telling you exactly how much time the GPU spent processing each draw call during that frame.
     
  18. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    It never starts. Whenever I try to do that, it shows as if it's trying to start the test and then it immediately stops, closing the app. It doesn't work with either release or debug :(
     
  19. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Which VS version do you have installed? The graphics debugger/profiler is very finicky... sometimes takes a lot of effort to get it working. I'd try updating to VS2015 Update 1 if you haven't done so already.
     
  20. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Yeap, that's the one I have. I tried it again and again but it just doesn't want to run :/
     
  21. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Try master config. I just ran into this exact same thing today - it looks like the graphics debugger crashes on our timer queries code... I'll look if we can fix it.
     
  22. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Yeah I tried all of the setups, I ll keep testing, see if it unblocks randomly. Any other clues as to why performance is down?
     
  23. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    I found a workaround. In Visual Studio, go to Tools -> Options -> Graphics Diagnostics -> Capture, and uncheck "Stop capture if any SDK layers errors are found":

     
  24. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Still no change :/ I'm trying it on release because Master says it's not supported
     
  25. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Could you describe exactly what happens when you press debug -> start diagnostics?
     
  26. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    VS: it starts building as normal
    VS: copies files accross
    VS: Completes the sending
    Phone: Goes into the splash screen
    Phone: rotates to match the landscape view
    Phone: still loading, no unity screen or otherwise
    Phone: turns black for a few seconds

    and I'll be damned as I was typing it, it worked
     
  27. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
  28. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Now it doesn't work when I try to do it again:

    VS: it starts building as normal
    VS: copies files accross
    VS: Completes the sending
    Phone: Goes into the splash screen
    Phone: rotates to match the landscape view
    Phone: still loading, no unity screen or otherwise
    Phone: turns black for a few seconds

    and goes back to the tiles screen of the phone
     
  29. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Go to project properties, debugging tab and set debugger type to "native". Let me know if that changes anything.
     
  30. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    It worked but after I make a screenshot it says: Playback on the phone requires Windows 8.1 tools :/
     
  31. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    When you installed VS 2015, do you remember whether you installed Windows 8.1 SDK/tools? I'd never thought that using graphics debugger would need that, but apparently they do. You can press "Modify" on Visual Studio installation in Programs and Features under Control panel, and add that feature. It will download and install everything it needs.
     
  32. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    hah I was looking for that, another 7GB off my ssd *sigh*
     
  33. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    You don't need the emulators. Just the Tools/SDK. Emulators take the majority of those 7 GB and aren't generally useful.
     
  34. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Hmm I couldn't find a way to take them out :/
     
  35. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    You should be able to uninstall them from "Programs and features" in control panel separately.

    Anyway, did the graphics diagnostics tools start working?
     
  36. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    An error occurred!
    The analysis engine encountered an error.

    Message The analysis tool returned an error.
    Code 0x80630004
     
  37. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,478
    Did you stop debugging before trying to analyze the frame? I'd also try rebooting both PC and the phone just in case.
     
  38. Nihil688

    Nihil688

    Joined:
    Mar 12, 2013
    Posts:
    503
    Yeap, otherwise it won't let me. I've rebooted a few times since.