First time here? Check out the FAQ!
answered 2013-05-15 02:15:33 -0600
"What is that?"
that is in most cases an invalid or empty Mat/IplImage.
check, if the image you're trying to access with cvPtr2D has proper width/height/depth.