Commit b03450ee authored by François Cartegnie's avatar François Cartegnie 🤞

access: dtv: rename enum values

parent daef6b27
......@@ -638,38 +638,38 @@ static const delsys_t *GuessSystem (const char *scheme, dvb_device_t *dev)
/* Only wave carrier is specified */
if (!strcasecmp (scheme, "cable"))
{
if (systems & DVB_C)
if (systems & DTV_DELIVERY_DVB_C)
return &dvbc;
if (systems & CQAM)
if (systems & DTV_DELIVERY_CQAM)
return &cqam;
if (systems & ISDB_C)
if (systems & DTV_DELIVERY_ISDB_C)
return &isdbc;
}
if (!strcasecmp (scheme, "satellite"))
{
if (systems & DVB_S)
if (systems & DTV_DELIVERY_DVB_S)
return &dvbs;
if (systems & ISDB_S)
if (systems & DTV_DELIVERY_ISDB_S)
return &isdbs;
}
if (!strcasecmp (scheme, "terrestrial"))
{
if (systems & DVB_T)
if (systems & DTV_DELIVERY_DVB_T)
return &dvbc;
if (systems & ATSC)
if (systems & DTV_DELIVERY_ATSC)
return &cqam;
if (systems & ISDB_T)
if (systems & DTV_DELIVERY_ISDB_T)
return &isdbt;
}
/* Only standards family or nothing is specified */
if (systems & DVB_C)
if (systems & DTV_DELIVERY_DVB_C)
return &dvbc;
if (systems & DVB_S)
if (systems & DTV_DELIVERY_DVB_S)
return &dvbs;
if (systems & DVB_T)
if (systems & DTV_DELIVERY_DVB_T)
return &dvbt;
if (systems & ATSC)
if (systems & DTV_DELIVERY_ATSC)
return &atsc;
return NULL;
}
......
......@@ -415,15 +415,15 @@ unsigned BDAGraph::GetSystem( REFCLSID clsid )
unsigned sys = 0;
if( clsid == CLSID_DVBTNetworkProvider )
sys = DVB_T;
sys = DTV_DELIVERY_DVB_T;
if( clsid == CLSID_DVBCNetworkProvider )
sys = DVB_C;
sys = DTV_DELIVERY_DVB_C;
if( clsid == CLSID_DVBSNetworkProvider )
sys = DVB_S;
sys = DTV_DELIVERY_DVB_S;
if( clsid == CLSID_ATSCNetworkProvider )
sys = ATSC;
sys = DTV_DELIVERY_ATSC;
if( clsid == CLSID_DigitalCableNetworkType )
sys = CQAM;
sys = DTV_DELIVERY_CQAM;
return sys;
}
......@@ -1323,7 +1323,7 @@ int BDAGraph::SetInversion(int inversion)
* in access.c. Since DVBT and DVBC don't support spectral
* inversion, we need to return VLC_SUCCESS in those cases
* so that dvb_tune() will be called */
if( ( GetSystem( guid_network_type ) & ( DVB_S | DVB_S2 | ISDB_S ) ) == 0 )
if( ( GetSystem( guid_network_type ) & ( DTV_DELIVERY_DVB_S | DTV_DELIVERY_DVB_S2 | DTV_DELIVERY_ISDB_S ) ) == 0 )
{
msg_Dbg( p_access, "SetInversion: Not Satellite type" );
return VLC_SUCCESS;
......
......@@ -27,19 +27,19 @@ extern "C" {
# endif
enum {
ATSC = 0x00000001,
CQAM = 0x00000002,
DVB_C = 0x00000010,
DVB_C2 = 0x00000020,
DVB_S = 0x00000040,
DVB_S2 = 0x00000080,
DVB_T = 0x00000100,
DVB_T2 = 0x00000200,
ISDB_C = 0x00001000,
ISDB_S = 0x00002000,
ISDB_T = 0x00004000,
DTV_DELIVERY_ATSC = 0x00000001,
DTV_DELIVERY_CQAM = 0x00000002,
DTV_DELIVERY_DVB_C = 0x00000010,
DTV_DELIVERY_DVB_C2 = 0x00000020,
DTV_DELIVERY_DVB_S = 0x00000040,
DTV_DELIVERY_DVB_S2 = 0x00000080,
DTV_DELIVERY_DVB_T = 0x00000100,
DTV_DELIVERY_DVB_T2 = 0x00000200,
DTV_DELIVERY_ISDB_C = 0x00001000,
DTV_DELIVERY_ISDB_S = 0x00002000,
DTV_DELIVERY_ISDB_T = 0x00004000,
};
typedef struct dvb_device dvb_device_t;
......
......@@ -497,24 +497,24 @@ unsigned dvb_enum_systems (dvb_device_t *d)
static const unsigned systab[] = {
[SYS_UNDEFINED] = 0,
[SYS_DVBC_ANNEX_A] = DVB_C,
[SYS_DVBC_ANNEX_B] = CQAM,
[SYS_DVBT] = DVB_T,
[SYS_DVBC_ANNEX_A] = DTV_DELIVERY_DVB_C,
[SYS_DVBC_ANNEX_B] = DTV_DELIVERY_CQAM,
[SYS_DVBT] = DTV_DELIVERY_DVB_T,
//[SYS_DSS]
[SYS_DVBS] = DVB_S,
[SYS_DVBS2] = DVB_S2,
[SYS_DVBS] = DTV_DELIVERY_DVB_S,
[SYS_DVBS2] = DTV_DELIVERY_DVB_S2,
//[SYS_DVBH]
[SYS_ISDBT] = ISDB_T,
[SYS_ISDBS] = ISDB_S,
[SYS_ISDBC] = ISDB_C, // no drivers exist (as of 3.3-rc6)
[SYS_ATSC] = ATSC,
[SYS_ISDBT] = DTV_DELIVERY_ISDB_T,
[SYS_ISDBS] = DTV_DELIVERY_ISDB_S,
[SYS_ISDBC] = DTV_DELIVERY_ISDB_C, // no drivers exist (as of 3.3-rc6)
[SYS_ATSC] = DTV_DELIVERY_ATSC,
//[SYS_ATSCMH]
//[SYS_DMBTH]
//[SYS_CMMB]
//[SYS_DAB]
[SYS_DVBT2] = DVB_T2,
[SYS_DVBT2] = DTV_DELIVERY_DVB_T2,
//[SYS_TURBO]
[SYS_DVBC_ANNEX_C] = ISDB_C, // another name for ISDB-C?
[SYS_DVBC_ANNEX_C] = DTV_DELIVERY_ISDB_C, // another name for ISDB-C?
};
unsigned systems = 0;
......@@ -587,10 +587,10 @@ legacy:
/* DVB first generation and ATSC */
switch (info.type)
{
case FE_QPSK: systems = DVB_S; break;
case FE_QAM: systems = DVB_C; break;
case FE_OFDM: systems = DVB_T; break;
case FE_ATSC: systems = ATSC | CQAM; break;
case FE_QPSK: systems = DTV_DELIVERY_DVB_S; break;
case FE_QAM: systems = DTV_DELIVERY_DVB_C; break;
case FE_OFDM: systems = DTV_DELIVERY_DVB_T; break;
case FE_ATSC: systems = DTV_DELIVERY_ATSC | DTV_DELIVERY_CQAM; break;
default:
msg_Err (d->obj, "unknown frontend type %u", info.type);
}
......@@ -609,7 +609,7 @@ legacy:
/* ISDB (only terrestrial before DVBv5.5) */
if (info.type == FE_OFDM)
systems |= ISDB_T;
systems |= DTV_DELIVERY_ISDB_T;
return systems;
}
......@@ -711,7 +711,7 @@ int dvb_set_dvbc (dvb_device_t *d, uint32_t freq, const char *modstr,
unsigned mod = dvb_parse_modulation (modstr, QAM_AUTO);
fec = dvb_parse_fec (fec);
if (dvb_find_frontend (d, DVB_C))
if (dvb_find_frontend (d, DTV_DELIVERY_DVB_C))
return -1;
return dvb_set_props (d, 6, DTV_CLEAR, 0,
#if DVBv5(5)
......@@ -886,7 +886,7 @@ int dvb_set_dvbs (dvb_device_t *d, uint64_t freq_Hz,
uint32_t freq = freq_Hz / 1000;
fec = dvb_parse_fec (fec);
if (dvb_find_frontend (d, DVB_S))
if (dvb_find_frontend (d, DTV_DELIVERY_DVB_S))
return -1;
return dvb_set_props (d, 5, DTV_CLEAR, 0, DTV_DELIVERY_SYSTEM, SYS_DVBS,
DTV_FREQUENCY, freq, DTV_SYMBOL_RATE, srate,
......@@ -916,7 +916,7 @@ int dvb_set_dvbs2 (dvb_device_t *d, uint64_t freq_Hz, const char *modstr,
default: rolloff = PILOT_AUTO; break;
}
if (dvb_find_frontend (d, DVB_S2))
if (dvb_find_frontend (d, DTV_DELIVERY_DVB_S2))
return -1;
#if DVBv5(8)
return dvb_set_props (d, 9, DTV_CLEAR, 0, DTV_DELIVERY_SYSTEM, SYS_DVBS2,
......@@ -1012,7 +1012,7 @@ int dvb_set_dvbt (dvb_device_t *d, uint32_t freq, const char *modstr,
guard = dvb_parse_guard (guard);
hierarchy = dvb_parse_hierarchy (hierarchy);
if (dvb_find_frontend (d, DVB_T))
if (dvb_find_frontend (d, DTV_DELIVERY_DVB_T))
return -1;
return dvb_set_props (d, 10, DTV_CLEAR, 0, DTV_DELIVERY_SYSTEM, SYS_DVBT,
DTV_FREQUENCY, freq, DTV_MODULATION, mod,
......@@ -1064,7 +1064,7 @@ int dvb_set_isdbc (dvb_device_t *d, uint32_t freq, const char *modstr,
unsigned mod = dvb_parse_modulation (modstr, QAM_AUTO);
fec = dvb_parse_fec (fec);
if (dvb_find_frontend (d, ISDB_C))
if (dvb_find_frontend (d, DTV_DELIVERY_ISDB_C))
return -1;
return dvb_set_props (d, 6, DTV_CLEAR, 0,
#if DVBv5(5)
......@@ -1083,7 +1083,7 @@ int dvb_set_isdbs (dvb_device_t *d, uint64_t freq_Hz, uint16_t ts_id)
{
uint32_t freq = freq_Hz / 1000;
if (dvb_find_frontend (d, ISDB_S))
if (dvb_find_frontend (d, DTV_DELIVERY_ISDB_S))
return -1;
return dvb_set_props (d, 4, DTV_CLEAR, 0, DTV_DELIVERY_SYSTEM, SYS_ISDBS,
DTV_FREQUENCY, freq,
......@@ -1122,7 +1122,7 @@ int dvb_set_isdbt (dvb_device_t *d, uint32_t freq, uint32_t bandwidth,
transmit_mode = dvb_parse_transmit_mode (transmit_mode);
guard = dvb_parse_guard (guard);
if (dvb_find_frontend (d, ISDB_T))
if (dvb_find_frontend (d, DTV_DELIVERY_ISDB_T))
return -1;
if (dvb_set_props (d, 6, DTV_CLEAR, 0, DTV_DELIVERY_SYSTEM, SYS_ISDBT,
DTV_FREQUENCY, freq, DTV_BANDWIDTH_HZ, bandwidth,
......@@ -1141,7 +1141,7 @@ int dvb_set_atsc (dvb_device_t *d, uint32_t freq, const char *modstr)
{
unsigned mod = dvb_parse_modulation (modstr, VSB_8);
if (dvb_find_frontend (d, ATSC))
if (dvb_find_frontend (d, DTV_DELIVERY_ATSC))
return -1;
return dvb_set_props (d, 4, DTV_CLEAR, 0, DTV_DELIVERY_SYSTEM, SYS_ATSC,
DTV_FREQUENCY, freq, DTV_MODULATION, mod);
......@@ -1151,7 +1151,7 @@ int dvb_set_cqam (dvb_device_t *d, uint32_t freq, const char *modstr)
{
unsigned mod = dvb_parse_modulation (modstr, QAM_AUTO);
if (dvb_find_frontend (d, CQAM))
if (dvb_find_frontend (d, DTV_DELIVERY_CQAM))
return -1;
return dvb_set_props (d, 4, DTV_CLEAR, 0,
DTV_DELIVERY_SYSTEM, SYS_DVBC_ANNEX_B,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment