1 Answer
1

You have to inspect your graphics carefully. What you do here is you compare apples and oranges. While your DensityHistogram contains about 100 colors (89 in this special case)

the ListContourPlot contains only 10 colors.

This is what you could have observed directly. Under the hood happens more which leads to the slowness of the DensityHistogram. The ListContourPlot uses the relatively new GraphicsComplex directive which works like that:

When you want to draw a polygon or rectangle or whatever, you don't use the coordinates directly because adjacent polygons share points and you would repeat the same coordinates over and over again. Instead, you start with a list of all coordinates and then you refer only to the index of those coordinates.

Additionally, while DensityHistogram creates many many Rectangle directives, ListContourPlot creates only some Polygon-directives and includes many polygons in one call:

To test this, just look at the InputForm of your DensityHistogram. You could write some lines of code to extract all coordinates, build a GraphicsComplex and convert the many Rectangles into Polygon calls:

Mathematica is a registered trademark of Wolfram Research, Inc. While the mark is used herein with the limited permission of Wolfram Research, Stack Exchange and this site disclaim all affiliation therewith.