mirror of
				https://github.com/vdr-projects/vdr.git
				synced 2025-03-01 10:50:46 +00:00 
			
		
		
		
	Implemented cDvbDevice::SetTransferModeForDolbyDigital()
This commit is contained in:
		
							
								
								
									
										3
									
								
								HISTORY
									
									
									
									
									
								
							
							
						
						
									
										3
									
								
								HISTORY
									
									
									
									
									
								
							| @@ -3410,3 +3410,6 @@ Video Disk Recorder Revision History | |||||||
|   library files from this version of VDR (suggested by Andreas Brachold). |   library files from this version of VDR (suggested by Andreas Brachold). | ||||||
| - Added a missing 'resultSkipped = 0' to cRemux::Clear() (thanks to Marco Schl<68><6C>ler | - Added a missing 'resultSkipped = 0' to cRemux::Clear() (thanks to Marco Schl<68><6C>ler | ||||||
|   for reporting this one). |   for reporting this one). | ||||||
|  | - The new function cDvbDevice::SetTransferModeForDolbyDigital() can be used by | ||||||
|  |   plugins that implement Dolby Digital output and thus want to prevent the cDvbDevice | ||||||
|  |   from starting Transfer Mode in order to replay DD over the DVB device. | ||||||
|   | |||||||
							
								
								
									
										10
									
								
								dvbdevice.c
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								dvbdevice.c
									
									
									
									
									
								
							| @@ -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: dvbdevice.c 1.119 2005/02/08 14:07:16 kls Exp $ |  * $Id: dvbdevice.c 1.120 2005/02/13 14:26:37 kls Exp $ | ||||||
|  */ |  */ | ||||||
|  |  | ||||||
| #include "dvbdevice.h" | #include "dvbdevice.h" | ||||||
| @@ -346,6 +346,7 @@ void cDvbTuner::Action(void) | |||||||
| // --- cDvbDevice ------------------------------------------------------------ | // --- cDvbDevice ------------------------------------------------------------ | ||||||
|  |  | ||||||
| int cDvbDevice::devVideoOffset = -1; | int cDvbDevice::devVideoOffset = -1; | ||||||
|  | bool cDvbDevice::setTransferModeForDolbyDigital = true; | ||||||
|  |  | ||||||
| cDvbDevice::cDvbDevice(int n) | cDvbDevice::cDvbDevice(int n) | ||||||
| { | { | ||||||
| @@ -861,6 +862,11 @@ void cDvbDevice::SetDigitalAudioDevice(bool On) | |||||||
|      } |      } | ||||||
| } | } | ||||||
|  |  | ||||||
|  | void cDvbDevice::SetTransferModeForDolbyDigital(bool On) | ||||||
|  | { | ||||||
|  |   setTransferModeForDolbyDigital = On; | ||||||
|  | } | ||||||
|  |  | ||||||
| void cDvbDevice::SetAudioTrackDevice(eTrackType Type) | void cDvbDevice::SetAudioTrackDevice(eTrackType Type) | ||||||
| { | { | ||||||
|   const tTrackId *TrackId = GetTrack(Type); |   const tTrackId *TrackId = GetTrack(Type); | ||||||
| @@ -872,6 +878,8 @@ void cDvbDevice::SetAudioTrackDevice(eTrackType Type) | |||||||
|            } |            } | ||||||
|         } |         } | ||||||
|      else if (IS_DOLBY_TRACK(Type)) { |      else if (IS_DOLBY_TRACK(Type)) { | ||||||
|  |         if (!setTransferModeForDolbyDigital) | ||||||
|  |            return; | ||||||
|         // Currently this works only in Transfer Mode |         // Currently this works only in Transfer Mode | ||||||
|         cChannel *Channel = Channels.GetByNumber(CurrentChannel()); |         cChannel *Channel = Channels.GetByNumber(CurrentChannel()); | ||||||
|         if (Channel) |         if (Channel) | ||||||
|   | |||||||
| @@ -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: dvbdevice.h 1.32 2005/01/06 13:30:51 kls Exp $ |  * $Id: dvbdevice.h 1.33 2005/02/13 14:14:31 kls Exp $ | ||||||
|  */ |  */ | ||||||
|  |  | ||||||
| #ifndef __DVBDEVICE_H | #ifndef __DVBDEVICE_H | ||||||
| @@ -99,11 +99,14 @@ protected: | |||||||
|  |  | ||||||
| private: | private: | ||||||
|   bool digitalAudio; |   bool digitalAudio; | ||||||
|  |   static bool setTransferModeForDolbyDigital; | ||||||
| protected: | protected: | ||||||
|   virtual int GetAudioChannelDevice(void); |   virtual int GetAudioChannelDevice(void); | ||||||
|   virtual void SetAudioChannelDevice(int AudioChannel); |   virtual void SetAudioChannelDevice(int AudioChannel); | ||||||
|   virtual void SetVolumeDevice(int Volume); |   virtual void SetVolumeDevice(int Volume); | ||||||
|   virtual void SetDigitalAudioDevice(bool On); |   virtual void SetDigitalAudioDevice(bool On); | ||||||
|  | public: | ||||||
|  |   static void SetTransferModeForDolbyDigital(bool On); | ||||||
|  |  | ||||||
| // Player facilities | // Player facilities | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user