You need to convert raster to xyz. If you are using ArcGIS Pro try https://support.esri.com/en-us/knowledge-base/how-to-convert-a-raster-dataset-to-an-xyz-table-with-ar-000023278. If you are use QGIS you can try gdal2xyz tool. eg. https://mapscaping.com/geotiff_xyz_csv_using_qgis/.