Copy link to clipboard
Copied
Hello there,
I am developing a plug-in using AE SDK. And would like to use the GPU so I took the sample SDK\_Invert\_ProcAmp as a starting point.
In this sample there are 3 GPU implementations: CUDA, OpenCL and Metal. One more thing to mention is that I have an Nvidia GPU in my PC. Now what I want to do is force the selection to be OpenCL but instead I get the CUDA selection forced.
More specifically, in the method GPUDeviceSetup in the main cpp file (SDK\_Invert\_ProcAmp.cpp), line 270:
if (extraP->input->what\_gpu == PF\_GPU\_Framework\_CUDA) {
...
This field extraP->input->what\_gpu always has the CUDA option and it comes as input, which is invoked directly from the main switch case. You might suggest simply to neglect this value, delete code related to CUDA and Metal and just go on. Unfortunately this will not work, because there is a whole AE GPU utility that depends on this selection and is needed to be used in many parts of the plug-in.
So how does one force the plug-in to use OpenCL, even if there is an Nvidia card available?
Any tips are highly appreciated.
Thanks!
Copy link to clipboard
Copied
Any thoughts on this?
Copy link to clipboard
Copied
No idea. Apparently the relevant "Changes to GPU functions" document never made it into the public SDK. I'm pretty sure all the switches and parameters are documented somewhere, just not anywhere easy to find.
Mylenium
Copy link to clipboard
Copied
Hi Rich
I don't believe it's possible to force AE to use any specific GPU API when going with their current ProcAmp sample pipeline. Ae chooses the API as well as the GPU (if there are multiple available). Furthermore if you write it for openCL (or any of the other GPU architectures) and the user has GPU acceleration disabled then you won't receive those calls at all, which many users may not know about.