Add CPU/GPU gate and support new ANSALPR using OCR
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#include "ANSRTMP.h"
|
||||
#include "ANSMatRegistry.h"
|
||||
#include "ANSGpuFrameOps.h"
|
||||
#include "ANSCVVendorGate.h" // anscv_vendor_gate::IsNvidiaGpuAvailable()
|
||||
#include <memory>
|
||||
#include "media_codec.h"
|
||||
#include <cstdint>
|
||||
@@ -563,6 +564,12 @@ namespace ANSCENTER {
|
||||
#endif
|
||||
|
||||
int ANSRTMPClient::AutoConfigureHWDecoders(int maxPerGpuOverride) {
|
||||
// Skip the CUDA probe on non-NVIDIA hardware — the Platform fallback
|
||||
// handles Intel/AMD auto configuration. See ANSCVVendorGate.h.
|
||||
if (!anscv_vendor_gate::IsNvidiaGpuAvailable()) {
|
||||
return AutoConfigureHWDecoders_Platform_RTMP();
|
||||
}
|
||||
|
||||
int gpuCount = 0;
|
||||
cudaError_t err = cudaGetDeviceCount(&gpuCount);
|
||||
if (err != cudaSuccess || gpuCount <= 0) {
|
||||
|
||||
Reference in New Issue
Block a user