1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

Non-primary devices in Transfer mode are now also used for recording

This commit is contained in:
Klaus Schmidinger 2007-04-30 09:40:34 +02:00
parent f935c03c79
commit fcbb206fdf
3 changed files with 5 additions and 2 deletions

View File

@ -2018,6 +2018,7 @@ Anssi Hannula <anssi.hannula@gmail.com>
receiving and doesn't require detatching receivers receiving and doesn't require detatching receivers
for improving handling Transfer Mode devices when selecting a device to receive for improving handling Transfer Mode devices when selecting a device to receive
for fixing handling frequencies in NitFilter::Process() for fixing handling frequencies in NitFilter::Process()
for making non-primary devices in Transfer mode be also used for recording
Antti Hartikainen <ami+vdr@ah.fi> Antti Hartikainen <ami+vdr@ah.fi>
for updating 'S13E' in 'sources.conf' for updating 'S13E' in 'sources.conf'

View File

@ -5180,3 +5180,5 @@ Video Disk Recorder Revision History
- Fixed handling frequencies in NitFilter::Process() (thanks to Anssi Hannula). - Fixed handling frequencies in NitFilter::Process() (thanks to Anssi Hannula).
- Fixed a race condition with signal handlers at program exit (thanks to Udo - Fixed a race condition with signal handlers at program exit (thanks to Udo
Richter). Richter).
- Non-primary devices in Transfer mode are now also used for recording (thanks
to Anssi Hannula).

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and * See the main source file 'vdr.c' for copyright information and
* how to reach the author. * how to reach the author.
* *
* $Id: device.c 1.139 2007/01/13 12:05:00 kls Exp $ * $Id: device.c 1.140 2007/04/30 09:34:00 kls Exp $
*/ */
#include "device.h" #include "device.h"
@ -327,7 +327,7 @@ cDevice *cDevice::GetDevice(const cChannel *Channel, int Priority, bool LiveView
// difference, because it results in the most significant bit of the result. // difference, because it results in the most significant bit of the result.
uint32_t imp = 0; uint32_t imp = 0;
imp <<= 1; imp |= LiveView ? !device[i]->IsPrimaryDevice() || ndr : 0; // prefer the primary device for live viewing if we don't need to detach existing receivers imp <<= 1; imp |= LiveView ? !device[i]->IsPrimaryDevice() || ndr : 0; // prefer the primary device for live viewing if we don't need to detach existing receivers
imp <<= 1; imp |= !device[i]->Receiving() || ndr; // use receiving devices if we don't need to detach existing receivers imp <<= 1; imp |= !device[i]->Receiving() && (device[i] != cTransferControl::ReceiverDevice() || device[i]->IsPrimaryDevice()) || ndr; // use receiving devices if we don't need to detach existing receivers, but avoid primary device in local transfer mode
imp <<= 1; imp |= device[i]->Receiving(); // avoid devices that are receiving imp <<= 1; imp |= device[i]->Receiving(); // avoid devices that are receiving
imp <<= 1; imp |= device[i] == cTransferControl::ReceiverDevice(); // avoid the Transfer Mode receiver device imp <<= 1; imp |= device[i] == cTransferControl::ReceiverDevice(); // avoid the Transfer Mode receiver device
imp <<= 8; imp |= min(max(device[i]->Priority() + MAXPRIORITY, 0), 0xFF); // use the device with the lowest priority (+MAXPRIORITY to assure that values -99..99 can be used) imp <<= 8; imp |= min(max(device[i]->Priority() + MAXPRIORITY, 0), 0xFF); // use the device with the lowest priority (+MAXPRIORITY to assure that values -99..99 can be used)