/*****************************************************************************
* sout.cpp : Stream output dialog ( old-style )
****************************************************************************
- * Copyright ( C ) 2006 the VideoLAN team
+ * Copyright (C) 2006 the VideoLAN team
* Copyright (C) 2007 Société des arts technologiques
* Copyright (C) 2007 Savoir-faire Linux
*
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
#include "dialogs/sout.hpp"
#include <vlc_streaming.h>
-#include <iostream>
#include <QString>
#include <QFileDialog>
+SoutDialog* SoutDialog::instance = NULL;
+
SoutDialog::SoutDialog( QWidget *parent, intf_thread_t *_p_intf,
bool _transcode_only ) : QVLCDialog( parent, _p_intf )
{
if( b_transcode_only ) toggleSout();
}
-QString SoutDialog::getMrl()
-{
- return mrl;
-}
-
void SoutDialog::fileBrowse()
{
ui.tabWidget->setTabEnabled( 0,false );
void SoutDialog::setRawOptions( bool b_raw )
{
- if ( b_raw )
+ if( b_raw )
{
ui.tabWidget->setDisabled( true );
}
}
/* ADD HERE the profiles you want and need */
+ /* FIXME */
if( profileString == "IPod" ) setProfile( MP4, true, "mp4a", true, "mp4v" )
else if( profileString == "XBox" ) setProfile( ASF, true, "wma", true, "WMV2" )
{
sout_gui_descr_t sout;
memset( &sout, 0, sizeof( sout_gui_descr_t ) );
- int counter = 0;
+ unsigned int counter = 0;
sout.b_local = ui.localOutput->isChecked();
sout.b_file = ui.fileOutput->isChecked();
if ( sout.b_mms ) counter++ ;
if ( sout.b_rtp ) counter++ ;
if ( sout.b_udp ) counter ++;
- if ( sout.b_icecast ) counter ++;
+ if ( sout.b_icecast ) counter ++;
#define SMUX( x, txt ) if( ui.x->isChecked() ) sout.psz_mux = strdup( txt );
SMUX( PSMux, "ps" );
SMUX( WAVMux, "wav" );
SMUX( RAWMux, "raw" );
SMUX( FLVMux, "flv" );
+ SMUX( MKVMux, "mkv" );
bool trans = false;
bool more = false;
{
#define ISMORE() if ( more ) mrl.append( "," );
-
-#define ATLEASTONE() \
- if ( counter > 1 ) \
- { \
- mrl.append( "dst=" ); \
- }
+#define ATLEASTONE() if ( counter ) mrl.append( "dst=" );
#define CHECKMUX() \
if( sout.psz_mux ) \
mrl.append( sout.psz_mux ); \
}
-
if ( trans )
{
mrl.append( ":" );
mrl = ":sout=#";
}
- if ( counter > 1 )
+ if ( counter )
{
mrl.append( "duplicate{" );
}
more = true;
}
- if ( counter > 1 )
+ if( sout.b_icecast )
+ {
+ // TODO
+ }
+
+ if ( counter )
{
mrl.append( "}" );
}