[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Graphics' (#lcl)

# TCustomBitmap.RawimageNeeded

Ensures that the RawImage data is allocated prior to use.

## Declaration

Source position: graphics.pp line 1410

`protected procedure TCustomBitmap.RawimageNeeded(`
`ADescOnly: Boolean`
`);`

## Arguments

`ADescOnly` |  | True when only the image descriptor in the raw image data is needed.

## Description

Ensures that the RawImage property is allocated prior to accessing values in the raw image data.

ADescOnly indicates whether the image descriptor or the complete raw image data is required. When ADescOnly is True, only the TRawImageDescription in the raw image is needed. When set to False, all values in the TRawImage instance are required.

RawImageNeeded is called from methods access the raw image data, and occurs before the value in RawImage is accessed. For example:

- SetSize
- UpdatePixelFormat
- GetMonochrome
- UnshareImage
- GetRawImagePtr
- GetRawImageDescriptionPtr