Relative co-ordinates optical flow

Is it possible to command Quadcopter using Pixhawk to go to relative co-ordinates using optical flow.