Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by EarMaster · Aug 29, 2013 at 08:26 AM · errorerror-handlingdirect3d

Player loses fullscreen

I'm currently working on a standalone application which has to run fullscreen for several days. While running my machine overnight with the application I experience that in the morning the application has left fullscreen and switched from FullHD (1080p) to HDReady (720p). As the machine the application has to run will be not accessible without enourmous effort just restarting the whole thing is no solution.

I checked the logs and at some point the application starts to spam the following message:

 HandleD3DDeviceLost
   HandleD3DDeviceLost: still lost
 Skipped rendering frame because GfxDevice is in invalid state (device lost)
  
 (Filename:  Line: 1494)
 
 [… this repeats alot …]
 
 HandleD3DDeviceLost
   HandleD3DDeviceLost: still lost
 Skipped rendering frame because GfxDevice is in invalid state (device lost)
  
 (Filename:  Line: 1494)
 
 HandleD3DDeviceLost
   HandleD3DDeviceLost: still lost
 d3d: failed to lock level 0 of texture 115 [invalid call]
 d3d: failed to lock level 0 of texture 117 [invalid call]
 d3d: failed to lock level 0 of texture 119 [invalid call]
 d3d: failed to lock level 0 of texture 121 [invalid call]
 d3d: failed to lock level 0 of texture 123 [invalid call]
 d3d: failed to lock level 0 of texture 125 [invalid call]
 Skipped rendering frame because GfxDevice is in invalid state (device lost)
  
 (Filename:  Line: 1494)
 
 HandleD3DDeviceLost
   HandleD3DDeviceLost: needs reset, doing it
 FullResetD3DDevice
 ResetD3DDevice
 dev->Reset
 D3Dwindow device not lost anymore
 Skipped rendering frame because GfxDevice is in invalid state (device lost)
  
 (Filename:  Line: 1494)
 
 HandleD3DDeviceLost
   HandleD3DDeviceLost: still lost
 Skipped rendering frame because GfxDevice is in invalid state (device lost)
  
 (Filename:  Line: 1494)
 
 [… again this repeats alot …]
 
 HandleD3DDeviceLost
   HandleD3DDeviceLost: still lost
 Skipped rendering frame because GfxDevice is in invalid state (device lost)
  
 (Filename:  Line: 1494)
 

I also checked Windows' error log but it didn't logged anything of importance. I also checked this thread from the forum, with no success.

Do you have any ideas how to fix this or at least how to handle this error properly.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by EarMaster · Aug 30, 2013 at 09:15 AM

I didn't solve the problem, but I'm now using a workaround which checks if the application has left fullscreen or changed it's full resolution and if this happened restores both.

 using UnityEngine;
 
 public class ResolutionChecker : MonoBehaviour {
 
     public bool ForceFullscreen = true;
 
     void Start() {
         if (Application.isEditor)
             ForceFullscreen = false;
     }
 
     void Update() {
         if (ForceFullscreen && (Screen.width!=Screen.currentResolution.width || !Screen.fullScreen))
             Screen.SetResolution(Screen.currentResolution.width, Screen.currentResolution.height, true);
     }
 }



If you have another suggestion how to fix the actual error or how it could be handled please post it…

I also found the real reason for this error: The monitor was sending a signal it has been turned off after some time of inactivity. This leads to Windows powering down the GPU as no output device is present (a behaviour which cannot be disabled). The solution was to use an modified adapter which doesn't transmit this signal. This solution originated from Microsoft Technet.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by NonGamingCoder · Aug 29, 2013 at 11:08 AM

Sounds like Windows is powering down your GPU device, although I can't be certain from what you have said.

In Windows, if the device is powered down, then powered up again, you will have to reacquire the device and reinit. (see PowerModeChanged event on MSDN)

After reading the post you cited, I find it hard to believe that using multiple threads is going to lose your device. Sounds like a bit of a goose chase.

Have you tried putting the machine into sleep/standby and then waking again? The test would take ~20 seconds and would probably reproduce the error you see.

But again, it's hard to tell from what you've mentioned.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image EarMaster · Aug 29, 2013 at 01:30 PM 0
Share

Thanks for your answer. I tried to reproduce the error with the standby mode. But I wasn't able to do so. The application was up and running in fullscreen and FullHD after I woke the machine up again. I also checked the Windows energy profile. I had already disabled every automatic power off / energy save mechanism when I set up the machine for this task.

I'm using $$anonymous$$ovie Textures quite a lot, is it possible that there is some memory leak causing the graphic memory running full?

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

17 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Lots of errors after importing john lemon's haunted jaunt package from asset store 0 Answers

InvalidCastException: Cannot cast from source type to destination type. 1 Answer

Why am I receiving "null" in console instead of the name? 2 Answers

What compiling error is this?! 1 Answer

I need help with this script, where are the errors? 2 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges