bug fixes, added rendering of images