fix image rendering R demo