dummy.c 4.27 KB
Newer Older
1 2 3
/*****************************************************************************
 * dummy.c : dummy plugin for vlc
 *****************************************************************************
4
 * Copyright (C) 2000, 2001 the VideoLAN team
Laurent Aimar's avatar
Laurent Aimar committed
5
 * $Id$
6 7 8 9 10 11 12
 *
 * Authors: Samuel Hocevar <sam@zoy.org>
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
Sam Hocevar's avatar
Sam Hocevar committed
13
 *
14 15 16 17 18 19 20
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
dionoea's avatar
dionoea committed
21
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
 *****************************************************************************/

/*****************************************************************************
 * Preamble
 *****************************************************************************/
#include <stdlib.h>                                      /* malloc(), free() */
#include <string.h>

#include <vlc/vlc.h>

#include "dummy.h"

/*****************************************************************************
 * Module descriptor
 *****************************************************************************/
Christophe Massiot's avatar
Christophe Massiot committed
37
#define CHROMA_TEXT N_("Dummy image chroma format")
38 39 40 41 42
#define CHROMA_LONGTEXT N_( \
    "Force the dummy video output to create images using a specific chroma " \
    "format instead of trying to improve performances by using the most " \
    "efficient one.")

gbazin's avatar
 
gbazin committed
43 44
#define SAVE_TEXT N_("Save raw codec data")
#define SAVE_LONGTEXT N_( \
45 46
    "Save the raw codec data if you have selected/forced the dummy " \
    "decoder in the main options." )
gbazin's avatar
 
gbazin committed
47

gbazin's avatar
 
gbazin committed
48
#ifdef WIN32
Sam Hocevar's avatar
Sam Hocevar committed
49
#define QUIET_TEXT N_("Do not open a DOS command box interface")
gbazin's avatar
 
gbazin committed
50
#define QUIET_LONGTEXT N_( \
Sam Hocevar's avatar
Sam Hocevar committed
51
    "By default the dummy interface plugin will start a DOS command box. " \
gbazin's avatar
 
gbazin committed
52
    "Enabling the quiet mode will not bring this command box but can also " \
Sam Hocevar's avatar
Sam Hocevar committed
53 54
    "be pretty annoying when you want to stop VLC and no video window is " \
    "open." )
gbazin's avatar
 
gbazin committed
55 56
#endif

57
vlc_module_begin();
zorglub's avatar
zorglub committed
58
    set_shortname( _("Dummy"));
59
    set_description( _("Dummy interface function") );
gbazin's avatar
 
gbazin committed
60
    set_capability( "interface", 0 );
61
    add_shortcut( "vlc" );
gbazin's avatar
 
gbazin committed
62
    set_callbacks( E_(OpenIntf), NULL );
gbazin's avatar
 
gbazin committed
63
#ifdef WIN32
zorglub's avatar
zorglub committed
64
    set_section( N_( "Dummy Interface" ), NULL );
gbazin's avatar
 
gbazin committed
65 66
    add_category_hint( N_("Interface"), NULL, VLC_FALSE );
    add_bool( "dummy-quiet", 0, NULL, QUIET_TEXT, QUIET_LONGTEXT, VLC_FALSE );
gbazin's avatar
 
gbazin committed
67
#endif
68
    add_submodule();
69
        set_description( _("Dummy access function") );
Laurent Aimar's avatar
Laurent Aimar committed
70
        set_capability( "access2", 0 );
71 72
        set_callbacks( E_(OpenAccess), NULL );
    add_submodule();
73
        set_description( _("Dummy demux function") );
Laurent Aimar's avatar
Laurent Aimar committed
74
        set_capability( "demux2", 0 );
75 76
        set_callbacks( E_(OpenDemux), E_(CloseDemux) );
    add_submodule();
zorglub's avatar
zorglub committed
77
        set_section( N_( "Dummy decoder" ), NULL );
78
        set_description( _("Dummy decoder function") );
79
        set_capability( "decoder", 0 );
gbazin's avatar
 
gbazin committed
80
        set_callbacks( E_(OpenDecoder), E_(CloseDecoder) );
81
        add_bool( "dummy-save-es", 0, NULL, SAVE_TEXT, SAVE_LONGTEXT, VLC_TRUE );
gbazin's avatar
 
gbazin committed
82
    add_submodule();
83
        set_description( _("Dummy encoder function") );
gbazin's avatar
 
gbazin committed
84 85
        set_capability( "encoder", 0 );
        set_callbacks( E_(OpenEncoder), E_(CloseEncoder) );
86
    add_submodule();
87
        set_description( _("Dummy audio output function") );
88
        set_capability( "audio output", 1 );
89 90
        set_callbacks( E_(OpenAudio), NULL );
    add_submodule();
91
        set_description( _("Dummy video output function") );
zorglub's avatar
zorglub committed
92
        set_section( N_( "Dummy Video output" ), NULL );
93
        set_capability( "video output", 1 );
94
        set_callbacks( E_(OpenVideo), NULL );
95
        add_category_hint( N_("Video"), NULL, VLC_FALSE );
96
        add_string( "dummy-chroma", NULL, NULL, CHROMA_TEXT, CHROMA_LONGTEXT, VLC_TRUE );
97
    add_submodule();
98
        set_description( _("Dummy font renderer function") );
99 100
        set_capability( "text renderer", 1 );
        set_callbacks( E_(OpenRenderer), NULL );
101 102
vlc_module_end();