r/GraphicsProgramming • • Sep 28 '21

Minimal NVIDIA example within GPU memory?

To get started, I just want to output something to a port on my NVIDIA Quadro P2000. I do not want to extend my display, just directly feed a monitor with what is generated.

0 Upvotes

9 comments sorted by

View all comments

Show parent comments

1

u/the_Demongod Sep 28 '21 edited Sep 28 '21

That's not really possible. The GPU is powered by a proprietary driver that has to run on an operating system in order to communicate with the GPU. You could connect it to a Raspberry Pi if your GPU driver supports it, but you won't be able to do it without an operating system. You need to stream huge amounts of data back and forth between the GPU in order to program it to do the stuff it normally does, you can't do it with just a circuit. If you want to do this without an operating system, you'll need to buy a high quality microcontroller and write a VGA controller application that will emit your graphics to the monitor as an analog signal, you won't be able to use a normal GPU.

I do not want the mouse or anything else on the screen, only my OpenGL output.

Create a GLFW context with

GLFWmonitor* monitor = glfwGetPrimaryMonitor();

which will make it fullscreen (borderless), then

glfwSetInputMode(window, GLFW_CURSOR, GLFW_CURSOR_DISABLED);

to hide the cursor.

If you have multiple windows then read this.

1

u/TTLAAJ Sep 29 '21

So this would do nothing for me? Direct Rendering Manager

DRM-NVDC is a compatibility library which implements the Direct Rendering Manager API (DRM) on top of the Tegra Display Controller kernel driver (NVDC).

1

u/the_Demongod Sep 29 '21

I think you're having an XY problem. Can you please explain what the end goal of your application is?

1

u/TTLAAJ Sep 29 '21

Not sure what XY would be. Anyway, one system outputs a video, my system outputs that video to a display with minor text overlayed.

1

u/the_Demongod Sep 29 '21 edited Sep 29 '21

The XY problem is when you ask a specific question to solve a sub-problem you're having, but the answer to the question as phrased is not the actual solution to your overall problem. In this case you're asking how to do something extremely strange and nonstandard when it could almost certainly be achieved with ordinary graphics programming. Unless you're writing your code on a machine that doesn't have an operating system (e.g. on a microcontroller), the question you're asking doesn't seem like what you actually want to do.

Depending on what a "system" is in this case (it would be great if you specified), you can simply write the frames of your video into an OpenGL texture, draw it on a framebuffer, draw your text over the framebuffer in a second pass, and push the frame to a fullscreen window on whichever monitor you like, with the mouse hidden.

0

u/WikiSummarizerBot Sep 29 '21

XY problem

The XY problem is a communication problem encountered in help desk and similar situations in which the person asking for help obscures the real issue, X, because instead of asking directly about issue X, they ask how to solve a secondary issue, Y, which they believe will allow them to resolve issue X on their own. However, resolving issue Y often does not resolve issue X, or is a poor way to resolve it, and the obscuring of the real issue and the introduction of the potentially strange secondary issue can lead to the person trying to help having unnecessary difficulties in communication and/or offering poor solutions.

[ F.A.Q | Opt Out | Opt Out Of Subreddit | GitHub ] Downvote to remove | v1.5