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