Return to Level1Techs.com

A little teaser of what is to come :)


#568

Oh I get it and I can see how powerful it would be in a full 3d engine… but for this… :tired_face:


#569

Damn. That is quite a lot of code for such a basic function. I am coder myself but web oriented instead of c/ c++. Aren’t there some templates for vulkan api? In my earlier days I did some ancient opengl but that would be of no use nowadays :wink:


#570

Tutorials and info a plenty, but even to get a basic pipeline up and running I am now approaching 2000 lines.


#571

Please everyone make very special note of this:

There is a reverse engineered method to enable the NvFBC capture API on consumer cards, it has been published by a third party, and no I will not be linking it here. Using said code/application with Looking Glass puts this entire project in jeopardy, the idiot (putting my feelings lightly) that posted the code is themselves at very high risk of being sued.

The NVIDIA Capture API is bound by the following License Agreement:

In it, it clearly states:

install, use and reproduce the software delivered by NVIDIA, make modifications and create derivative works of sample source code software delivered by NVIDIA and use documentation delivered by NVIDIA, provided that the software is executed only in NVIDIA GRID, Tesla or Quadro 2000+ hardware products that you separately obtain from NVIDIA or its affiliates, all to develop, test and service your products (each, a “Customer Product”) that are interoperable with NVIDIA GRID, Tesla or Quadro 2000+ hardware products

Use of the NVIDIA Capture API with Looking Glass by means of even a third party tool as mentioned above on non “NVIDIA GRID, Tesla or Quadro 2000+ hardware products” would be violating this license agreement.

If people start using this it is very likely going to land us in VERY hot water. Please DO NOT use any such software, either get a supported card or use DXGI DD like the rest of us.


#572

I don’t understand what the big deal with reverse engineering is and probably these terms don’t even apply where I live. This is somewhat similar to how Apples EULA discourages installing macOS on non-Apple hardware, which they just can’t forbid here.

Anyway, I’ll try to keep distance from NVidia hardware altogether, this should leave me on the safe side…


#573

The issue isn’t the reverse engineering, the issue is enabling Looking Glass to use the API. If NVIDIA decide to pay attention to us as people are illegally using it in breach of their agreement they could legally attack the Looking Glass project, just knowing they could destroy the project financially even if they couldn’t win in court. It is simply not worth the risk.


#574

What advantage would have to enable such NvFBC capture API on consumer cards?

I’m interested how NVIDIA is disabling capabilities on consume grade products. Are those capabalities blocked by software, hardware or both?
Does it make difference if you have a laptop versus a PC?


#575

ShadowPlay & Steam can use it on any NVIDIA hardware… that should answer your question.


#576

Would LookingGlass be adequate to play FPS or competitive games?


#577

Answer = Very yes! :smiley:. That’s the main goal of Looking Glass.


#578

What about laptops/notebooks, like Macbook Pro, MSi, Asus, Acer, Razer, Aorus, Clevo, Lenovo, Sager? I’m trying to get GPU passthrough on my MSI GT73VR, but no luck, the system doesn’t boot.

Provided that my MSi could work, and its screen refreshes at 120Hz, would that be preserved or will run at 50/60Hz on the integrated display of the laptop?


#579

Outside of the scope of this project sorry, perhaps ask for help in a new thread or on the VFIO subreddit.


#580

My newb self has been looking for instructions on configuring VFIO for hours. Thanks.


#581

Well, there goes Freesync on an Nvidia card.

You can still sift over how OBS hooks into programs and the screen to apply those methods to Looking Glass.


#582

Yeah Vulkan needs every little explicit detail passed into create info structs when creating objects, and every cabability queried for in properties structs. But I think that the low level swapchain implementation could be useful for your project.

I think the external memory extensions could be useful for avoiding copying the framebuffer too many times. Maybe you could copy it directly into the destination framebuffer by accessing the swapchain images directly, though you wouldn’t be able to scale the image that way.

The display and display_swapchain extensions could be used to output the result directly to a monitor (fullscreen) rather than through some window handle that is composited by the operating system. That could maybe reduce latency a bit, but don’t quote me on that.

EDIT:
To be more specific about external memory. You want the VK_EXT_external_memory_host extension. It is a brand new extension though, I haven’t heard of a GPU/driver combo that supports it yet. That extension allows creating a VkMemory object from an opaque pointer. Then you could create a VkBuffer or VkImage object and bind the memory object, then use vkCmdCopyBufferToImage or vkCmdCopyImage to copy it either directly into the swapchain image or into an image suitable for sampling (might work to sample the image framebuffer directly?). If you’re just copying it into another image, I’d recommend using a VkBuffer object for the shared framebuffer, so you’ll have less image layout transitions to deal with.


#583

Thanks I will try that


#584

Do you need a dummy hdmi plug to use this?


#585

a second monitor works too but essentially at the moment those are the only options i know of


#586

It essentially just needs an input source to work so if your monitor has multiple inputs e.g. DP and HDMI or multiple HDMI ports you can just plug the guest gpu into another source and it should work even if it isn’t the active one.


#587

So as long as it is outputting a digital signal it will work?