network.h 1.67 KB
Newer Older
Sam Hocevar's avatar
 
Sam Hocevar committed
1
/*****************************************************************************
Christophe Massiot's avatar
Christophe Massiot committed
2
 * network.h: interface to communicate with network plug-ins
Sam Hocevar's avatar
 
Sam Hocevar committed
3
 *****************************************************************************
Christophe Massiot's avatar
Christophe Massiot committed
4
 * Copyright (C) 2002 VideoLAN
5
 * $Id: network.h,v 1.3 2002/07/20 18:01:41 sam Exp $
Sam Hocevar's avatar
 
Sam Hocevar committed
6
 *
7
 * Authors: Christophe Massiot <massiot@via.ecp.fr>
Sam Hocevar's avatar
 
Sam Hocevar committed
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
 *
 * 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.
 *
 * 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
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
 *****************************************************************************/

Christophe Massiot's avatar
Christophe Massiot committed
24 25 26 27
/*****************************************************************************
 * network_socket_t: structure passed to a network plug-in to define the
 *                   kind of socket we want
 *****************************************************************************/
28
struct network_socket_t
Christophe Massiot's avatar
Christophe Massiot committed
29 30 31 32 33 34 35 36 37 38 39 40
{
    unsigned int i_type;

    char * psz_bind_addr;
    int i_bind_port;

    char * psz_server_addr;
    int i_server_port;

    /* Return values */
    int i_handle;
    size_t i_mtu;
41
};
Christophe Massiot's avatar
Christophe Massiot committed
42 43 44 45 46

/* Socket types */
#define NETWORK_UDP 1
#define NETWORK_TCP 2