Quick version: How can I properly configure the hardware.opengl.extraPackages variable, given the high number of possibilities? Just reading in this page of the wiki, I can see intel-media-driver, vaapiIntel, vaapiVdpau, libvdpau-va-gl, enableHybridCodec, but I’m also aware of intel-ocl, and I guess there is many more depending on your graphic card. Is there a tool that says “for this graphic card, use this module”?
My specific problem:
A while ago I was using the configuration:
hardware.opengl.extraPackages = with pkgs; [ intel-ocl ];
It was working, as I was detecting one CPU when I was using clinfo. But I noticed recently that opencl does not work anymore: clinfo lists zero devices. Back when it was still working, I also had a strange experience: in NixOs, the clinfo command was listing my CPU, while in an ubuntu docker instance, clinfo was listing my GPU.
Any idea idea why opencl is not listed anymore? For more details, I have a Intel(R) Core(TM) i5-8365U CPU, which is supposed to be packed with Intel® UHD Graphics for 8th Generation Intel® Processors.
Also, the issue I had with undiscovered GPU is because I need both intel-ocl (proprietary, for GPU Gen 7 and it also seems to make my CPU appear) and intel-compute-runtime (for GPU, Gen 8). For Gen 7, there is also the deprecated open source beignet. I realized all of this was actually documented in NixOS - NixOS 21.11 manual and the documentation I was reading in the wiki Intel Graphics - NixOS Wiki should be updated accordingly.
I guess my problems are nearly solved, thanks a lot! There is just a remaining question about how to choose the appropriate things between vaapi, vaapiIntel libvdpau-va-gl vaapiVdpau, libvdpau-va-gl…