libVLC-3

9.media player

LIBVLC_APIlibvlc_media_player_t*libvlc_media_player_new(libvlc_instance_t*p_libvlc_instance)

Create an empty Media Player object.

LIBVLC_APIlibvlc_media_player_t*libvlc_media_player_new_from_media(libvlc_media_t*p_md)

Create a Media Player object from a Media.

LIBVLC_APIvoidlibvlc_media_player_release(libvlc_media_player_t*p_mi)

Release a media_player after use Decrement the reference count of a media player object.

LIBVLC_APIvoidlibvlc_media_player_retain(libvlc_media_player_t*p_mi)

Retain a reference to a media player object.

LIBVLC_APIvoidlibvlc_media_player_set_media(libvlc_media_player_t*p_mi,libvlc_media_t*p_md)

Set the media that will be used by the media_player.

LIBVLC_APIlibvlc_media_t*libvlc_media_player_get_media(libvlc_media_player_t*p_mi)

Get the media used by the media_player.

LIBVLC_APIlibvlc_event_manager_t*libvlc_media_player_event_manager(libvlc_media_player_t*p_mi)

Get the Event Manager from which the media player send event.

LIBVLC_APIintlibvlc_media_player_is_playing(libvlc_media_player_t*p_mi)

is_playing

LIBVLC_APIintlibvlc_media_player_play(libvlc_media_player_t*p_mi)

Play.

LIBVLC_APIvoidlibvlc_media_player_set_pause(libvlc_media_player_t*mp, int do_pause)

Pause or resume (no effect if there is no media)

LIBVLC_APIvoidlibvlc_media_player_pause(libvlc_media_player_t*p_mi)

Toggle pause (no effect if there is no media)

LIBVLC_APIvoidlibvlc_media_player_stop(libvlc_media_player_t*p_mi)

Stop (no effect if there is no media)

LIBVLC_APIvoidlibvlc_video_set_callbacks(libvlc_media_player_t*mp,libvlc_video_lock_cblock,libvlc_video_unlock_cbunlock,libvlc_video_display_cbdisplay, void *opaque)

Set callbacks and private data to render decoded video to a custom area in memory.

LIBVLC_APIvoidlibvlc_video_set_format(libvlc_media_player_t*mp, const char *chroma, unsigned width, unsigned height, unsigned pitch)

Set decoded video chroma and dimensions.

LIBVLC_APIvoidlibvlc_video_set_format_callbacks(libvlc_media_player_t*mp,libvlc_video_format_cbsetup,libvlc_video_cleanup_cbcleanup)

Set decoded video chroma and dimensions.

LIBVLC_APIvoidlibvlc_media_player_set_nsobject(libvlc_media_player_t*p_mi, void *drawable)

Set the NSView handler where the media player should render its video output.

LIBVLC_APIvoid *libvlc_media_player_get_nsobject(libvlc_media_player_t*p_mi)

Get the NSView handler previously set withlibvlc_media_player_set_nsobject().

LIBVLC_APIvoidlibvlc_media_player_set_agl(libvlc_media_player_t*p_mi, uint32_t drawable)

Set the agl handler where the media player should render its video output.

LIBVLC_APIuint32_tlibvlc_media_player_get_agl(libvlc_media_player_t*p_mi)

Get the agl handler previously set withlibvlc_media_player_set_agl().

LIBVLC_APIvoidlibvlc_media_player_set_xwindow(libvlc_media_player_t*p_mi, uint32_t drawable)

Set an X Window System drawable where the media player should render its video output.

LIBVLC_APIuint32_tlibvlc_media_player_get_xwindow(libvlc_media_player_t*p_mi)

Get the X Window System window identifier previously set withlibvlc_media_player_set_xwindow().

LIBVLC_APIvoidlibvlc_media_player_set_hwnd(libvlc_media_player_t*p_mi, void *drawable)

Set a Win32/Win64 API window handle (HWND) where the media player should render its video output.

LIBVLC_APIvoid *libvlc_media_player_get_hwnd(libvlc_media_player_t*p_mi)

Get the Windows API window handle (HWND) previously set withlibvlc_media_player_set_hwnd().

LIBVLC_APIvoidlibvlc_media_player_set_android_context(libvlc_media_player_t*p_mi, void *p_jvm, void *p_awindow_handler)

Set the android context.

