X-ray imaging in tokamaks: Characterization of a C-MOS imager (medipix-2)