Skip to content

Commit

Permalink
Enable linear filtering in OTG mode
Browse files Browse the repository at this point in the history
This improves the icon quality with non-standard window size.
  • Loading branch information
rom1v committed Apr 28, 2022
1 parent 74b4697 commit 93b542c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/src/usb/scrcpy_otg.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ scrcpy_otg(struct scrcpy_options *options) {

const char *serial = options->serial;

if (!SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, "1")) {
LOGW("Could not enable linear filtering");
}

// Minimal SDL initialization
if (SDL_Init(SDL_INIT_EVENTS)) {
LOGE("Could not initialize SDL: %s", SDL_GetError());
Expand Down

0 comments on commit 93b542c

Please sign in to comment.