[DDK]
[reactos.git] / reactos / include / ddk / drmk.h
1 /*
2 ReactOS Kernel Streaming
3 Digital Rights Management
4
5 Author: Andrew Greenwood
6 */
7
8 #ifndef DRMK_H
9 #define DRMK_H
10
11 typedef struct {
12 DWORD Flags;
13 PDEVICE_OBJECT DeviceObject;
14 PFILE_OBJECT FileObject;
15 PVOID Context;
16 } DRMFORWARD, *PDRMFORWARD, *PCDRMFORWARD;
17
18 typedef struct {
19 BOOL CopyProtect;
20 ULONG Reserved;
21 BOOL DigitalOutputDisable;
22 } DRMRIGHTS, *PDRMRIGHTS;
23
24 typedef const DRMRIGHTS *PCDRMRIGHTS;
25
26 /* ===============================================================
27 Digital Rights Management Functions
28 TODO: Check calling convention
29 */
30
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34
35 NTSTATUS
36 NTAPI
37 DrmAddContentHandlers(
38 IN ULONG ContentId,
39 IN PVOID *paHandlers,
40 IN ULONG NumHandlers);
41
42 NTSTATUS
43 NTAPI
44 DrmCreateContentMixed(
45 IN PULONG paContentId,
46 IN ULONG cContentId,
47 OUT PULONG pMixedContentId);
48
49 NTSTATUS
50 NTAPI
51 DrmDestroyContent(
52 IN ULONG ContentId);
53
54 NTSTATUS
55 NTAPI
56 DrmForwardContentToDeviceObject(
57 IN ULONG ContentId,
58 IN PVOID Reserved,
59 IN PCDRMFORWARD DrmForward);
60
61 NTSTATUS
62 NTAPI
63 DrmForwardContentToFileObject(
64 IN ULONG ContentId,
65 IN PFILE_OBJECT FileObject);
66
67 NTSTATUS
68 NTAPI
69 DrmForwardContentToInterface(
70 IN ULONG ContentId,
71 IN PUNKNOWN pUnknown,
72 IN ULONG NumMethods);
73
74 NTSTATUS
75 NTAPI
76 DrmGetContentRights(
77 IN ULONG ContentId,
78 OUT PDRMRIGHTS DrmRights);
79
80 #ifdef __cplusplus
81 }
82 #endif
83
84 DEFINE_GUID(IID_IDrmAudioStream,
85 0x1915c967, 0x3299, 0x48cb, 0xa3, 0xe4, 0x69, 0xfd, 0x1d, 0x1b, 0x30, 0x6e);
86
87 #undef INTERFACE
88 #define INTERFACE IDrmAudioStream
89
90 DECLARE_INTERFACE_(IDrmAudioStream, IUnknown) {
91 STDMETHOD_(NTSTATUS, QueryInterface)(THIS_
92 REFIID InterfaceId,
93 PVOID* Interface
94 ) PURE;
95 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
96 STDMETHOD_(ULONG,Release)(THIS) PURE;
97 STDMETHOD_(NTSTATUS,SetContentId)(THIS_
98 IN ULONG ContentId,
99 IN PCDRMRIGHTS DrmRights
100 ) PURE;
101 };
102
103 typedef IDrmAudioStream *PDRMAUDIOSTREAM;
104
105 #define IMP_IDrmAudioStream \
106 STDMETHODIMP_(NTSTATUS) SetContentId( \
107 IN ULONG ContentId, \
108 IN PCDRMRIGHTS DrmRights);
109
110 #endif /* DRMK_H */