LiVES 2.4.6

- Main Page
- Namespaces
- Data Structures
- Files

- File List
- Globals

All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
Macros | Typedefs | Functions
videoplugin.h File Reference
`#include <inttypes.h>`
`#include "../../../../libweed/weed-palettes.h"`

Go to the source code of this file.

## Macros
#define | __WORDSIZE 32
#define | __PRI64_PREFIX "ll"
#define | PRId64 __PRI64_PREFIX "d"
#define | PRIu64 __PRI64_PREFIX "u"
#define | TRUE 1
#define | FALSE 0
#define | ABS(a) (a>0?a:-a)
#define | CPU_BITS ((sizeof(void *))<<3)
#define | VPP_CAN_RESIZE 1<<0
#define | VPP_CAN_RETURN 1<<1
#define | VPP_LOCAL_DISPLAY 1<<2
#define | MOD_CONTROL_MASK 1<<2
#define | MOD_ALT_MASK 1<<3
#define | MOD_NEEDS_TRANSLATION 1<<15

## Typedefs
typedef void *( | func_ptr )(void *)
typedef int | boolean
typedef boolean(* | keyfunc )(boolean down, uint16_t unicode, uint16_t keymod)
| This is a host function - a pointer to it is passed in send_keycodes() More...

## Functions
const char * | module_check_init (void)
| host calls at startup More...
const char * | version (void)
const char * | get_description (void)
| optional More...
const char * | get_init_rfx (void)
| optional More...
const void ** | get_play_params (func_ptr func)
const int * | get_palette_list (void)
| plugin send list of palettes, in order of preference More...
boolean | set_palette (int palette)
| host sets the palette used More...
uint64_t | get_capabilities (int palette)
| host will call this More...
boolean | init_screen (int width, int height, boolean fullscreen, uint64_t window_id, int argc, char **argv)
| ready the screen to play (optional) More...
boolean | render_frame (int hsize, int vsize, int64_t timecode, void **pixel_data, void **return_data, void **play_params)
void | exit_screen (int16_t mouse_x, int16_t mouse_y)
| destroy the screen, return mouse to original posn., allow the host GUI to take over (optional) More...
void | module_unload (void)
| this is called when module is unloaded More...
const char * | get_fps_list (int palette)
boolean | set_fps (double fps)
boolean | send_keycodes (keyfunc)
| host calls this fn to send keycodes, plugin should call key function with a unicode keycode and modifier. If no more keys, return FALSE. More...
const int * | get_yuv_palette_sampling (int palette)
| plugin send list of palette sampling types, in order of preference (optional); -1 terminates list More...
const int * | get_yuv_palette_clamping (int palette)
| plugin send list of palette clamping types, in order of preference (optional); -1 terminates list More...
const int * | get_yuv_palette_subspace (int palette)
| plugin send list of palette subspace types, in order of preference (optional); -1 terminates list More...
boolean | set_yuv_palette_sampling (int sampling_type)
| host sets the palette sampling (optional) More...
boolean | set_yuv_palette_clamping (int clamping_type)
| host sets the palette sampling (optional) More...
boolean | set_yuv_palette_subspace (int subspace_type)
| host sets the palette subspace (optional) More...
const int * | get_audio_fmts (void)

## Macro Definition Documentation

#define __PRI64_PREFIX "ll"

#define __WORDSIZE 32

#define ABS | ( |  | a | ) | (a>0?a:-a)

#define CPU_BITS ((sizeof(void *))<<3)

#define FALSE 0

#define MOD_ALT_MASK 1<<3

#define MOD_CONTROL_MASK 1<<2

#define MOD_NEEDS_TRANSLATION 1<<15

#define PRId64 __PRI64_PREFIX "d"

#define PRIu64 __PRI64_PREFIX "u"

#define TRUE 1

#define VPP_CAN_RESIZE 1<<0

#define VPP_CAN_RETURN 1<<1

#define VPP_LOCAL_DISPLAY 1<<2

## Typedef Documentation

typedef int boolean

typedef void*( func_ptr)(void *)

typedef boolean(* keyfunc)(boolean down, uint16_t unicode, uint16_t keymod)

This is a host function - a pointer to it is passed in send_keycodes()

## Function Documentation

void exit_screen | ( | int16_t | mouse_x,
|  | int16_t | mouse_y
| ) |  |

destroy the screen, return mouse to original posn., allow the host GUI to take over (optional)

const int* get_audio_fmts | ( | void |  | ) |

uint64_t get_capabilities | ( | int | palette | ) |

host will call this

const char* get_description | ( | void |  | ) |

optional

const char* get_fps_list | ( | int | palette | ) |

const char* get_init_rfx | ( | void |  | ) |

optional

optional (but should return a weed plantptr array of paramtmpl and chantmpl, NULL terminated)

const int* get_palette_list | ( | void |  | ) |

plugin send list of palettes, in order of preference

const void** get_play_params | ( | func_ptr | func | ) |

const int* get_yuv_palette_clamping | ( | int | palette | ) |

plugin send list of palette clamping types, in order of preference (optional); -1 terminates list

const int* get_yuv_palette_sampling | ( | int | palette | ) |

plugin send list of palette sampling types, in order of preference (optional); -1 terminates list

const int* get_yuv_palette_subspace | ( | int | palette | ) |

plugin send list of palette subspace types, in order of preference (optional); -1 terminates list

boolean init_screen | ( | int | width,
|  | int | height,
|  | boolean | fullscreen,
|  | uint64_t | window_id,
|  | int | argc,
|  | char ** | argv
| ) |  |

ready the screen to play (optional)

const char* module_check_init | ( | void |  | ) |

host calls at startup

void module_unload | ( | void |  | ) |

this is called when module is unloaded

boolean render_frame | ( | int | hsize,
|  | int | vsize,
|  | int64_t | timecode,
|  | void ** | pixel_data,
|  | void ** | return_data,
|  | void ** | play_params
| ) |  |

display one frame, adding effects if you like, and resizing it to screen size if possible (VPP_CAN_RESIZE)

if return_data is non-NULL, you should either fill it with the effected, unresized data (VPP_CAN_RETURN) or set it back to NULL if you can't

hsize and vsize are width and height of the pixel data (in macropixels) no extra padding (rowstrides) is allowed play_params should be cast to weed_plant_t ** (if the plugin exports get_play_paramtmpls() )

boolean send_keycodes | ( | keyfunc |  | ) |

host calls this fn to send keycodes, plugin should call key function with a unicode keycode and modifier. If no more keys, return FALSE.

boolean set_fps | ( | double | fps | ) |

boolean set_palette | ( | int | palette | ) |

host sets the palette used

boolean set_yuv_palette_clamping | ( | int | clamping_type | ) |

host sets the palette sampling (optional)

boolean set_yuv_palette_sampling | ( | int | sampling_type | ) |

host sets the palette sampling (optional)

boolean set_yuv_palette_subspace | ( | int | subspace_type | ) |

host sets the palette subspace (optional)

const char* version | ( | void |  | ) |