fix shadowing width/height on resize

This commit is contained in:
Mischa Spiegelmock
2018-04-08 12:04:00 -07:00
parent 4b5f671775
commit fc5451076c

View File

@ -98,7 +98,7 @@ void projectMSDL::beginAudioCapture() {
unsigned int maxSamples = audioChannelsCount * audioSampleCount;
pcmBuffer = (unsigned char *) malloc(maxSamples);
SDL_PauseAudioDevice(audioDeviceID, false);
this->pcm()->initPCM(2048);
pcm()->initPCM(2048);
}
void projectMSDL::endAudioCapture() {
@ -114,7 +114,7 @@ void projectMSDL::maximize() {
}
SDL_SetWindowSize(win, dm.w, dm.h);
this->resize(dm.w, dm.h);
resize(dm.w, dm.h);
}
void projectMSDL::toggleFullScreen() {
@ -177,9 +177,9 @@ void projectMSDL::addFakePCM() {
pcm()->addPCM16(pcm_data);
}
void projectMSDL::resize(unsigned int width, unsigned int height) {
this->width = width;
this->height = height;
void projectMSDL::resize(unsigned int width_, unsigned int height_) {
width = width_;
height = height_;
settings.windowWidth = width;
settings.windowHeight = height;
projectM_resetGL(width, height);