Skip to content

Commit

Permalink
Move SDL_HINT_RENDER_SCALE_QUALITY setting to non-OSX platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
guillep committed Mar 4, 2021
1 parent f29736f commit 45f883a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
3 changes: 1 addition & 2 deletions src/OSWindow-SDL2/SDL2.class.st
Expand Up @@ -250,8 +250,7 @@ SDL2 class >> initLibrary [

self
setHint: SDL_HINT_VIDEO_ALLOW_SCREENSAVER value: '1';
setHint: SDL_HINT_NO_SIGNAL_HANDLERS value: '1';
setHint: SDL_HINT_RENDER_SCALE_QUALITY value: '1'.
setHint: SDL_HINT_NO_SIGNAL_HANDLERS value: '1'.

self init: SDL_INIT_NOPARACHUTE.
Session := Smalltalk session.
Expand Down
3 changes: 3 additions & 0 deletions src/OSWindow-SDL2/SDLAbstractPlatform.class.st
Expand Up @@ -7,6 +7,9 @@ Get the corresponding class to use through
Class {
#name : #SDLAbstractPlatform,
#superclass : #Object,
#pools : [
'SDL2ConstantsHint'
],
#category : #'OSWindow-SDL2-Bindings'
}

Expand Down
3 changes: 3 additions & 0 deletions src/OSWindow-SDL2/SDLNullPlatform.class.st
Expand Up @@ -14,5 +14,8 @@ SDLNullPlatform >> afterSetWindowTitle: aString onWindow: aOSSDLWindow [
{ #category : #initialization }
SDLNullPlatform >> initPlatformSpecific [

"For windows and Unix, we activate linearization.
This does not work properly on OSX with retina display, blurrying the rendering"

SDL2 setHint: SDL_HINT_RENDER_SCALE_QUALITY value: '1'
]

0 comments on commit 45f883a

Please sign in to comment.