- ret = am7xxx_send_image(dev, format, width, height, image, size);
+ /* When setting AM7XXX_ZOOM_TEST don't display the actual image */
+ if (zoom == AM7XXX_ZOOM_TEST) {
+ printf("AM7XXX_ZOOM_TEST requested, not sending actual image.\n");
+ goto cleanup;
+ }
+
+ if ((unsigned int)width > device_info.native_width ||
+ (unsigned int)height > device_info.native_height)
+ fprintf(stderr,
+ "WARNING: image is %dx%d, not fitting the native resolution, it may be displayed wrongly!\n",
+ width, height);
+
+ ret = am7xxx_send_image(dev, format, width, height, image, (unsigned int)size);