OpenCV convertTo Failure

I do not have any idea why it did not work before but now it works with the following code :
VideoCapture cap(1); // open the default camera
if(!cap.isOpened()) // check if we succeeded
return -1;

Mat edges;
namedWindow("edges",1);
for(;;)
{
    Mat frame;
    cap >> frame; // get a new frame from camera
//    cvtColor(frame, edges, CV_BGR2GRAY);
//    GaussianBlur(edges, edges, Size(7,7), 1.5, 1.5);
 //   Canny(edges, edges, 0, 30, 3);
    imshow("edges", frame);
    if(waitKey(30) >= 0) break;
}
// the camera will be deinitialized automatically in VideoCapture destructor
return 0;

I used to change cap(index) from -1, 0, 1 ,2 ,… just to test and make sure if I am reading the right camera. Usually index values of either -1 or 0 were okay but this time index of ‘1’ worked !!!

Still Cheese program does not work but I do not need it anyway.
Now I have my camera frames and opencv4tegra with full GPU functionality.

Thanks for being so supportive and quick ^^
My problem is SOLVED :)

Hi all,

Correct OpenCV4Tegra is available in JetPack3.1 now.
Please check https://developer.nvidia.com/embedded/jetpack

Dear AastaLLL,

Thanks for keeping us updated , the problem is solved though.
I will keep it in mind for the upcoming installations.

Regardless of the corrected installation, may I ask how it is different from Jetpack 3.0 by the way ?

Hi,

Please find the release details here:
https://devtalk.nvidia.com/default/topic/1019640/jetson-tx2/jetpack-3-1-mdash-l4t-r28-1-released-for-jetson-tx1-tx2/