--- vlc-0.8.2.orig/modules/gui/wxwindows/wxwindows.h	2005-06-25 13:43:09.000000000 +0000
+++ vlc-0.8.2/modules/gui/wxwindows/wxwindows.h	2005-08-01 20:09:22.000000000 +0000
@@ -602,6 +602,7 @@
 enum
 {
     ANN_MISC_SOUT = 0,
+    TTL_MISC_SOUT,
     MISC_SOUT_NUM
 };
 
@@ -670,13 +671,14 @@
     wxSpinCtrl *net_ports[ACCESS_OUT_NUM];
     wxTextCtrl *net_addrs[ACCESS_OUT_NUM];
 
-    /* Controls for the SAP announces */
+    /* Controls for ttl and the SAP announces */
     wxPanel *misc_panel;
     wxPanel *misc_subpanels[MISC_SOUT_NUM];
     wxCheckBox *sap_checkbox;
     wxCheckBox *slp_checkbox;
     wxTextCtrl *announce_group;
     wxTextCtrl *announce_addr;
+    wxSpinCtrl *ttl_spin;
 
     /* Controls for the encapsulation */
     wxPanel *encapsulation_panel;
--- vlc-0.8.2.orig/modules/gui/wxwindows/streamout.cpp	2005-06-25 13:43:09.000000000 +0000
+++ vlc-0.8.2/modules/gui/wxwindows/streamout.cpp	2005-08-01 20:15:58.000000000 +0000
@@ -564,8 +564,10 @@
 
     /* Announce Row */
     misc_subpanels[ANN_MISC_SOUT] = new wxPanel( panel, -1 );
+    misc_subpanels[TTL_MISC_SOUT] = new wxPanel( panel, -1 );
     wxFlexGridSizer *subpanel_sizer = new wxFlexGridSizer( 3, 4, 20 );
     wxFlexGridSizer *subpanel_sub_sizer = new wxFlexGridSizer( 2, 4, 20 );
+    wxFlexGridSizer *ttl_sizer = new wxFlexGridSizer( 2, 2, 20 );
 
     sap_checkbox = new wxCheckBox( misc_subpanels[ANN_MISC_SOUT],SAPMisc_Event,
                                    wxU(_("SAP announce")) );
@@ -586,6 +588,11 @@
                                     wxT(""), wxDefaultPosition,
                                     wxSize( 200, -1 ), wxTE_PROCESS_ENTER);
 
+    wxStaticText *ttl_label = new wxStaticText( misc_subpanels[TTL_MISC_SOUT], -1,
+						wxU(_("Time-To-Live (TTL)")) );
+    ttl_spin = new wxSpinCtrl( misc_subpanels[TTL_MISC_SOUT], -1, wxEmptyString, wxDefaultPosition, wxDefaultSize,
+			       0, 1, 255, 1 );
+
     subpanel_sizer->Add( sap_checkbox, 0,
                          wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL );
     subpanel_sizer->Add( slp_checkbox, 0,
@@ -601,17 +608,25 @@
     subpanel_sizer->Add( subpanel_sub_sizer, 1, wxEXPAND |
                          wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL );
 
+    ttl_sizer->Add( ttl_label, 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL );
+    ttl_sizer->Add( ttl_spin, 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL );
+
     misc_subpanels[ANN_MISC_SOUT]->SetSizerAndFit( subpanel_sizer );
+    misc_subpanels[TTL_MISC_SOUT]->SetSizerAndFit( ttl_sizer );
 
     /* Stuff everything into the main panel */
     panel_sizer->Add( misc_subpanels[ANN_MISC_SOUT], 1,
                       wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL | wxLEFT, 5 );
 
+
     sout_all_checkbox = new wxCheckBox( panel, SoutAll_Event,
                             wxU(_("Select all elementary streams")) );
     panel_sizer->Add( sout_all_checkbox, 1,
                       wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL | wxLEFT, 5 );
 
+    panel_sizer->Add( misc_subpanels[TTL_MISC_SOUT], 1,
+                      wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL | wxALL, 5 );
+
     panel->SetSizerAndFit( panel_sizer );
 
     /* Update misc panel */
@@ -903,6 +918,7 @@
 void SoutDialog::OnOk( wxCommandEvent& WXUNUSED(event) )
 {
     mrl_combo->Append( mrl_combo->GetValue() );
+    config_PutInt( p_intf, "ttl", ttl_spin->GetValue());
     EndModal( wxID_OK );
 }
 
