@@ -13,17 +13,39 @@ namespace cv { namespace ximgproc {
1313 * @brief Computes the Radon transform of a given 2D image.
1414 *
1515 * The Radon transform is often used in image processing, particularly in applications
16- * like computed tomography, to analyze the structure of an image.
16+ * like computed tomography, to analyze the structure of an image by projecting it along
17+ * different angles. This function calculates the Radon Transform over a specified range
18+ * of angles.
19+ *
20+ * The output type will vary depending on the input type:
21+ * - If the input type is CV_8U, the output will be CV_32S.
22+ * - If the input type is CV_32F or CV_64F, the output will be CV_64F.
23+ *
24+ * The size of the output matrix depends on whether cropping is applied:
25+ * - Without cropping, the output size will be `num_of_integral x src_diagonal_length`.
26+ * - With cropping (circular), the output size will be `num_of_integral x min_edge`,
27+ * where `min_edge` is the smaller dimension of the cropped square.
28+ *
29+ * See https://engineering.purdue.edu/~malcolm/pct/CTI_Ch03.pdf for more details.
1730 *
1831 * @param src The input image on which the Radon transform is to be applied.
1932 * Must be a 2D single-channel array (e.g., grayscale image).
2033 * @param dst The output array that will hold the result of the Radon transform.
21- * @param theta The angle increment in degrees for the projection.
34+ * The type of the output will depend on the input image type.
35+ * @param theta The angle increment in degrees for the projection (resolution of the transform).
36+ * Default is 1 degree.
2237 * @param start_angle The starting angle for the Radon transform in degrees.
38+ * Default is 0 degrees.
2339 * @param end_angle The ending angle for the Radon transform in degrees.
24- * The difference between end_angle and start_angle must be positive when multiplied by theta.
25- * @param crop A flag indicating whether to crop the input image to a square or circular shape before transformation.
26- * @param norm A flag indicating whether to normalize the output image to the range [0, 255] after computation.
40+ * Default is 180 degrees. The difference between end_angle and start_angle must
41+ * be positive when multiplied by theta.
42+ * @param crop A flag indicating whether to crop the input image to a square or circular shape
43+ * before the transformation. If enabled, the image is first cropped to a square
44+ * (smallest dimension) and then transformed into a circle.
45+ * @param norm A flag indicating whether to normalize the output image to the range [0, 255] after
46+ * computation and convert the type to `CV_8U`. If normalization is not enabled,
47+ * the output will retain its original data range.
48+ *
2749 */
2850CV_EXPORTS_W void RadonTransform (InputArray src,
2951 OutputArray dst,
0 commit comments