4 * Copyright (C) 2007 ReactOS Team
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
27 typedef struct _VIDEO_PORT_FUNCTION_TABLE
{
30 } *PVIDEO_PORT_FUNCTION_TABLE
, VIDEO_PORT_FUNCTION_TABLE
;
32 /* GLOBAL VARIABLES ***********************************************************/
34 #define VP_EXPORTED_FUNCS 6
36 UCHAR FN_VideoPortClearEvent
[] = "VideoPortClearEvent";
37 UCHAR FN_VideoPortCreateEvent
[] = "VideoPortCreateEvent";
38 UCHAR FN_VideoPortCreateSecondaryDisplay
[] = "VideoPortCreateSecondaryDisplay";
39 UCHAR FN_VideoPortDeleteEvent
[] = "VideoPortDeleteEvent";
40 UCHAR FN_VideoPortQueueDpc
[] = "VideoPortQueueDpc";
41 UCHAR FN_VideoPortSetEvent
[] = "VideoPortSetEvent";
43 VIDEO_PORT_FUNCTION_TABLE VideoPortExports
[] = {
44 {VideoPortClearEvent
, FN_VideoPortClearEvent
},
45 {VideoPortCreateEvent
, FN_VideoPortCreateEvent
},
46 {VideoPortCreateSecondaryDisplay
, FN_VideoPortCreateSecondaryDisplay
},
47 {VideoPortDeleteEvent
, FN_VideoPortDeleteEvent
},
48 {VideoPortQueueDpc
, FN_VideoPortQueueDpc
},
49 {VideoPortSetEvent
, FN_VideoPortSetEvent
}
53 IntVideoPortGetProcAddress(
54 IN PVOID HwDeviceExtension
,
55 IN PUCHAR FunctionName
)
59 TRACE_(VIDEOPRT
, "VideoPortGetProcAddress(%s)\n", FunctionName
);
62 for (i
= 0; i
< VP_EXPORTED_FUNCS
; i
++)
64 if (!_strnicmp((PCHAR
)FunctionName
, (PCHAR
)VideoPortExports
[i
].Name
,
65 strlen((PCHAR
)FunctionName
)))
67 return (PVOID
)VideoPortExports
[i
].Address
;
71 WARN_(VIDEOPRT
, "VideoPortGetProcAddress: Can't resolve symbol %s\n", FunctionName
);