This work demonstrates the use of a scientific-CMOS (sCMOS) energy-integrating detector as a photon-counting detector, thereby eliminating dark current and read-out noise issues, that simultaneously provides both energy resolution and sub-pixel spatial resolution for X-ray imaging. These capabilities are obtained by analyzing visible light photon clouds that result when X-ray photons produce fluorescence from a scintillator in front of the visible light sensor. Using low-fluence monochromatic X-ray projections to avoid overlapping photon clouds, the centroid of individual X-ray photon interactions was identified. This enabled a tripling of the spatial resolution of the detector to 6.71-0.04 μm. By calculating the total charge deposited by this interaction, an energy resolution of 61.2-0.1% at 17 keV was obtained. When combined with propagation-based phase contrast imaging and phase retrieval, a signal-to-noise ratio of up to 15-3 was achieved for an X-ray fluence of less than 3 photons/mm2.