ImageBasedHeightMap fails while loading JPEG generated by Windows Paint

While developing a game in jME3 RC2, I ran into a shortcoming of ImageBasedHeightMap after I created a JPEG in Windows Paint. When I load() the resulting heightmap, I got an UnsupportedOperationException at ImageBasedHeightMap.getHeightAtPostion() line 170, apparently because the BGR8 format is not supported.

I’ve worked around this by creating heightmaps using other tools, but I since Paint seems to be the default external editor for JPEGs in the Windows SDK, I wonder if it might be worth adding support for BGR8. Heck, with a little help I might be able to commit a fix myself.

ImageBasedHeightMap should use ImageRaster then it supports all formats :slight_smile:

That would be fine with me. How can we “make it so”?

I just installed 3.0 Stable. It appears that ImageRaster is used therein, and BGR8 files work as heightmaps therein, so I’ll consider the issue closed.

1 Like