mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-09-24 23:26:37 +00:00
Merge branch 'master' into mac
# Conflicts: # GpApp/Main.cpp
This commit is contained in:
@@ -2711,7 +2711,7 @@ bool GpDisplayDriver_SDL_GL2::InitBackBuffer(uint32_t width, uint32_t height)
|
||||
m_gl.BindFramebuffer(GL_FRAMEBUFFER, 0);
|
||||
}
|
||||
|
||||
m_useUpscaleFilter = ((m_pixelScaleX < 2.0f && m_pixelScaleX > 1.0f) || (m_pixelScaleY < 2.0f && m_pixelScaleY > 1.0f));
|
||||
m_useUpscaleFilter = (m_pixelScaleX == 1.5f || m_pixelScaleX == 2.5f || m_pixelScaleY == 1.5f || m_pixelScaleY == 2.5f);
|
||||
|
||||
if (m_useUpscaleFilter)
|
||||
{
|
||||
|
@@ -197,7 +197,7 @@ void GpInputDriverSDLGamepad::ProcessSDLEvent(const SDL_Event &msg)
|
||||
IGpVOSEventQueue *evtQueue = m_properties.m_eventQueue;
|
||||
|
||||
switch (msg.type)
|
||||
{
|
||||
{
|
||||
case SDL_CONTROLLERAXISMOTION:
|
||||
{
|
||||
const SDL_ControllerAxisEvent &axisMsg = msg.caxis;
|
||||
@@ -231,8 +231,8 @@ void GpInputDriverSDLGamepad::ProcessSDLEvent(const SDL_Event &msg)
|
||||
|
||||
m_pendingEvents.push_back(evt);
|
||||
}
|
||||
break;
|
||||
case SDL_CONTROLLERBUTTONDOWN:
|
||||
break;
|
||||
case SDL_CONTROLLERBUTTONDOWN:
|
||||
case SDL_CONTROLLERBUTTONUP:
|
||||
{
|
||||
const bool isDown = (msg.type == SDL_CONTROLLERBUTTONDOWN);
|
||||
@@ -287,22 +287,22 @@ void GpInputDriverSDLGamepad::ProcessSDLEvent(const SDL_Event &msg)
|
||||
|
||||
m_pendingEvents.push_back(evt);
|
||||
}
|
||||
break;
|
||||
break;
|
||||
case SDL_CONTROLLERDEVICEADDED:
|
||||
HandleDeviceAdded(msg.cdevice.which);
|
||||
break;
|
||||
break;
|
||||
case SDL_CONTROLLERDEVICEREMOVED:
|
||||
HandleDeviceRemoved(msg.cdevice.which);
|
||||
break;
|
||||
break;
|
||||
case SDL_CONTROLLERDEVICEREMAPPED:
|
||||
// Not really sure what to do here, just re-add it
|
||||
HandleDeviceRemoved(msg.cdevice.which);
|
||||
HandleDeviceAdded(msg.cdevice.which);
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
IGpInputDriver *GpDriver_CreateInputDriver_SDL2_Gamepad(const GpInputDriverProperties &properties)
|
||||
{
|
||||
return GpInputDriverSDLGamepad::Create(properties);
|
||||
return GpInputDriverSDLGamepad::Create(properties);
|
||||
}
|
||||
|
@@ -58,7 +58,7 @@
|
||||
"vec4 ApplyDesaturation(float desaturation, vec4 color)\n"\
|
||||
"{\n"\
|
||||
" // This is intentionally done in gamma space\n"\
|
||||
" if (desaturation == 0.0)\n"\
|
||||
" if (desaturation == 0.0 || (color.r == 1.0 && color.g == 1.0 && color.b == 0.0))\n"\
|
||||
" return color;\n"\
|
||||
"\n"\
|
||||
" float grayLevel = dot(color.rgb, vec3(3.0, 6.0, 1.0) / 10.0);\n"\
|
||||
|
Reference in New Issue
Block a user