Skip to content

Problem with this line #16

@maxrodro

Description

@maxrodro

Hello everybody,

I am using OpenCvSharp in my Xamarin Forms to capture the video and process the resulting Frame, but this line remains and does not continue with the following lines of code, any ideas?

File: AndroidCapture.cs

`
capturedBuffer = mat;

        var k = 0;  // -->   it works yes I uncomment and comment the following line
        var k = Cv2.WaitKey(0); // ---> Stop Code

        var args = new FrameArgs(mat, (char)k);

        if (MultiThread)
        {
            lock (capturedBufferLocker)
            {
                if (lastFrame > frameIndex)
                {
                    if (mat != null)
                        mat.Dispose();
                    mat = null;
                    CvProfiler.Count("CaptureSkipped");
                    return;
                }

                lastFrame = frameIndex;
                FrameReady?.Invoke(this, args);
            }
        }
        else
        {
            FrameReady?.Invoke(this, args);
        }

        if (args.MatDispose)
        {
            mat.Release();
            mat.Dispose();
            mat = null;
        }

`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions