File:  [DVB] / multiplexer / command.h
Revision 1.7: download - view: text, annotated - select for diffs
Wed Aug 1 08:23:18 2001 UTC (22 years, 10 months ago) by oskar
Branches: MAIN
CVS tags: HEAD
Add command --sipid to allow manual entries into PMTs. See man page.
Prepare data structures to hold manually entered descriptors (internal).
Fix bug, which blocked action, when SI data filled buffers before regular
data buffers could be triggered.
Save PAT (PID 0x0000) from being touched by --si or --sipid.
Minor changes in configuration printout.
Solve PID collision problem between normal PIDs and --si PIDs.

/*
 * ISO 13818 stream multiplexer
 * Copyright (C) 2001 Convergence Integrated Media GmbH Berlin
 * Author: Oskar Schirmer (oskar@convergence.de)
 */


/* Tokens to denote main commands:
 */
enum {
  C_HELP = 1,
  C_VERS,
  C_QUIT,
  C_VERB,
  C_OPES,
  C_OPS,
  C_OTS,
  C_CLOS,
  C_APPE,
  C_FILE,
  C_CROP,
  C_REPT,
  C_FROP,
  C_BUSY,
  C_TIMD,
  C_FPSI,
  C_TSID,
  C_TSSI,
  C_TSSP,
  C_TRGI,
  C_TRGO,
  C_CONF,
  C_STAT,
  C_BSCR
};

typedef struct {
  byte token;      /* 0, if com* is not set */
  byte width;      /* size of field to print comlong in help, 0 to term list */
  short comshort;  /* -1, if no short version */
  char *comlong;   /* NULL for purely explanatory lines */
  char *explain;   /* exaplanatory string, may contain %s to insert explmulti*/
  char *explmulti; /* is inserted only when splice_multipleprograms is TRUE */
} command_list;    /* otherwise if explmulti is NULL, ignore the whole line */

/* Linked list to hold pairs of filerefnum and filenames, as
 * long as not used during an "open" or "append" operation:
 */
typedef struct filerefer_list {
  struct filerefer_list *next;
  int filerefnum;
  char *filename;
} filerefer_list;

boolean command_init (int cargc,
    char **cargv);
boolean command_expected (unsigned int *nfds,
    struct pollfd *ufds);
void command_process (boolean readable);


LinuxTV legacy CVS <linuxtv.org/cvs>