godotengine / godotengine/godot

Opening window-node makes me lose -10fps in compability mode

Open
#89,438 0 comments 0 reactions 0 assignees View on GitHub
bug enhancement performance topic:rendering
Dominant language
C++
Stars
117k
Forks
26.8k
PR merge metrics
PR metrics pending

Description

### Tested versions

Reproducible in godot 4.0-4.3 dev4

### System information

Windows 11, Compatibility mode

### Issue description

I try to target my game for older devices or laptops without dGPU.

My game opens another window with the window-node (embedded subwindows are off.) Without opening another window the game runs smoothly 60fps. With window the game fps drops to 50fps.

This is without opening window:
![image](https://github.com/godotengine/godot/assets/81559157/1c23c268-c999-4596-99fa-a72f2f5ccae9)

And this is with window opened:
![image](https://github.com/godotengine/godot/assets/81559157/9fa6c9c2-8a0a-40d8-8d7c-667a7f421db7)

The code for the opening window is here:
```
extends Control

const CONTROL_PANEL: PackedScene = preload("res://window.tscn")
func _ready():
var _scene = CONTROL_PANEL.instantiate()

_scene.title = "Control panel"
self.add_child(_scene)
```
Without vsync, my fps is around 1400 but will cause a lot of stuttering (Even if I cap fps to 60.

This is only reproducible in compatibility mode. Forward+ won't make this. I'm running this with intel 12th igpu for testing purposes. Somehow my RTX 3060 can handle the 2 windows.

This problem makes my game not suitable for older laptops even if it's a very simple game.

### Steps to reproduce

Run with igpu and make project compatibility mode.
1. Make the main scene and window scene (Just Godot sprite in both).

Main scene:
```
const CONTROL_PANEL: PackedScene = preload("res://window.tscn")
func _ready():
var _scene = CONTROL_PANEL.instantiate()

_scene.title = "Control panel"
self.add_child(_scene)
```

### Minimal reproduction project (MRP)

[MRP.zip](https://github.com/godotengine/godot/files/14585751/MRP.zip)

Contributor guide

Open the contributing guide

Research direction

Start with the attached MRP and reproduce the frame-rate drop on an Intel 12th-generation iGPU in Compatibility mode when a second window-node is opened. Compare the same project with one window and in Forward+; done means the extra window no longer causes the reported performance loss in Compatibility mode.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
game-dev, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.