rectify working from qt gui