I had the problem that sometimes ofter resuming from standby parts of the screen were black and the other part showed the desktop. When i pressed the down key on my MCE compatible remote MediaPortal was reacting again and also show correctly on screen again.
I hunted down the problem in the MedioPortal 1.0 code and found out that sometimes OnSizeChanged was called in class D3DApp after resuming from standby. That leads to the affect that MediaPortal tried to change from fullscreen mode to normal mode although MediaPortal was started in fullscreen mode.
I fixed that issue by extending the if statement in OnSizeChanged. Current code:
2475 protected override void OnSizeChanged(EventArgs e)
2476 {
2477 if (GUIGraphicsContext.IsDirectX9ExUsed() && this.Visible && !_resizeOngoing && !_toggleFullWindowed &&
2478 !_ignoreNextResizeEvent && this.WindowState == _windowState)
2479 {
2480 Log.Info("Main: OnSizeChanged - Resetting device");
2481 SwitchFullScreenOrWindowed(false);
2482 OnDeviceReset(null, null);
2483 }
2484 base.OnSizeChanged(e);
2485 }
New code:
2475 protected override void OnSizeChanged(EventArgs e)
2476 {
2477 if (GUIGraphicsContext.IsDirectX9ExUsed() && this.Visible && !_resizeOngoing && !_toggleFullWindowed &&
2478 !_ignoreNextResizeEvent && this.WindowState == _windowState && !startFullscreen)
2479 {
2480 Log.Info("Main: OnSizeChanged - Resetting device");
2481 SwitchFullScreenOrWindowed(false);
2482 OnDeviceReset(null, null);
2483 }
2484 base.OnSizeChanged(e);
2485 }
Can someone please put this change to subversion.
TV-Server Version: 1.0
MediaPortal Version: 1.0
MediaPortal Skin: Blue3wide
Windows Version: Windows Vista Ultimate SP1
CPU Type: Intel Core 2 Duo 2.1 GHz
HDD: 160 GB
Memory: 1 MB
Motherboard: Shuttle FG33 (SG33G5M)
Video Card: GMA 3100 (onboard)
Video Card Driver: Shuttle 2008-06-05
Sound Card: Realtek ALC888DD
Sound Card AC3:
Sound Card Driver: Shuttle 2007-08-23
1. TV Card: Terratec Cinergy S2 HD PCI
1. TV Card Type: DVB-S, DVB-S2
1. TV Card Driver:
2. TV Card: -
2. TV Card Type: -
2. TV Card Driver: -
3. TV Card: -
3. TV Card Type: -
3. TV Card Driver: -
4. TV Card: -
4. TV Card Type: -
4. TV Card Driver: -
MPEG2 Video Codec: MPV
MPEG2 Audio Codec: MPA
h.264 Video Codec: none
Satelite/CableTV Provider: Astra 19.2°E
HTPC Case: Shuttle SG33G5M
Cooling:
Power Supply:
Remote: Shuttle Multimedia Remote (MCE compatible)
TV: Sony
TV - HTPC Connection: HDMI
I hunted down the problem in the MedioPortal 1.0 code and found out that sometimes OnSizeChanged was called in class D3DApp after resuming from standby. That leads to the affect that MediaPortal tried to change from fullscreen mode to normal mode although MediaPortal was started in fullscreen mode.
I fixed that issue by extending the if statement in OnSizeChanged. Current code:
2475 protected override void OnSizeChanged(EventArgs e)
2476 {
2477 if (GUIGraphicsContext.IsDirectX9ExUsed() && this.Visible && !_resizeOngoing && !_toggleFullWindowed &&
2478 !_ignoreNextResizeEvent && this.WindowState == _windowState)
2479 {
2480 Log.Info("Main: OnSizeChanged - Resetting device");
2481 SwitchFullScreenOrWindowed(false);
2482 OnDeviceReset(null, null);
2483 }
2484 base.OnSizeChanged(e);
2485 }
New code:
2475 protected override void OnSizeChanged(EventArgs e)
2476 {
2477 if (GUIGraphicsContext.IsDirectX9ExUsed() && this.Visible && !_resizeOngoing && !_toggleFullWindowed &&
2478 !_ignoreNextResizeEvent && this.WindowState == _windowState && !startFullscreen)
2479 {
2480 Log.Info("Main: OnSizeChanged - Resetting device");
2481 SwitchFullScreenOrWindowed(false);
2482 OnDeviceReset(null, null);
2483 }
2484 base.OnSizeChanged(e);
2485 }
Can someone please put this change to subversion.
TV-Server Version: 1.0
MediaPortal Version: 1.0
MediaPortal Skin: Blue3wide
Windows Version: Windows Vista Ultimate SP1
CPU Type: Intel Core 2 Duo 2.1 GHz
HDD: 160 GB
Memory: 1 MB
Motherboard: Shuttle FG33 (SG33G5M)
Video Card: GMA 3100 (onboard)
Video Card Driver: Shuttle 2008-06-05
Sound Card: Realtek ALC888DD
Sound Card AC3:
Sound Card Driver: Shuttle 2007-08-23
1. TV Card: Terratec Cinergy S2 HD PCI
1. TV Card Type: DVB-S, DVB-S2
1. TV Card Driver:
2. TV Card: -
2. TV Card Type: -
2. TV Card Driver: -
3. TV Card: -
3. TV Card Type: -
3. TV Card Driver: -
4. TV Card: -
4. TV Card Type: -
4. TV Card Driver: -
MPEG2 Video Codec: MPV
MPEG2 Audio Codec: MPA
h.264 Video Codec: none
Satelite/CableTV Provider: Astra 19.2°E
HTPC Case: Shuttle SG33G5M
Cooling:
Power Supply:
Remote: Shuttle Multimedia Remote (MCE compatible)
TV: Sony
TV - HTPC Connection: HDMI