We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4149 - metal: needs to resize window before things are actually displayed
Summary: metal: needs to resize window before things are actually displayed
Status: RESOLVED FIXED
Alias: None
Product: SDL
Classification: Unclassified
Component: render (show other bugs)
Version: 2.0.8
Hardware: x86_64 macOS 10.13
: P2 normal
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-04-24 15:43 UTC by SuperZazu
Modified: 2018-05-28 15:13 UTC (History)
2 users (show)

See Also:


Attachments
a minimal C program that reproduces the bug (2.79 KB, text/plain)
2018-04-24 15:43 UTC, SuperZazu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description SuperZazu 2018-04-24 15:43:48 UTC
Created attachment 3230 [details]
a minimal C program that reproduces the bug

Good morning.

On macOS 10.13.4, while trying to do:
```
SDL_SetHint(SDL_HINT_RENDER_DRIVER, "metal");
```

I find that nothing is displayed on the window at launch. I need to resize the window at least once before anything starts showing. Note that everything works as expected with the default OpenGL driver.

Also, another little thing, I noticed that the `SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, "0");` setting is not taken into account (also when using metal driver): it always displays graphics as if the scale quality was set to 1 (linear filtering).

I attached a little C program that reproduces the bug: try to resize the window + comment/uncomment the `SDL_SetHint(SDL_HINT_RENDER_DRIVER, "metal");` line).

Thank you for your time,
Best regards
Comment 1 Ryan C. Gordon 2018-05-28 00:32:20 UTC
This should be fixed by https://hg.libsdl.org/SDL/rev/9116d02d3feb

--ryan.
Comment 2 SuperZazu 2018-05-28 15:13:39 UTC
Indeed, the commit fixes the bug. Thank you.