Add VLC Module

Source: Internet
Author: User
64 how to add a module
65 -------------------
66
67 to add a module to the repository, just add its sources to a modules. AM
68 file. If you add a new directory you will need to create a new modules. am,
69 inside that directory. Do not forget to add a corresponding
70 makefile line at the end of Configure. AC for this new modules. Am file.
71
72 to have the module built, you need to add a call to vlc_add_plugin or
73 vlc_add_builtins to configure. AC with your new module name as argument.
74 look at other modules for guidelines on how to add build and linkage options.
75
76 after changing Configure. AC you will always need to rerun Bootstrap and
77. Configure.
78
79 VLC keeps a cache of its modules (IN ~ /. Cache/VLC/on Linux), so you'll have
80 delete it (or use VLC -- reset-plugins-Cache). Then use VLC-vvv -- color -- list
81 to check that the your plugin is seen by VLC. describes the modules provided by VLC, as shown in. The following describes how to add a Module Directory and add a module, Source code See the final section. 1. Add the Module Directory. (1) Create a New mymodules subdirectory under the modules directory and add "module source" Code "Mymdule1.c (2) Add the modules. Am file sources_mymodule1 = mymodule1.clibvlc _ ltlibraries + = \
$ (Null) (3) modify the modules/makefile. Am file and add the mymodules subdirectory base_subdirs = \
....
Mymodules (4) modifies the configure. AC file under the root directory, adds modules, and supports compiling DNL
DNL mymodules
DNL
Vlc_add_plugin ([mymodule1]) (4) Run./Bootstrap./configure **. Sh (custom configure file) 2. Add "modules" For example, add the mymodule1 module under the Demux directory (1) and modify the modules under the Demux directory. add one line of sources_mymodule1 = mymodule1.c (2) Copy mymodule1.c to the Demux directory (3) Modify configure under the root directory. AC file, add module, support for compiling DNL
DNL mymodules
DNL
Vlc_add_plugin ([mymodule1]) (4) Run./Bootstrap./configure **. Sh (custom configure file)       Appendix: mymodule1.c source code:
 # Ifdef have_config_h
# Include " Config. h "
# Endif


# Include < Vlc_common.h >
# Include < Vlc_plugin.h >


/* **************************************** ************************************
* Local prototypes.
**************************************** ************************************ */

Static Int Open (vlc_object_t * );
Static Void Close (vlc_object_t * );

/* **************************************** ************************************
* Module Descriptor
**************************************** ************************************ */

Vlc_module_begin ()
Add_shortcut ( " Testmodule " )
Set_description ( " Testmodle plug-in " )
Set_callbacks (Open, close)
Set_capability ( " Testing " , 0 )
Set_category (cat_input)
Vlc_module_end ()


/* **************************************** ************************************
* Open: Initialize Interface
**************************************** ************************************ */

Static Int Open (vlc_object_t * P_this)
{
Msg_dbg (p_this, " Using test module... \ n " );
Return Vlc_success;
}

/* **************************************** ************************************
* Close: Destroy Interface
**************************************** ************************************ */

Static Void Close (vlc_object_t * P_this)
{
Msg_dbg (p_this, " Close test module! \ N " );
}


 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.