Method

VipsSourcesniff

Declaration [src]

unsigned char*
vips_source_sniff (
  VipsSource* source,
  size_t length
)

Description [src]

Return a pointer to the first few bytes of the file. If the file is too short, return NULL.

Parameters

length

Type: size_t

Number of bytes to sniff.

Return value

Type: unsigned char*

A pointer to the bytes at the start of the file, or NULL on error.

The returned data is owned by the instance.