|
1 /* |
|
2 * Copyright (c) 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef TOBJECTDESCRIPTION_H |
|
20 #define TOBJECTDESCRIPTION_H |
|
21 |
|
22 #include <mtp/mtpprotocolconstants.h> |
|
23 |
|
24 // vendor extended property code |
|
25 const TUint16 EMTPExtObjectPropCodeOmaDrmStatus = 0xDB01; |
|
26 |
|
27 struct TObjectDescription |
|
28 { |
|
29 TUint16 iPropCode; |
|
30 TUint32 iGroupCode; |
|
31 }; |
|
32 |
|
33 enum TGroupCodeType |
|
34 { |
|
35 EGroupCodeGeneral = 0x00000001, |
|
36 EGroupCodeMediaDB = 0x00FF0000, |
|
37 EGroupCodeNotDefined = 0xFFFFFFFF // TODO: need to reconsider |
|
38 }; |
|
39 |
|
40 static const TGroupCodeType KSupportedGroupCode[] = |
|
41 { |
|
42 EGroupCodeGeneral, |
|
43 EGroupCodeMediaDB |
|
44 }; |
|
45 |
|
46 static const TObjectDescription KPropGroupMapTable[] = |
|
47 { |
|
48 // First group, mandatory for all |
|
49 { EMTPObjectPropCodeStorageID, EGroupCodeGeneral }, |
|
50 { EMTPObjectPropCodeObjectFormat, EGroupCodeGeneral }, |
|
51 { EMTPObjectPropCodeProtectionStatus, EGroupCodeGeneral }, |
|
52 { EMTPObjectPropCodeObjectSize, EGroupCodeGeneral }, |
|
53 { EMTPObjectPropCodeObjectFileName, EGroupCodeGeneral }, |
|
54 { EMTPObjectPropCodeParentObject, EGroupCodeGeneral }, |
|
55 { EMTPObjectPropCodePersistentUniqueObjectIdentifier, |
|
56 EGroupCodeGeneral }, |
|
57 { EMTPObjectPropCodeNonConsumable, EGroupCodeGeneral }, |
|
58 |
|
59 // First group, addtional for all |
|
60 { EMTPObjectPropCodeDateCreated, EGroupCodeGeneral }, |
|
61 { EMTPObjectPropCodeDateModified, EGroupCodeGeneral }, |
|
62 |
|
63 // Second group, additional for all |
|
64 { EMTPObjectPropCodeName, EGroupCodeMediaDB }, |
|
65 { EMTPObjectPropCodeDateAdded, EGroupCodeMediaDB }, |
|
66 |
|
67 // Second group, mandatory for audio |
|
68 { EMTPObjectPropCodeArtist, EGroupCodeMediaDB }, |
|
69 { EMTPObjectPropCodeTrack, EGroupCodeMediaDB }, |
|
70 { EMTPObjectPropCodeGenre, EGroupCodeMediaDB }, |
|
71 { EMTPObjectPropCodeAlbumName, EGroupCodeMediaDB }, |
|
72 { EMTPObjectPropCodeSampleRate, EGroupCodeMediaDB }, |
|
73 { EMTPObjectPropCodeNumberOfChannels, EGroupCodeMediaDB }, |
|
74 { EMTPObjectPropCodeAudioWAVECodec, EGroupCodeMediaDB }, |
|
75 { EMTPObjectPropCodeAudioBitRate, EGroupCodeMediaDB }, |
|
76 { EMTPObjectPropCodeDuration, EGroupCodeMediaDB }, |
|
77 { EMTPObjectPropCodeOriginalReleaseDate, EGroupCodeMediaDB }, |
|
78 { EMTPObjectPropCodeDescription, EGroupCodeMediaDB }, |
|
79 { EMTPObjectPropCodeComposer, EGroupCodeMediaDB }, |
|
80 |
|
81 // Second group, mandatory for video |
|
82 { EMTPObjectPropCodeWidth, EGroupCodeMediaDB }, |
|
83 { EMTPObjectPropCodeHeight, EGroupCodeMediaDB }, |
|
84 { EMTPObjectPropCodeUseCount, EGroupCodeMediaDB }, |
|
85 { EMTPObjectPropCodeScanType, EGroupCodeMediaDB }, |
|
86 { EMTPObjectPropCodeVideoFourCCCodec, EGroupCodeMediaDB }, |
|
87 { EMTPObjectPropCodeVideoBitRate, EGroupCodeMediaDB }, |
|
88 { EMTPObjectPropCodeFramesPerThousandSeconds, EGroupCodeMediaDB }, |
|
89 { EMTPObjectPropCodeKeyFrameDistance, EGroupCodeMediaDB }, |
|
90 { EMTPObjectPropCodeEncodingProfile, EGroupCodeMediaDB }, |
|
91 |
|
92 // Second group, additional for video |
|
93 { EMTPObjectPropCodeParentalRating, EGroupCodeMediaDB }, |
|
94 { EMTPObjectPropCodeDRMStatus, EGroupCodeMediaDB }, |
|
95 { EMTPExtObjectPropCodeOmaDrmStatus, EGroupCodeMediaDB } |
|
96 }; |
|
97 |
|
98 #endif // TOBJECTDESCRIPTION_H |