LIBVLC_APIvoidlibvlc_audio_set_callbacks(libvlc_media_player_t*mp,libvlc_audio_play_cbplay,libvlc_audio_pause_cbpause,libvlc_audio_resume_cbresume,libvlc_audio_flush_cbflush,libvlc_audio_drain_cbdrain, void *opaque)

Set callbacks and private data for decoded audio.

LIBVLC_APIvoidlibvlc_audio_set_volume_callback(libvlc_media_player_t*mp,libvlc_audio_set_volume_cbset_volume)

Set callbacks and private data for decoded audio.

LIBVLC_APIvoidlibvlc_audio_set_format_callbacks(libvlc_media_player_t*mp,libvlc_audio_setup_cbsetup,libvlc_audio_cleanup_cbcleanup)

Set decoded audio format.

LIBVLC_APIvoidlibvlc_audio_set_format(libvlc_media_player_t*mp, const char *format, unsigned rate, unsigned channels)

Set decoded audio format.

LIBVLC_APIlibvlc_time_tlibvlc_media_player_get_length(libvlc_media_player_t*p_mi)

Get the current movie length (in ms).

LIBVLC_APIlibvlc_time_tlibvlc_media_player_get_time(libvlc_media_player_t*p_mi)

Get the current movie time (in ms).

LIBVLC_APIvoidlibvlc_media_player_set_time(libvlc_media_player_t*p_mi,libvlc_time_ti_time)

Set the movie time (in ms).

LIBVLC_APIfloatlibvlc_media_player_get_position(libvlc_media_player_t*p_mi)

Get movie position as percentage between 0.0 and 1.0.

LIBVLC_APIvoidlibvlc_media_player_set_position(libvlc_media_player_t*p_mi, float f_pos)

Set movie position as percentage between 0.0 and 1.0.

LIBVLC_APIvoidlibvlc_media_player_set_chapter(libvlc_media_player_t*p_mi, int i_chapter)

Set movie chapter (if applicable).

LIBVLC_APIintlibvlc_media_player_get_chapter(libvlc_media_player_t*p_mi)

Get movie chapter.

LIBVLC_APIintlibvlc_media_player_get_chapter_count(libvlc_media_player_t*p_mi)

Get movie chapter count.

LIBVLC_APIintlibvlc_media_player_will_play(libvlc_media_player_t*p_mi)

Is the player able to play.

LIBVLC_APIintlibvlc_media_player_get_chapter_count_for_title(libvlc_media_player_t*p_mi, int i_title)

Get title chapter count.

LIBVLC_APIvoidlibvlc_media_player_set_title(libvlc_media_player_t*p_mi, int i_title)

Set movie title.

LIBVLC_APIintlibvlc_media_player_get_title(libvlc_media_player_t*p_mi)

Get movie title.

LIBVLC_APIintlibvlc_media_player_get_title_count(libvlc_media_player_t*p_mi)

Get movie title count.

LIBVLC_APIvoidlibvlc_media_player_previous_chapter(libvlc_media_player_t*p_mi)

Set previous chapter (if applicable)

LIBVLC_APIvoidlibvlc_media_player_next_chapter(libvlc_media_player_t*p_mi)

Set next chapter (if applicable)

LIBVLC_APIfloatlibvlc_media_player_get_rate(libvlc_media_player_t*p_mi)

Get the requested movie play rate.

LIBVLC_APIintlibvlc_media_player_set_rate(libvlc_media_player_t*p_mi, float rate)

Set movie play rate.

LIBVLC_APIlibvlc_state_tlibvlc_media_player_get_state(libvlc_media_player_t*p_mi)

Get current movie state.

LIBVLC_APIfloatlibvlc_media_player_get_fps(libvlc_media_player_t*p_mi)

Get movie fps rate.

LIBVLC_APIunsignedlibvlc_media_player_has_vout(libvlc_media_player_t*p_mi)

end bug

LIBVLC_APIintlibvlc_media_player_is_seekable(libvlc_media_player_t*p_mi)

Is this media player seekable?

LIBVLC_APIintlibvlc_media_player_can_pause(libvlc_media_player_t*p_mi)

Can this media player be paused?

LIBVLC_APIintlibvlc_media_player_program_scrambled(libvlc_media_player_t*p_mi)

Check if the current program is scrambled.

LIBVLC_APIvoidlibvlc_media_player_next_frame(libvlc_media_player_t*p_mi)

