drawImage
Draws the image, loading it using the resource name.
Image is always drawn preserving the aspect ratio
Following additional drawing parameters are supported:
width- width of the area where the image should be placed (canvas width by default)height- height of the area where the image should be placed (canvas height by default)fill- controls image scaling; iftrue(default) image should completely fill the drawing area, sides may be cropped if needed, iffalseimage should be fully visible even if drawing area is not completely filled.
Parameters
name
name of the resource file that contains an image
config
image drawing parameters
Draw the image encoded in the given ByteString.
Parameters
bytes
byte array that encodes the image in PNG or JPEG format
config
image drawing parameters