This commit is contained in:
Camilla Berglund
2012-09-12 19:35:52 +02:00
parent 83f5b920b9
commit 830f2b439c
16 changed files with 287 additions and 284 deletions
+1 -1
View File
@@ -120,7 +120,7 @@ int main(int argc, char** argv)
if (mode == GLFW_FULLSCREEN)
{
GLFWvidmode mode;
glfwGetVideoMode(glfwGetNextMonitor(NULL), &mode);
glfwGetVideoMode(glfwGetPrimaryMonitor(), &mode);
width = mode.width;
height = mode.height;
}
+1 -1
View File
@@ -101,7 +101,7 @@ int main(int argc, char** argv)
if (mode == GLFW_FULLSCREEN)
{
GLFWvidmode current_mode;
glfwGetVideoMode(glfwGetNextMonitor(NULL), &current_mode);
glfwGetVideoMode(glfwGetPrimaryMonitor(), &current_mode);
width = current_mode.width;
height = current_mode.height;
}
+7 -5
View File
@@ -199,8 +199,8 @@ static void test_modes(GLFWmonitor monitor)
int main(int argc, char** argv)
{
int ch, mode = LIST_MODE;
GLFWmonitor monitor = NULL;
int ch, i, count, mode = LIST_MODE;
GLFWmonitor* monitors;
while ((ch = getopt(argc, argv, "th")) != -1)
{
@@ -226,12 +226,14 @@ int main(int argc, char** argv)
if (!glfwInit())
exit(EXIT_FAILURE);
while ((monitor = glfwGetNextMonitor(monitor)))
monitors = glfwGetMonitors(&count);
for (i = 0; i < count; i++)
{
if (mode == LIST_MODE)
list_modes(monitor);
list_modes(monitors[i]);
else if (mode == TEST_MODE)
test_modes(monitor);
test_modes(monitors[i]);
}
exit(EXIT_SUCCESS);