Display the next frame (if supported)

LIBVLC_APIvoidlibvlc_media_player_navigate(libvlc_media_player_t*p_mi, unsigned navigate)

Navigate through DVD Menu.

LIBVLC_APIvoidlibvlc_media_player_set_video_title_display(libvlc_media_player_t*p_mi,libvlc_position_tposition, unsigned int timeout)

Set if, and how, the video title will be shown when media is played.

LIBVLC_APIvoidlibvlc_track_description_list_release(libvlc_track_description_t*p_track_description)

Release (free)libvlc_track_description_t.

LIBVLC_DEPRECATEDLIBVLC_APIvoidlibvlc_track_description_release(libvlc_track_description_t*p_track_description)

10.vlm stream output

LIBVLC_APIvoidlibvlc_vlm_release(libvlc_instance_t*p_instance)

Release the vlm instance related to the given libvlc_instance_t.

LIBVLC_APIintlibvlc_vlm_add_broadcast(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_input, const char *psz_output, int i_options, const char *const *ppsz_options, int b_enabled, int b_loop)

Add a broadcast, with one input.

LIBVLC_APIintlibvlc_vlm_add_vod(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_input, int i_options, const char *const *ppsz_options, int b_enabled, const char *psz_mux)

Add a vod, with one input.

LIBVLC_APIintlibvlc_vlm_del_media(libvlc_instance_t*p_instance, const char *psz_name)

Delete a media (VOD or broadcast).

LIBVLC_APIintlibvlc_vlm_set_enabled(libvlc_instance_t*p_instance, const char *psz_name, int b_enabled)

Enable or disable a media (VOD or broadcast).

LIBVLC_APIintlibvlc_vlm_set_output(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_output)

Set the output for a media.

LIBVLC_APIintlibvlc_vlm_set_input(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_input)

Set a media's input MRL.

LIBVLC_APIintlibvlc_vlm_add_input(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_input)

Add a media's input MRL.

LIBVLC_APIintlibvlc_vlm_set_loop(libvlc_instance_t*p_instance, const char *psz_name, int b_loop)

Set a media's loop status.

LIBVLC_APIintlibvlc_vlm_set_mux(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_mux)

Set a media's vod muxer.

LIBVLC_APIintlibvlc_vlm_change_media(libvlc_instance_t*p_instance, const char *psz_name, const char *psz_input, const char *psz_output, int i_options, const char *const *ppsz_options, int b_enabled, int b_loop)

Edit the parameters of a media.

LIBVLC_APIintlibvlc_vlm_play_media(libvlc_instance_t*p_instance, const char *psz_name)

Play the named broadcast.

LIBVLC_APIintlibvlc_vlm_stop_media(libvlc_instance_t*p_instance, const char *psz_name)

Stop the named broadcast.

LIBVLC_APIintlibvlc_vlm_pause_media(libvlc_instance_t*p_instance, const char *psz_name)

Pause the named broadcast.

LIBVLC_APIintlibvlc_vlm_seek_media(libvlc_instance_t*p_instance, const char *psz_name, float f_percentage)

Seek in the named broadcast.

LIBVLC_APIconst char *libvlc_vlm_show_media(libvlc_instance_t*p_instance, const char *psz_name)

Return information about the named media as a JSON string representation.

LIBVLC_APIfloatlibvlc_vlm_get_media_instance_position(libvlc_instance_t*p_instance, const char *psz_name, int i_instance)

Get vlm_media instance position by name or instance id.

LIBVLC_APIintlibvlc_vlm_get_media_instance_time(libvlc_instance_t*p_instance, const char *psz_name, int i_instance)

Get vlm_media instance time by name or instance id.

LIBVLC_APIintlibvlc_vlm_get_media_instance_length(libvlc_instance_t*p_instance, const char *psz_name, int i_instance)

Get vlm_media instance length by name or instance id.

LIBVLC_APIintlibvlc_vlm_get_media_instance_rate(libvlc_instance_t*p_instance, const char *psz_name, int i_instance)

Get vlm_media instance playback rate by name or instance id.

LIBVLC_APIlibvlc_event_manager_t*libvlc_vlm_get_event_manager(libvlc_instance_t*p_instance)

Get libvlc_event_manager from a vlm media.

你可能感兴趣的:(libVLC-3)