WordPress at a glance
function is not described

image_make_intermediate_size() WP 2.5.0

Resizes an image to make a thumbnail or intermediate size.

The returned array has the file size, the image width, and image height. The 'image_make_intermediate_size' filter can be used to hook in and change the values of the returned array. The only parameter is the resized file path.

No Hooks.

Return

false/Array. False, if no image was created. Metadata array on success.

Usage

image_make_intermediate_size( $file, $width, $height, $crop );
$file(string) (required)
File path.
$width(int) (required)
Image width.
$height(int) (required)
Image height.
$crop(true/false)
Whether to crop image to specified width and height or resize.
Default: false

Code of image make intermediate size: wp-includes/media.php WP 5.2.1

<?php
function image_make_intermediate_size( $file, $width, $height, $crop = false ) {
	if ( $width || $height ) {
		$editor = wp_get_image_editor( $file );

		if ( is_wp_error( $editor ) || is_wp_error( $editor->resize( $width, $height, $crop ) ) ) {
			return false;
		}

		$resized_file = $editor->save();

		if ( ! is_wp_error( $resized_file ) && $resized_file ) {
			unset( $resized_file['path'] );
			return $resized_file;
		}
	}
	return false;
}