Peculiarities of CCD and photodiode arrays application to X-ray image detection