0
votes

March 27 2020: The question boils down to how to run applications in Nvidia graphics card. If Intel Graphics card is enabled, OpenGL version is 4.6 for both Nvidia and Intel GPU's according to GPU-Z software. But, if disable Intel, to run the application using Nvidia, the application crashes; GPU-Z shows OpenGL version 1.1. So, how can I run the application with Nvidia graphics cards?

Notes: 1. I tried adding the application in the graphics settings to use high performance GPU, but the application uses Intel GPU. 2. Also, tried adding the application in Nvidia Control Panel to no luck.

March 16 2020: I was executing the example1 code in NanoGUI in Windows 10. The program is working when I connect my display using HDMI cable(connected to motherboard), but crashes without any errors using DP cable(connected to NVIDIA graphics card). I have Intel UHD Graphics 630 and NVIDIA GeForce GT 730 in my system. The driver version of NVIDIA is 26.21.14.4250.

I ran a simple OpenGL code in debug mode, and the program crashes at glfwInit() function. The error is at

libEGL!eglDestroyImageKHR

Here is a sample code that crashes with DP port and works with the HDMI port.

// #include <glad/glad.h>
#include <GLFW/glfw3.h>

#include <iostream>

void framebuffer_size_callback(GLFWwindow* window, int width, int height);
void processInput(GLFWwindow *window);

// settings
const unsigned int SCR_WIDTH = 800;
const unsigned int SCR_HEIGHT = 600;

int main()
{
    // glfw: initialize and configure
    // ------------------------------
    glfwInit();

    // glfw window creation
    // --------------------
    GLFWwindow* window = glfwCreateWindow(SCR_WIDTH, SCR_HEIGHT, "LearnOpenGL", NULL, NULL);
    if (window == NULL)
    {
        std::cout << "Failed to create GLFW window" << std::endl;
        glfwTerminate();
        return -1;
    }
    glfwMakeContextCurrent(window);

    // render loop
    // -----------
    while (!glfwWindowShouldClose(window))
    {

        // glfw: swap buffers and poll IO events (keys pressed/released, mouse moved etc.)
        // -------------------------------------------------------------------------------
        glfwSwapBuffers(window);
        glfwPollEvents();
    }

    // glfw: terminate, clearing all previously allocated GLFW resources.
    // ------------------------------------------------------------------
    glfwTerminate();
    return 0;
}
1
If you have a simple piece of code that crashes then it would make sense to edit your question to include that code as your minimal reproducible example.G.M.
Is your driver up to date? A quick search on the nvidia homepage showed me that there is a 442.59 WHQL version of the game ready driver available and suggested for your device. I think you have a driver problem, because the glfwInit() should not fail otherwise and I encounted similar problems with bad driver installations before.OutOfBound
@OutOfBound I checked the driver version and it is 442.50 and this looks like the latest. How do I check whether OpenGL is supported by this driver or not?Navin Rahim
This driver should support OpenGL 4.5.OutOfBound
@OutOfBound I was disabling Intel graphics to force the code to use Nvidia, I read that this would disable working of Nvidia. Is there any way to force Nvidia GPU on the app?Navin Rahim

1 Answers

0
votes

The issue was solved in another update of the Nvidia drivers to 445.75 standard.

Also, I found that remote desktop has issues with Nvidia drivers. Remote software programs sometimes install their own display drivers. More can be found here.