_Ecore_Audio_Vio Struct Reference

- Main Page
- Related Pages
- Modules
- Data Structures
- Files
- Examples

- Data Structures
- Data Structure Index
- Class Hierarchy
- Data Fields

Data Fields
_Ecore_Audio_Vio Struct Reference
Ecore » Ecore_Audio - Convenience audio API

## Data Fields
int(* | get_length )(void *data, Eo *eo_obj)
| Gets the length of the file.
int(* | seek )(void *data, Eo *eo_obj, int offset, int whence)
| Seeks to a position within the file.
int(* | tell )(void *data, Eo *eo_obj)
| Gets the current position within the file.
int(* | read )(void *data, Eo *eo_obj, void *buffer, int length)
| Reads some data from the file.
int(* | write )(void *data, Eo *eo_obj, const void *buffer, int length)
| Writes some data to the file.

## Field Documentation

## ◆ get_length

int(* _Ecore_Audio_Vio::get_length) (void *data, Eo *eo_obj)

Gets the length of the file.

Parameters

  data | User data from the ecore_audio_obj_set_vio call
  eo_obj | The Ecore_Audio object this operates on

Returns
  The length of the virtual file in bytes

Since
  1.8

## ◆ seek

int(* _Ecore_Audio_Vio::seek) (void *data, Eo *eo_obj, int offset, int whence)

Seeks to a position within the file.

Parameters

  data | User data from the ecore_audio_obj_set_vio call
  eo_obj | The Ecore_Audio object this operates on
  offset | The number of bytes to move (can be negative)
  whence | Accepts the same values as fseek(), which are: SEEK_SET: offset is absolute SEEK_CUR: offset is relative to the current position SEEK_END: offset is relative to the end

Returns
  The resulting position from the start of the file (in bytes) or -1 if an error occurred (i.e. out of bounds)

Since
  1.8

## ◆ tell

int(* _Ecore_Audio_Vio::tell) (void *data, Eo *eo_obj)

Gets the current position within the file.

Parameters

  data | User data from the ecore_audio_obj_set_vio call
  eo_obj | The Ecore_Audio object this operates on

Returns
  The resulting position from the start of the file (in bytes)

This is equivalent to calling seek() with offset 0 and whence SEEK_CUR.

Since
  1.8

## ◆ read

int(* _Ecore_Audio_Vio::read) (void *data, Eo *eo_obj, void *buffer, int length)

Reads some data from the file.

Parameters

  | data | User data from the ecore_audio_obj_set_vio call
  | eo_obj | The Ecore_Audio object this operates on
  [out] | buffer | the buffer to write the data to
  | length | The number of bytes to read

Returns
  The number of bytes read from the file. May be less than length

Since
  1.8

## ◆ write

int(* _Ecore_Audio_Vio::write) (void *data, Eo *eo_obj, const void *buffer, int length)

Writes some data to the file.

Parameters

  data | User data from the ecore_audio_obj_set_vio call
  eo_obj | The Ecore_Audio object this operates on
  buffer | Write data from here to the file
  length | The number of bytes to write

Returns
  The number of bytes written to the file. May be less than length

Since
  1.8