Direct3D could not be created after resume (1 Viewer)

The_Stig

Retired Team Member
  • Premium Supporter
  • April 5, 2005
    2,176
    428
    MediaPortal Version: 1.4.0

    Description
    I get this Direct3D error after resume quite often lately (hangs on "Initializing DirectX" and after around 2 Minutes it closes MP with the Direct3D error).
    Debug-log attached. Since its not happening all the time I could only export present logs.
    I already tried to increase the time when MP starts to 5 seconds, but this doesnt help at all. First time if have seen this behaviour was with 1.4 pre-release.
    What I think is a bit weird is that MP is starting up fully. Shouldnt it only re-initialize itself? At least that is what I am seeing most of the time after a resume.
    Anyone with an idea?

    Steps to Reproduce:
    1. Resume MP from standy
     

    Froderikus

    Portal Member
    May 27, 2013
    8
    2
    52
    Home Country
    Germany Germany
    Hello,

    I also have this problem after reboot. Does not help to set the internal "Delay Startup" function.
    I use a third party software called "StartupDelayer" to set a startup delay of 5 sec.
    This does the job.

    Frank
     
    Last edited:

    BlueMax1916

    Super User
  • Team MediaPortal
  • Super User
  • January 29, 2007
    704
    125
    Home Country
    Germany Germany
    I have the same problem after a fresh restart. MePo 1.4.0 hangs at 'Initializing DirectX'. When a fire up the task manager I see that FullScreenSplashScreen.exe hangs. After killing it and another start it loads. I have set MePo to autostart via autostart folder. This problem began after updating to 1.4.0 from 1.3.0 yesterday.

    I have reinstalled latest DirectX9 already but to no avail.
     
    Last edited:

    The_Stig

    Retired Team Member
  • Premium Supporter
  • April 5, 2005
    2,176
    428
    Thanks for your answers. I'd like to get this fixed and not just workaround with other tools. So may I ask if you attach logs when happening? Best run MP debug mode and click on "Export all current avalílable logs". So I hope to find a dev when other have this problem too. Thanks!
     

    mm1352000

    Retired Team Member
  • Premium Supporter
  • September 1, 2008
    21,577
    8,224
    Home Country
    New Zealand New Zealand
    @Scythe42 (seem to be tagging you quite a lot recently - sorry :))
    I guess the error message is due to _renderTarget having been disposed, but my question would be why/how the application is disposed. Unhandled exception in the standby process (total guess :)) ???

    @The_Stig
    Seems like your logs are not debug-level. Could you please change to debug-level in MP configuration so we can have full details for when this problem occurs next time.
     

    The_Stig

    Retired Team Member
  • Premium Supporter
  • April 5, 2005
    2,176
    428
    Seems like your logs are not debug-level. Could you please change to debug-level in MP configuration so we can have full details for when this problem occurs next time.
    Will do. Thanks for looking into this issue.
     

    BlueMax1916

    Super User
  • Team MediaPortal
  • Super User
  • January 29, 2007
    704
    125
    Home Country
    Germany Germany
    Here is my log. I have to kill MePo during DirectX Initialisation because it hangs. When the trouble starts I hear a Windows error sound in the background.

    Cheers
     
    Last edited:

    Scythe42

    Retired Team Member
  • Premium Supporter
  • June 20, 2009
    2,065
    2,703
    50
    Berlin
    Home Country
    Germany Germany
    MP comes up too early and lands in an "environment" before D3D is fully ready. Delaying startup inside MP has no effect here naturally, as the executable is already loaded.

    This does down to an issue with Manged DirectX that loads some resources that cannot be re-initialized in .NET as soon as the executable loads you are stuck in a given environment.

    Please give it a try starting MP with the Task Scheduler if the problem still persists. Changing from the legacy Run Key to the Task Scheduler is simple.

    Or use an other tool for a more controlled Auto Start of applications.

    Also there is a proper Error Message Box, but it is overlayed by the damn splash screen that is on top of it. A simple OK would work here, but you cannot click on it. Always on Top is evil...
     
    Last edited:

    The_Stig

    Retired Team Member
  • Premium Supporter
  • April 5, 2005
    2,176
    428
    Please give it a try starting MP with the Task Scheduler if the problem still persists. Changing from the legacy Run Key to the Task Scheduler is simple.
    Erm...could you explain a bit more for a dummy?
     

    Scythe42

    Retired Team Member
  • Premium Supporter
  • June 20, 2009
    2,065
    2,703
    50
    Berlin
    Home Country
    Germany Germany
    Windows has its own Task Scheduler since for ever. I think since the Win95 Plus Pack.

    Here is a video introduction:


    Just autostart MP with a trigger executed upon booting Windows. In fact this is the way autostart should be handled since Windows 7 according to MS guidelines. Was overhauled with Vista a lot with additional feature like executing stuff based on entries in the event log...

    And changing code to create an entry here instead of the run key is very very simple. Have a branch laying around since ages for MP that uses the task management library.

    Edit:
    Interesting question now is: will this solve the issue for you or does it in the end come down to an issue with Managed DirectX, meaning MP needs an autostart wrapper that actually does the delay before starting the MediaPortal.exe.

    As said code wise nothing can be done, because I tracked the issue down to Managed Direct X, that cannot re-init some stuff once the runtime is loaded.

    I consider this a defect in MP, but nothing that can be solved easily without some major changes. In the end the deprecated Managed DirectX has to anyway and such problems go away with it.
     
    Last edited:

    Users who are viewing this thread

    Top Bottom