{"action":"created","issue":{"url":"https://api.github.com/repos/shimat/opencvsharp/issues/145","labels_url":"https://api.github.com/repos/shimat/opencvsharp/issues/145/labels{/name}","comments_url":"https://api.github.com/repos/shimat/opencvsharp/issues/145/comments","events_url":"https://api.github.com/repos/shimat/opencvsharp/issues/145/events","html_url":"https://github.com/shimat/opencvsharp/issues/145","id":113122698,"number":145,"title":"A Rosetta Stone for OpenCvSharp 3.0","user":{"login":"Tharyn","id":12853316,"avatar_url":"https://avatars.githubusercontent.com/u/12853316?v=3","gravatar_id":"","url":"https://api.github.com/users/Tharyn","html_url":"https://github.com/Tharyn","followers_url":"https://api.github.com/users/Tharyn/followers","following_url":"https://api.github.com/users/Tharyn/following{/other_user}","gists_url":"https://api.github.com/users/Tharyn/gists{/gist_id}","starred_url":"https://api.github.com/users/Tharyn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tharyn/subscriptions","organizations_url":"https://api.github.com/users/Tharyn/orgs","repos_url":"https://api.github.com/users/Tharyn/repos","events_url":"https://api.github.com/users/Tharyn/events{/privacy}","received_events_url":"https://api.github.com/users/Tharyn/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/shimat/opencvsharp/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-10-24T00:38:51Z","updated_at":"2015-10-24T03:32:24Z","closed_at":null,"body":"This is small piece of code that returns a few errors. I'm making this sheet for myself an others moving into OpenCvSharp 3.0 as so much has changed.  Most of it works, however the two errors it is returning are new to me. Any help would be appreciated.\r\n\r\nThanks,\r\nTharyn\r\n\r\n```\r\n    // STANDARD\r\n        // (Works)\r\n        Mat image = new Mat(640, 480, MatType.CV_8U);\r\n\r\n        // (Works)                               \r\n        Window window = new Window(windowName);\r\n\r\n        // (Works) Reads image\r\n        Mat sourceAmat = Cv2.ImRead(AssetDatabase.GetAssetPath(sourceA), ImreadModes.Color);    \r\n\r\n        // (Works) Displays image in window \r\n        Cv2.ImShow(windowName, sourceAmat);\r\n\r\n        // (???) Create capture but light does not turn on webcam\r\n        VideoCapture capture = new VideoCapture();\r\n\r\n        capture.Read(sourceAmat);     \r\n        /*  ERROR:    \r\n            OpenCVException: !fixedSize(    )\r\n            OpenCvSharp.NativeMethods.<.cctor>b__0 (ErrorCode status, System.String funcName, System.String errMsg, System.String fileName, Int32 line, IntPtr userdata)\r\n                (wrapper native-to-managed) OpenCvSharp.NativeMethods:<.cctor>b__0 (OpenCvSharp.ErrorCode,intptr,intptr,intptr,int,intptr)\r\n            OpenCvSharp.VideoCapture.Read (OpenCvSharp.Mat image)\r\n            MatToTexture2D.Start () (at Assets/Scripts/MatToTexture2D.cs:39)\r\n        */   \r\n\r\n        Debug.Log(image);               // (Works returns)       Mat [ 640*480*CV_8UC1, IsContinuous=True, IsSubmatrix=False, Ptr=0x363150, Data=0x33056020 ]\r\n        Debug.Log(capture);             // (Works returns )      OpenCvSharp.VideoCapture\r\n        Debug.Log(capture.Gain);        // (Not working returns) 0\r\n        Debug.Log(capture.Brightness);  // (Not working returns) 0\r\n        Debug.Log(capture.Fps);         // (Not working returns) 0\r\n\r\n\r\n    // NATIVE\r\n        IntPtr camera = NativeMethods.videoio_VideoCapture_new1();\r\n        IntPtr mat = NativeMethods.core_Mat_new1();\r\n        Debug.Log(camera);                                          //  (Works returns) 704276736\r\n        Debug.Log(mat);                                             //  (Works returns) 702924480\r\n\r\n        \r\n        IntPtr matPtr = NativeMethods.videoio_VideoCapture_read(camera, mat);\r\n        //Error\t5\tCannot implicitly convert type 'int' to 'System.IntPtr'. An explicit conversion exists (are you missing a cast?)\t\r\n```\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/shimat/opencvsharp/issues/comments/150748290","html_url":"https://github.com/shimat/opencvsharp/issues/145#issuecomment-150748290","issue_url":"https://api.github.com/repos/shimat/opencvsharp/issues/145","id":150748290,"user":{"login":"shimat","id":4434824,"avatar_url":"https://avatars.githubusercontent.com/u/4434824?v=3","gravatar_id":"","url":"https://api.github.com/users/shimat","html_url":"https://github.com/shimat","followers_url":"https://api.github.com/users/shimat/followers","following_url":"https://api.github.com/users/shimat/following{/other_user}","gists_url":"https://api.github.com/users/shimat/gists{/gist_id}","starred_url":"https://api.github.com/users/shimat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shimat/subscriptions","organizations_url":"https://api.github.com/users/shimat/orgs","repos_url":"https://api.github.com/users/shimat/repos","events_url":"https://api.github.com/users/shimat/events{/privacy}","received_events_url":"https://api.github.com/users/shimat/received_events","type":"User","site_admin":false},"created_at":"2015-10-24T03:32:24Z","updated_at":"2015-10-24T03:32:24Z","body":"Please see: https://github.com/shimat/opencvsharp/issues/142"}}