Returns the grayscale intensity of a specific pixel in an image.
Computes grayscale value using the formula: Gray = (0.299 * R + 0.587 * G + 0.114 * B) / 255.0
planetcnc.image_get_pixel_gray(image, x, y)
#! /usr/bin/env python import planetcnc # Assuming 'img' is a valid image capsule object gray_value = planetcnc.image_get_pixel_gray(img, 10, 20) print(f"Grayscale intensity at (10,20): {gray_value}")