|
1 /* |
|
2 * Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Contains agent specific data types, commands |
|
15 * and attributes that are common DRM agents |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef DRMAGENTS_H |
|
21 #define DRMAGENTS_H |
|
22 |
|
23 #include <caf/caftypes.h> |
|
24 |
|
25 namespace DRM |
|
26 { |
|
27 |
|
28 /** |
|
29 * OMA DRM CAF Agent name |
|
30 */ |
|
31 _LIT(KDrmOmaAgentName, "OMA DRM Agent"); |
|
32 |
|
33 /** |
|
34 * WMDRM CAF Agent name |
|
35 */ |
|
36 _LIT(KDrmWMAgentName, "WM DRM Agent"); |
|
37 |
|
38 /** |
|
39 * Common attributes for DRM CAF Agents |
|
40 */ |
|
41 enum TDrmAgentAttribute |
|
42 { |
|
43 EDrmFileType = ContentAccess::EAgentSpecificAttributeBase + ContentAccess::EAgentSpecificAttributeBase + 1, |
|
44 EDrmAgentUid, |
|
45 EDrmAllowedOutputs |
|
46 }; |
|
47 |
|
48 /** |
|
49 * Common string attributes for DRM CAF Agents |
|
50 */ |
|
51 enum TDrmAgentStringAttribute |
|
52 { |
|
53 EDrmAgentName = ContentAccess::EAgentSpecificAttributeBase + ContentAccess::EAgentSpecificAttributeBase + 1, |
|
54 EDrmFileName, |
|
55 EDrmOriginalArtist, |
|
56 EDrmRatingInfo, |
|
57 EDrmTrackNumber, |
|
58 EDrmRecordingYear, |
|
59 EDrmFullName |
|
60 }; |
|
61 |
|
62 /** |
|
63 * DRM protection type of the file |
|
64 */ |
|
65 enum TDrmFileType |
|
66 { |
|
67 EDrmNone = 0, ///< No DRM |
|
68 EDrmOma1Dcf = 1, ///< OMA DRM v1 |
|
69 EDrmOma2Dcf = 2, ///< OMA DRM v2 |
|
70 EDrmWMFile = 3, ///< WMDRM |
|
71 EDrmOma1DcfBased = 4 ///< OMA DRM v1 DCF based format with extensions |
|
72 }; |
|
73 |
|
74 /** |
|
75 * DRM CAF Agent UIDs |
|
76 */ |
|
77 enum TDrmAgentUid |
|
78 { |
|
79 EDrmOmaAgent = 0x101F6DB4, ///< OMA DRM CAF Agent UID |
|
80 EDrmWmAgent = 0x10205CB6, ///< WMDRM CAF Agent UID |
|
81 }; |
|
82 |
|
83 /** |
|
84 * Allowed outputs for the content. The values below are used as bitmasks and |
|
85 * can be combined to allow multiple allowed outputs. Note that not all possible |
|
86 * outputs are listed here. The outputs will be added once their impact to the |
|
87 * adpatation layer and their compliance rule impact is understood. Only |
|
88 * outputs which have been analysed before are listed here. |
|
89 */ |
|
90 enum TDrmAllowedOutputs |
|
91 { |
|
92 /** |
|
93 * Allow all audio and video outputs |
|
94 */ |
|
95 EDrmAllowAll = 0xFFFFFFFF, |
|
96 |
|
97 /** |
|
98 * Allow none of the outputs |
|
99 */ |
|
100 EDrmAllowNone = 0x00000000, |
|
101 |
|
102 /** |
|
103 * Allow analog audio output via line out or the built-in speaker |
|
104 */ |
|
105 EDrmAllowAudioAnalog = 0x00000001, |
|
106 |
|
107 /** |
|
108 * Allow playback via an analog radio transmitter broadcasting device, |
|
109 * commonly called FM Transmitter |
|
110 */ |
|
111 EDrmAllowAudioFmTransmitter = 0x00000002, |
|
112 |
|
113 /** |
|
114 * Allow playback via a mono Bluetooth link using the Handset or |
|
115 * Handsfree Profiles (HSP, HFP), or using an A2DP profile, but in neither |
|
116 * case playing back with more than 48kHz sample rate, 16 bits sample width, |
|
117 * 2 channels and a playback speed of 1.5 times the original speed |
|
118 */ |
|
119 EDrmAllowAudioBluetooth = 0x00000004, |
|
120 |
|
121 /** |
|
122 * Allow mixing the audio stream upwards into other audio playback streams, |
|
123 * e.g. into a phone call |
|
124 */ |
|
125 EDrmAllowAudioUplink = 0x00000008, |
|
126 |
|
127 /** |
|
128 * Allow output of the video signal to an analog video output device, |
|
129 * e.g. S-Video |
|
130 */ |
|
131 EDrmAllowVideoAnalog = 0x00000010, |
|
132 |
|
133 /** |
|
134 * Allow video output over an anlog output channel which has MacroVision |
|
135 * video protection |
|
136 */ |
|
137 EDrmAllowVideoMacroVision = 0x00000020, |
|
138 |
|
139 /** |
|
140 * Allow audio output via USB |
|
141 */ |
|
142 EDrmAllowAudioUsb = 0x00000040, |
|
143 |
|
144 /** |
|
145 * Allow audio output to devices using HDCP, e.g. DVD players and HDTV. |
|
146 */ |
|
147 EDrmAllowAudioHdcp = 0x00000080, |
|
148 |
|
149 /** |
|
150 * Licensed product is required to engage HDCP to protect the audio. |
|
151 * If HDCP is not engaged or can't be engaged the audio must not be passed through to HDMI. |
|
152 */ |
|
153 EDrmAllowAudioHdmiHdcpRequired = 0x00000080, |
|
154 |
|
155 /** |
|
156 * Allow audio output to devices using HDMI, e.g. DVD players and HDTV. |
|
157 */ |
|
158 EDrmAllowAudioHdmi = 0x00000100, |
|
159 |
|
160 /** |
|
161 * Allow the passing the video data to devices using HDMI, eg DVD players and HDTV |
|
162 */ |
|
163 EDrmAllowVideoHDMI = 0x00000200, |
|
164 |
|
165 /** |
|
166 * Licensed product must attempt to engage HDCP to protect the video. |
|
167 * However it should be passed through to HDMI even if HDCP is not engaged or fails to engage. |
|
168 */ |
|
169 EDrmAllowVideoHdmiHdcpRequested = 0x00000400, |
|
170 |
|
171 |
|
172 /** |
|
173 * Licensed product is required to engage HDCP to protect the video. |
|
174 * If HDCP is not engaged or can not be engaged the video must not be passed through to HDMI. |
|
175 */ |
|
176 EDrmAllowVideoHdmiHdcpRequired = 0x00000800 |
|
177 |
|
178 }; |
|
179 } |
|
180 |
|
181 #endif // DRMAGENTS_H |