Commit 0239152b authored by Seungha Yang's avatar Seungha Yang Committed by Sebastian Dröge

nvdec: Create CUDA context with registered device id

Only the default device has been used by NVDEC so far.
This commit make it possible to use registered device id.
To simplify device id selection, GstNvDecCudaContext usage is removed.
parent 1df2f13d
Pipeline #50407 failed with stages
in 58 minutes and 34 seconds
This diff is collapsed.
......@@ -35,25 +35,6 @@
G_BEGIN_DECLS
typedef struct _GstNvDecCudaContext GstNvDecCudaContext;
typedef struct _GstNvDecCudaContextClass GstNvDecCudaContextClass;
struct _GstNvDecCudaContext
{
GObject parent;
CUcontext context;
CUvideoctxlock lock;
};
struct _GstNvDecCudaContextClass
{
GObjectClass parent_class;
};
GType gst_nvdec_cuda_context_get_type (void);
#define GST_TYPE_NVDEC (gst_nvdec_get_type())
#define GST_NVDEC(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), GST_TYPE_NVDEC, GstNvDec))
#define GST_NVDEC_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), GST_TYPE_NVDEC, GstNvDecClass))
......@@ -79,9 +60,10 @@ struct _GstNvDec
GstGLContext *gl_context;
GstGLContext *other_gl_context;
GstNvDecCudaContext *cuda_context;
CUvideoparser parser;
CUvideodecoder decoder;
CUcontext context;
CUvideoctxlock ctx_lock;
guint width;
guint height;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment