Heat map in cesium

how do i create cesium heat map. want to make it smaller on zoom level

We have a Sandcastle example which color the terrain based on elevation, slope, and aspect: Cesium Sandcastle.

There was an extensive thread discussing this particular example, which may help you in your development: Show legend on cesium slope, aspect and elevation.

There are also other examples (2D heatmap for example) and discussions which you can find by searching for “heatmap” in the community forum search bar: Search results for 'heatmap' - Cesium Community.