Normalize all the line endings
This commit is contained in:
parent
b99790cb7c
commit
ed463ba658
141 changed files with 45010 additions and 45010 deletions
|
|
@ -1,123 +1,123 @@
|
|||
/*
|
||||
* $Id: pa_log.c $
|
||||
* Portable Audio I/O Library Multi-Host API front end
|
||||
* Validate function parameters and manage multiple host APIs.
|
||||
*
|
||||
* Based on the Open Source API proposed by Ross Bencina
|
||||
* Copyright (c) 1999-2006 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup common_src
|
||||
|
||||
@brief Implements log function.
|
||||
|
||||
PaUtil_SetLogPrintFunction can be user called to replace the provided
|
||||
DefaultLogPrint function, which writes to stderr.
|
||||
One can NOT pass var_args across compiler/dll boundaries as it is not
|
||||
"byte code/abi portable". So the technique used here is to allocate a local
|
||||
a static array, write in it, then callback the user with a pointer to its
|
||||
start.
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
#include "pa_debugprint.h"
|
||||
|
||||
// for OutputDebugStringA
|
||||
#if defined(_MSC_VER) && defined(PA_ENABLE_MSVC_DEBUG_OUTPUT)
|
||||
#define WIN32_LEAN_AND_MEAN // exclude rare headers
|
||||
#include "windows.h"
|
||||
#endif
|
||||
|
||||
// User callback
|
||||
static PaUtilLogCallback userCB = NULL;
|
||||
|
||||
// Sets user callback
|
||||
void PaUtil_SetDebugPrintFunction(PaUtilLogCallback cb)
|
||||
{
|
||||
userCB = cb;
|
||||
}
|
||||
|
||||
/*
|
||||
If your platform doesn’t have vsnprintf, you are stuck with a
|
||||
VERY dangerous alternative, vsprintf (with no n)
|
||||
*/
|
||||
#if _MSC_VER
|
||||
/* Some Windows Mobile SDKs don't define vsnprintf but all define _vsnprintf (hopefully).
|
||||
According to MSDN "vsnprintf is identical to _vsnprintf". So we use _vsnprintf with MSC.
|
||||
*/
|
||||
#define VSNPRINTF _vsnprintf
|
||||
#else
|
||||
#define VSNPRINTF vsnprintf
|
||||
#endif
|
||||
|
||||
#define PA_LOG_BUF_SIZE 2048
|
||||
|
||||
void PaUtil_DebugPrint( const char *format, ... )
|
||||
{
|
||||
// Optional logging into Output console of Visual Studio
|
||||
#if defined(_MSC_VER) && defined(PA_ENABLE_MSVC_DEBUG_OUTPUT)
|
||||
{
|
||||
char buf[PA_LOG_BUF_SIZE];
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
VSNPRINTF(buf, sizeof(buf), format, ap);
|
||||
buf[sizeof(buf)-1] = 0;
|
||||
OutputDebugStringA(buf);
|
||||
va_end(ap);
|
||||
}
|
||||
#endif
|
||||
|
||||
// Output to User-Callback
|
||||
if (userCB != NULL)
|
||||
{
|
||||
char strdump[PA_LOG_BUF_SIZE];
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
VSNPRINTF(strdump, sizeof(strdump), format, ap);
|
||||
strdump[sizeof(strdump)-1] = 0;
|
||||
userCB(strdump);
|
||||
va_end(ap);
|
||||
}
|
||||
else
|
||||
// Standard output to stderr
|
||||
{
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
vfprintf(stderr, format, ap);
|
||||
va_end(ap);
|
||||
fflush(stderr);
|
||||
}
|
||||
}
|
||||
/*
|
||||
* $Id: pa_log.c $
|
||||
* Portable Audio I/O Library Multi-Host API front end
|
||||
* Validate function parameters and manage multiple host APIs.
|
||||
*
|
||||
* Based on the Open Source API proposed by Ross Bencina
|
||||
* Copyright (c) 1999-2006 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup common_src
|
||||
|
||||
@brief Implements log function.
|
||||
|
||||
PaUtil_SetLogPrintFunction can be user called to replace the provided
|
||||
DefaultLogPrint function, which writes to stderr.
|
||||
One can NOT pass var_args across compiler/dll boundaries as it is not
|
||||
"byte code/abi portable". So the technique used here is to allocate a local
|
||||
a static array, write in it, then callback the user with a pointer to its
|
||||
start.
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
#include "pa_debugprint.h"
|
||||
|
||||
// for OutputDebugStringA
|
||||
#if defined(_MSC_VER) && defined(PA_ENABLE_MSVC_DEBUG_OUTPUT)
|
||||
#define WIN32_LEAN_AND_MEAN // exclude rare headers
|
||||
#include "windows.h"
|
||||
#endif
|
||||
|
||||
// User callback
|
||||
static PaUtilLogCallback userCB = NULL;
|
||||
|
||||
// Sets user callback
|
||||
void PaUtil_SetDebugPrintFunction(PaUtilLogCallback cb)
|
||||
{
|
||||
userCB = cb;
|
||||
}
|
||||
|
||||
/*
|
||||
If your platform doesn’t have vsnprintf, you are stuck with a
|
||||
VERY dangerous alternative, vsprintf (with no n)
|
||||
*/
|
||||
#if _MSC_VER
|
||||
/* Some Windows Mobile SDKs don't define vsnprintf but all define _vsnprintf (hopefully).
|
||||
According to MSDN "vsnprintf is identical to _vsnprintf". So we use _vsnprintf with MSC.
|
||||
*/
|
||||
#define VSNPRINTF _vsnprintf
|
||||
#else
|
||||
#define VSNPRINTF vsnprintf
|
||||
#endif
|
||||
|
||||
#define PA_LOG_BUF_SIZE 2048
|
||||
|
||||
void PaUtil_DebugPrint( const char *format, ... )
|
||||
{
|
||||
// Optional logging into Output console of Visual Studio
|
||||
#if defined(_MSC_VER) && defined(PA_ENABLE_MSVC_DEBUG_OUTPUT)
|
||||
{
|
||||
char buf[PA_LOG_BUF_SIZE];
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
VSNPRINTF(buf, sizeof(buf), format, ap);
|
||||
buf[sizeof(buf)-1] = 0;
|
||||
OutputDebugStringA(buf);
|
||||
va_end(ap);
|
||||
}
|
||||
#endif
|
||||
|
||||
// Output to User-Callback
|
||||
if (userCB != NULL)
|
||||
{
|
||||
char strdump[PA_LOG_BUF_SIZE];
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
VSNPRINTF(strdump, sizeof(strdump), format, ap);
|
||||
strdump[sizeof(strdump)-1] = 0;
|
||||
userCB(strdump);
|
||||
va_end(ap);
|
||||
}
|
||||
else
|
||||
// Standard output to stderr
|
||||
{
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
vfprintf(stderr, format, ap);
|
||||
va_end(ap);
|
||||
fflush(stderr);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,149 +1,149 @@
|
|||
#ifndef PA_LOG_H
|
||||
#define PA_LOG_H
|
||||
/*
|
||||
* Log file redirector function
|
||||
* Copyright (c) 1999-2006 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup common_src
|
||||
*/
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
|
||||
void PaUtil_DebugPrint( const char *format, ... );
|
||||
|
||||
|
||||
/*
|
||||
The basic format for log messages is described below. If you need to
|
||||
add any log messages, please follow this format.
|
||||
|
||||
Function entry (void function):
|
||||
|
||||
"FunctionName called.\n"
|
||||
|
||||
Function entry (non void function):
|
||||
|
||||
"FunctionName called:\n"
|
||||
"\tParam1Type param1: param1Value\n"
|
||||
"\tParam2Type param2: param2Value\n" (etc...)
|
||||
|
||||
|
||||
Function exit (no return value):
|
||||
|
||||
"FunctionName returned.\n"
|
||||
|
||||
Function exit (simple return value):
|
||||
|
||||
"FunctionName returned:\n"
|
||||
"\tReturnType: returnValue\n"
|
||||
|
||||
If the return type is an error code, the error text is displayed in ()
|
||||
|
||||
If the return type is not an error code, but has taken a special value
|
||||
because an error occurred, then the reason for the error is shown in []
|
||||
|
||||
If the return type is a struct ptr, the struct is dumped.
|
||||
|
||||
See the code below for examples
|
||||
*/
|
||||
|
||||
/** PA_DEBUG() provides a simple debug message printing facility. The macro
|
||||
passes it's argument to a printf-like function called PaUtil_DebugPrint()
|
||||
which prints to stderr and always flushes the stream after printing.
|
||||
Because preprocessor macros cannot directly accept variable length argument
|
||||
lists, calls to the macro must include an additional set of parenthesis, eg:
|
||||
PA_DEBUG(("errorno: %d", 1001 ));
|
||||
*/
|
||||
|
||||
|
||||
#ifdef PA_ENABLE_DEBUG_OUTPUT
|
||||
#define PA_DEBUG(x) PaUtil_DebugPrint x ;
|
||||
#else
|
||||
#define PA_DEBUG(x)
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef PA_LOG_API_CALLS
|
||||
#define PA_LOGAPI(x) PaUtil_DebugPrint x
|
||||
|
||||
#define PA_LOGAPI_ENTER(functionName) PaUtil_DebugPrint( functionName " called.\n" )
|
||||
|
||||
#define PA_LOGAPI_ENTER_PARAMS(functionName) PaUtil_DebugPrint( functionName " called:\n" )
|
||||
|
||||
#define PA_LOGAPI_EXIT(functionName) PaUtil_DebugPrint( functionName " returned.\n" )
|
||||
|
||||
#define PA_LOGAPI_EXIT_PAERROR( functionName, result ) \
|
||||
PaUtil_DebugPrint( functionName " returned:\n" ); \
|
||||
PaUtil_DebugPrint("\tPaError: %d ( %s )\n", result, Pa_GetErrorText( result ) )
|
||||
|
||||
#define PA_LOGAPI_EXIT_T( functionName, resultFormatString, result ) \
|
||||
PaUtil_DebugPrint( functionName " returned:\n" ); \
|
||||
PaUtil_DebugPrint("\t" resultFormatString "\n", result )
|
||||
|
||||
#define PA_LOGAPI_EXIT_PAERROR_OR_T_RESULT( functionName, positiveResultFormatString, result ) \
|
||||
PaUtil_DebugPrint( functionName " returned:\n" ); \
|
||||
if( result > 0 ) \
|
||||
PaUtil_DebugPrint("\t" positiveResultFormatString "\n", result ); \
|
||||
else \
|
||||
PaUtil_DebugPrint("\tPaError: %d ( %s )\n", result, Pa_GetErrorText( result ) )
|
||||
#else
|
||||
#define PA_LOGAPI(x)
|
||||
#define PA_LOGAPI_ENTER(functionName)
|
||||
#define PA_LOGAPI_ENTER_PARAMS(functionName)
|
||||
#define PA_LOGAPI_EXIT(functionName)
|
||||
#define PA_LOGAPI_EXIT_PAERROR( functionName, result )
|
||||
#define PA_LOGAPI_EXIT_T( functionName, resultFormatString, result )
|
||||
#define PA_LOGAPI_EXIT_PAERROR_OR_T_RESULT( functionName, positiveResultFormatString, result )
|
||||
#endif
|
||||
|
||||
|
||||
typedef void (*PaUtilLogCallback ) (const char *log);
|
||||
|
||||
/**
|
||||
Install user provided log function
|
||||
*/
|
||||
void PaUtil_SetDebugPrintFunction(PaUtilLogCallback cb);
|
||||
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* PA_LOG_H */
|
||||
#ifndef PA_LOG_H
|
||||
#define PA_LOG_H
|
||||
/*
|
||||
* Log file redirector function
|
||||
* Copyright (c) 1999-2006 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup common_src
|
||||
*/
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
|
||||
void PaUtil_DebugPrint( const char *format, ... );
|
||||
|
||||
|
||||
/*
|
||||
The basic format for log messages is described below. If you need to
|
||||
add any log messages, please follow this format.
|
||||
|
||||
Function entry (void function):
|
||||
|
||||
"FunctionName called.\n"
|
||||
|
||||
Function entry (non void function):
|
||||
|
||||
"FunctionName called:\n"
|
||||
"\tParam1Type param1: param1Value\n"
|
||||
"\tParam2Type param2: param2Value\n" (etc...)
|
||||
|
||||
|
||||
Function exit (no return value):
|
||||
|
||||
"FunctionName returned.\n"
|
||||
|
||||
Function exit (simple return value):
|
||||
|
||||
"FunctionName returned:\n"
|
||||
"\tReturnType: returnValue\n"
|
||||
|
||||
If the return type is an error code, the error text is displayed in ()
|
||||
|
||||
If the return type is not an error code, but has taken a special value
|
||||
because an error occurred, then the reason for the error is shown in []
|
||||
|
||||
If the return type is a struct ptr, the struct is dumped.
|
||||
|
||||
See the code below for examples
|
||||
*/
|
||||
|
||||
/** PA_DEBUG() provides a simple debug message printing facility. The macro
|
||||
passes it's argument to a printf-like function called PaUtil_DebugPrint()
|
||||
which prints to stderr and always flushes the stream after printing.
|
||||
Because preprocessor macros cannot directly accept variable length argument
|
||||
lists, calls to the macro must include an additional set of parenthesis, eg:
|
||||
PA_DEBUG(("errorno: %d", 1001 ));
|
||||
*/
|
||||
|
||||
|
||||
#ifdef PA_ENABLE_DEBUG_OUTPUT
|
||||
#define PA_DEBUG(x) PaUtil_DebugPrint x ;
|
||||
#else
|
||||
#define PA_DEBUG(x)
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef PA_LOG_API_CALLS
|
||||
#define PA_LOGAPI(x) PaUtil_DebugPrint x
|
||||
|
||||
#define PA_LOGAPI_ENTER(functionName) PaUtil_DebugPrint( functionName " called.\n" )
|
||||
|
||||
#define PA_LOGAPI_ENTER_PARAMS(functionName) PaUtil_DebugPrint( functionName " called:\n" )
|
||||
|
||||
#define PA_LOGAPI_EXIT(functionName) PaUtil_DebugPrint( functionName " returned.\n" )
|
||||
|
||||
#define PA_LOGAPI_EXIT_PAERROR( functionName, result ) \
|
||||
PaUtil_DebugPrint( functionName " returned:\n" ); \
|
||||
PaUtil_DebugPrint("\tPaError: %d ( %s )\n", result, Pa_GetErrorText( result ) )
|
||||
|
||||
#define PA_LOGAPI_EXIT_T( functionName, resultFormatString, result ) \
|
||||
PaUtil_DebugPrint( functionName " returned:\n" ); \
|
||||
PaUtil_DebugPrint("\t" resultFormatString "\n", result )
|
||||
|
||||
#define PA_LOGAPI_EXIT_PAERROR_OR_T_RESULT( functionName, positiveResultFormatString, result ) \
|
||||
PaUtil_DebugPrint( functionName " returned:\n" ); \
|
||||
if( result > 0 ) \
|
||||
PaUtil_DebugPrint("\t" positiveResultFormatString "\n", result ); \
|
||||
else \
|
||||
PaUtil_DebugPrint("\tPaError: %d ( %s )\n", result, Pa_GetErrorText( result ) )
|
||||
#else
|
||||
#define PA_LOGAPI(x)
|
||||
#define PA_LOGAPI_ENTER(functionName)
|
||||
#define PA_LOGAPI_ENTER_PARAMS(functionName)
|
||||
#define PA_LOGAPI_EXIT(functionName)
|
||||
#define PA_LOGAPI_EXIT_PAERROR( functionName, result )
|
||||
#define PA_LOGAPI_EXIT_T( functionName, resultFormatString, result )
|
||||
#define PA_LOGAPI_EXIT_PAERROR_OR_T_RESULT( functionName, positiveResultFormatString, result )
|
||||
#endif
|
||||
|
||||
|
||||
typedef void (*PaUtilLogCallback ) (const char *log);
|
||||
|
||||
/**
|
||||
Install user provided log function
|
||||
*/
|
||||
void PaUtil_SetDebugPrintFunction(PaUtilLogCallback cb);
|
||||
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* PA_LOG_H */
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -1,136 +1,136 @@
|
|||
/*
|
||||
* Internal blocking interfaces for PortAudio Apple AUHAL implementation
|
||||
*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Latest Version at: http://www.portaudio.com
|
||||
*
|
||||
* Written by Bjorn Roche of XO Audio LLC, from PA skeleton code.
|
||||
* Portions copied from code by Dominic Mazzoni (who wrote a HAL implementation)
|
||||
*
|
||||
* Dominic's code was based on code by Phil Burk, Darren Gibbs,
|
||||
* Gord Peters, Stephane Letz, and Greg Pfiel.
|
||||
*
|
||||
* The following people also deserve acknowledgements:
|
||||
*
|
||||
* Olivier Tristan for feedback and testing
|
||||
* Glenn Zelniker and Z-Systems engineering for sponsoring the Blocking I/O
|
||||
* interface.
|
||||
*
|
||||
*
|
||||
* Based on the Open Source API proposed by Ross Bencina
|
||||
* Copyright (c) 1999-2002 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/**
|
||||
@file
|
||||
@ingroup hostapi_src
|
||||
*/
|
||||
|
||||
#ifndef PA_MAC_CORE_BLOCKING_H_
|
||||
#define PA_MAC_CORE_BLOCKING_H_
|
||||
|
||||
#include "pa_ringbuffer.h"
|
||||
#include "portaudio.h"
|
||||
#include "pa_mac_core_utilities.h"
|
||||
|
||||
/*
|
||||
* Number of miliseconds to busy wait whil waiting for data in blocking calls.
|
||||
*/
|
||||
#define PA_MAC_BLIO_BUSY_WAIT_SLEEP_INTERVAL (5)
|
||||
/*
|
||||
* Define exactly one of these blocking methods
|
||||
* PA_MAC_BLIO_MUTEX is not actively maintained.
|
||||
*/
|
||||
#define PA_MAC_BLIO_BUSY_WAIT
|
||||
/*
|
||||
#define PA_MAC_BLIO_MUTEX
|
||||
*/
|
||||
|
||||
typedef struct {
|
||||
PaUtilRingBuffer inputRingBuffer;
|
||||
PaUtilRingBuffer outputRingBuffer;
|
||||
size_t ringBufferFrames;
|
||||
PaSampleFormat inputSampleFormat;
|
||||
size_t inputSampleSizeActual;
|
||||
size_t inputSampleSizePow2;
|
||||
PaSampleFormat outputSampleFormat;
|
||||
size_t outputSampleSizeActual;
|
||||
size_t outputSampleSizePow2;
|
||||
|
||||
size_t framesPerBuffer;
|
||||
|
||||
int inChan;
|
||||
int outChan;
|
||||
|
||||
//PaStreamCallbackFlags statusFlags;
|
||||
uint32_t statusFlags;
|
||||
PaError errors;
|
||||
|
||||
/* Here we handle blocking, using condition variables. */
|
||||
#ifdef PA_MAC_BLIO_MUTEX
|
||||
volatile bool isInputEmpty;
|
||||
pthread_mutex_t inputMutex;
|
||||
pthread_cond_t inputCond;
|
||||
|
||||
volatile bool isOutputFull;
|
||||
pthread_mutex_t outputMutex;
|
||||
pthread_cond_t outputCond;
|
||||
#endif
|
||||
}
|
||||
PaMacBlio;
|
||||
|
||||
/*
|
||||
* These functions operate on condition and related variables.
|
||||
*/
|
||||
|
||||
PaError initializeBlioRingBuffers(
|
||||
PaMacBlio *blio,
|
||||
PaSampleFormat inputSampleFormat,
|
||||
PaSampleFormat outputSampleFormat,
|
||||
size_t framesPerBuffer,
|
||||
long ringBufferSize,
|
||||
int inChan,
|
||||
int outChan );
|
||||
PaError destroyBlioRingBuffers( PaMacBlio *blio );
|
||||
PaError resetBlioRingBuffers( PaMacBlio *blio );
|
||||
|
||||
int BlioCallback(
|
||||
const void *input, void *output,
|
||||
unsigned long frameCount,
|
||||
const PaStreamCallbackTimeInfo* timeInfo,
|
||||
PaStreamCallbackFlags statusFlags,
|
||||
void *userData );
|
||||
|
||||
void waitUntilBlioWriteBufferIsFlushed( PaMacBlio *blio );
|
||||
|
||||
#endif /*PA_MAC_CORE_BLOCKING_H_*/
|
||||
/*
|
||||
* Internal blocking interfaces for PortAudio Apple AUHAL implementation
|
||||
*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Latest Version at: http://www.portaudio.com
|
||||
*
|
||||
* Written by Bjorn Roche of XO Audio LLC, from PA skeleton code.
|
||||
* Portions copied from code by Dominic Mazzoni (who wrote a HAL implementation)
|
||||
*
|
||||
* Dominic's code was based on code by Phil Burk, Darren Gibbs,
|
||||
* Gord Peters, Stephane Letz, and Greg Pfiel.
|
||||
*
|
||||
* The following people also deserve acknowledgements:
|
||||
*
|
||||
* Olivier Tristan for feedback and testing
|
||||
* Glenn Zelniker and Z-Systems engineering for sponsoring the Blocking I/O
|
||||
* interface.
|
||||
*
|
||||
*
|
||||
* Based on the Open Source API proposed by Ross Bencina
|
||||
* Copyright (c) 1999-2002 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/**
|
||||
@file
|
||||
@ingroup hostapi_src
|
||||
*/
|
||||
|
||||
#ifndef PA_MAC_CORE_BLOCKING_H_
|
||||
#define PA_MAC_CORE_BLOCKING_H_
|
||||
|
||||
#include "pa_ringbuffer.h"
|
||||
#include "portaudio.h"
|
||||
#include "pa_mac_core_utilities.h"
|
||||
|
||||
/*
|
||||
* Number of miliseconds to busy wait whil waiting for data in blocking calls.
|
||||
*/
|
||||
#define PA_MAC_BLIO_BUSY_WAIT_SLEEP_INTERVAL (5)
|
||||
/*
|
||||
* Define exactly one of these blocking methods
|
||||
* PA_MAC_BLIO_MUTEX is not actively maintained.
|
||||
*/
|
||||
#define PA_MAC_BLIO_BUSY_WAIT
|
||||
/*
|
||||
#define PA_MAC_BLIO_MUTEX
|
||||
*/
|
||||
|
||||
typedef struct {
|
||||
PaUtilRingBuffer inputRingBuffer;
|
||||
PaUtilRingBuffer outputRingBuffer;
|
||||
size_t ringBufferFrames;
|
||||
PaSampleFormat inputSampleFormat;
|
||||
size_t inputSampleSizeActual;
|
||||
size_t inputSampleSizePow2;
|
||||
PaSampleFormat outputSampleFormat;
|
||||
size_t outputSampleSizeActual;
|
||||
size_t outputSampleSizePow2;
|
||||
|
||||
size_t framesPerBuffer;
|
||||
|
||||
int inChan;
|
||||
int outChan;
|
||||
|
||||
//PaStreamCallbackFlags statusFlags;
|
||||
uint32_t statusFlags;
|
||||
PaError errors;
|
||||
|
||||
/* Here we handle blocking, using condition variables. */
|
||||
#ifdef PA_MAC_BLIO_MUTEX
|
||||
volatile bool isInputEmpty;
|
||||
pthread_mutex_t inputMutex;
|
||||
pthread_cond_t inputCond;
|
||||
|
||||
volatile bool isOutputFull;
|
||||
pthread_mutex_t outputMutex;
|
||||
pthread_cond_t outputCond;
|
||||
#endif
|
||||
}
|
||||
PaMacBlio;
|
||||
|
||||
/*
|
||||
* These functions operate on condition and related variables.
|
||||
*/
|
||||
|
||||
PaError initializeBlioRingBuffers(
|
||||
PaMacBlio *blio,
|
||||
PaSampleFormat inputSampleFormat,
|
||||
PaSampleFormat outputSampleFormat,
|
||||
size_t framesPerBuffer,
|
||||
long ringBufferSize,
|
||||
int inChan,
|
||||
int outChan );
|
||||
PaError destroyBlioRingBuffers( PaMacBlio *blio );
|
||||
PaError resetBlioRingBuffers( PaMacBlio *blio );
|
||||
|
||||
int BlioCallback(
|
||||
const void *input, void *output,
|
||||
unsigned long frameCount,
|
||||
const PaStreamCallbackTimeInfo* timeInfo,
|
||||
PaStreamCallbackFlags statusFlags,
|
||||
void *userData );
|
||||
|
||||
void waitUntilBlioWriteBufferIsFlushed( PaMacBlio *blio );
|
||||
|
||||
#endif /*PA_MAC_CORE_BLOCKING_H_*/
|
||||
|
|
|
|||
|
|
@ -1,94 +1,94 @@
|
|||
//
|
||||
// AudioSessionTypes.h -- Copyright Microsoft Corporation, All Rights Reserved.
|
||||
//
|
||||
// Description: Type definitions used by the audio session manager RPC/COM interfaces
|
||||
//
|
||||
#pragma once
|
||||
|
||||
#ifndef __AUDIOSESSIONTYPES__
|
||||
#define __AUDIOSESSIONTYPES__
|
||||
|
||||
#if defined(__midl)
|
||||
#define MIDL_SIZE_IS(x) [size_is(x)]
|
||||
#define MIDL_STRING [string]
|
||||
#define MIDL_ANYSIZE_ARRAY
|
||||
#else // !defined(__midl)
|
||||
#define MIDL_SIZE_IS(x)
|
||||
#define MIDL_STRING
|
||||
#define MIDL_ANYSIZE_ARRAY ANYSIZE_ARRAY
|
||||
#endif // defined(__midl)
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: AudioClient share mode
|
||||
//
|
||||
// AUDCLNT_SHAREMODE_SHARED - The device will be opened in shared mode and use the
|
||||
// WAS format.
|
||||
// AUDCLNT_SHAREMODE_EXCLUSIVE - The device will be opened in exclusive mode and use the
|
||||
// application specified format.
|
||||
//
|
||||
typedef enum _AUDCLNT_SHAREMODE
|
||||
{
|
||||
AUDCLNT_SHAREMODE_SHARED,
|
||||
AUDCLNT_SHAREMODE_EXCLUSIVE
|
||||
} AUDCLNT_SHAREMODE;
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: AudioClient stream flags
|
||||
//
|
||||
// Can be a combination of AUDCLNT_STREAMFLAGS and AUDCLNT_SYSFXFLAGS:
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS (this group of flags uses the high word, w/exception of high-bit which is reserved, 0x7FFF0000):
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS_CROSSPROCESS - Audio policy control for this stream will be shared with
|
||||
// with other process sessions that use the same audio session
|
||||
// GUID.
|
||||
// AUDCLNT_STREAMFLAGS_LOOPBACK - Initializes a renderer endpoint for a loopback audio application.
|
||||
// In this mode, a capture stream will be opened on the specified
|
||||
// renderer endpoint. Shared mode and a renderer endpoint is required.
|
||||
// Otherwise the IAudioClient::Initialize call will fail. If the
|
||||
// initialize is successful, a capture stream will be available
|
||||
// from the IAudioClient object.
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS_EVENTCALLBACK - An exclusive mode client will supply an event handle that will be
|
||||
// signaled when an IRP completes (or a waveRT buffer completes) telling
|
||||
// it to fill the next buffer
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS_NOPERSIST - Session state will not be persisted
|
||||
//
|
||||
// AUDCLNT_SYSFXFLAGS (these flags use low word 0x0000FFFF):
|
||||
//
|
||||
// none defined currently
|
||||
//
|
||||
#define AUDCLNT_STREAMFLAGS_CROSSPROCESS 0x00010000
|
||||
#define AUDCLNT_STREAMFLAGS_LOOPBACK 0x00020000
|
||||
#define AUDCLNT_STREAMFLAGS_EVENTCALLBACK 0x00040000
|
||||
#define AUDCLNT_STREAMFLAGS_NOPERSIST 0x00080000
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: Device share mode - sharing mode for the audio device.
|
||||
//
|
||||
// DeviceShared - The device can be shared with other processes.
|
||||
// DeviceExclusive - The device will only be used by this process.
|
||||
//
|
||||
typedef enum _DeviceShareMode
|
||||
{
|
||||
DeviceShared,
|
||||
DeviceExclusive
|
||||
} DeviceShareMode;
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: AudioSession State.
|
||||
//
|
||||
// AudioSessionStateInactive - The session has no active audio streams.
|
||||
// AudioSessionStateActive - The session has active audio streams.
|
||||
// AudioSessionStateExpired - The session is dormant.
|
||||
typedef enum _AudioSessionState
|
||||
{
|
||||
AudioSessionStateInactive = 0,
|
||||
AudioSessionStateActive = 1,
|
||||
AudioSessionStateExpired = 2
|
||||
} AudioSessionState;
|
||||
|
||||
#endif
|
||||
|
||||
//
|
||||
// AudioSessionTypes.h -- Copyright Microsoft Corporation, All Rights Reserved.
|
||||
//
|
||||
// Description: Type definitions used by the audio session manager RPC/COM interfaces
|
||||
//
|
||||
#pragma once
|
||||
|
||||
#ifndef __AUDIOSESSIONTYPES__
|
||||
#define __AUDIOSESSIONTYPES__
|
||||
|
||||
#if defined(__midl)
|
||||
#define MIDL_SIZE_IS(x) [size_is(x)]
|
||||
#define MIDL_STRING [string]
|
||||
#define MIDL_ANYSIZE_ARRAY
|
||||
#else // !defined(__midl)
|
||||
#define MIDL_SIZE_IS(x)
|
||||
#define MIDL_STRING
|
||||
#define MIDL_ANYSIZE_ARRAY ANYSIZE_ARRAY
|
||||
#endif // defined(__midl)
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: AudioClient share mode
|
||||
//
|
||||
// AUDCLNT_SHAREMODE_SHARED - The device will be opened in shared mode and use the
|
||||
// WAS format.
|
||||
// AUDCLNT_SHAREMODE_EXCLUSIVE - The device will be opened in exclusive mode and use the
|
||||
// application specified format.
|
||||
//
|
||||
typedef enum _AUDCLNT_SHAREMODE
|
||||
{
|
||||
AUDCLNT_SHAREMODE_SHARED,
|
||||
AUDCLNT_SHAREMODE_EXCLUSIVE
|
||||
} AUDCLNT_SHAREMODE;
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: AudioClient stream flags
|
||||
//
|
||||
// Can be a combination of AUDCLNT_STREAMFLAGS and AUDCLNT_SYSFXFLAGS:
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS (this group of flags uses the high word, w/exception of high-bit which is reserved, 0x7FFF0000):
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS_CROSSPROCESS - Audio policy control for this stream will be shared with
|
||||
// with other process sessions that use the same audio session
|
||||
// GUID.
|
||||
// AUDCLNT_STREAMFLAGS_LOOPBACK - Initializes a renderer endpoint for a loopback audio application.
|
||||
// In this mode, a capture stream will be opened on the specified
|
||||
// renderer endpoint. Shared mode and a renderer endpoint is required.
|
||||
// Otherwise the IAudioClient::Initialize call will fail. If the
|
||||
// initialize is successful, a capture stream will be available
|
||||
// from the IAudioClient object.
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS_EVENTCALLBACK - An exclusive mode client will supply an event handle that will be
|
||||
// signaled when an IRP completes (or a waveRT buffer completes) telling
|
||||
// it to fill the next buffer
|
||||
//
|
||||
// AUDCLNT_STREAMFLAGS_NOPERSIST - Session state will not be persisted
|
||||
//
|
||||
// AUDCLNT_SYSFXFLAGS (these flags use low word 0x0000FFFF):
|
||||
//
|
||||
// none defined currently
|
||||
//
|
||||
#define AUDCLNT_STREAMFLAGS_CROSSPROCESS 0x00010000
|
||||
#define AUDCLNT_STREAMFLAGS_LOOPBACK 0x00020000
|
||||
#define AUDCLNT_STREAMFLAGS_EVENTCALLBACK 0x00040000
|
||||
#define AUDCLNT_STREAMFLAGS_NOPERSIST 0x00080000
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: Device share mode - sharing mode for the audio device.
|
||||
//
|
||||
// DeviceShared - The device can be shared with other processes.
|
||||
// DeviceExclusive - The device will only be used by this process.
|
||||
//
|
||||
typedef enum _DeviceShareMode
|
||||
{
|
||||
DeviceShared,
|
||||
DeviceExclusive
|
||||
} DeviceShareMode;
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Description: AudioSession State.
|
||||
//
|
||||
// AudioSessionStateInactive - The session has no active audio streams.
|
||||
// AudioSessionStateActive - The session has active audio streams.
|
||||
// AudioSessionStateExpired - The session is dormant.
|
||||
typedef enum _AudioSessionState
|
||||
{
|
||||
AudioSessionStateInactive = 0,
|
||||
AudioSessionStateActive = 1,
|
||||
AudioSessionStateExpired = 2
|
||||
} AudioSessionState;
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -1,186 +1,186 @@
|
|||
|
||||
/*++
|
||||
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
|
||||
Module Name:
|
||||
|
||||
devpkey.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Defines property keys for the Plug and Play Device Property API.
|
||||
|
||||
Author:
|
||||
|
||||
Jim Cavalaris (jamesca) 10-14-2003
|
||||
|
||||
Environment:
|
||||
|
||||
User-mode only.
|
||||
|
||||
Revision History:
|
||||
|
||||
14-October-2003 jamesca
|
||||
|
||||
Creation and initial implementation.
|
||||
|
||||
20-June-2006 dougb
|
||||
|
||||
Copied Jim's version replaced "DEFINE_DEVPROPKEY(DEVPKEY_" with "DEFINE_PROPERTYKEY(PKEY_"
|
||||
|
||||
--*/
|
||||
|
||||
//#include <devpropdef.h>
|
||||
|
||||
//
|
||||
// _NAME
|
||||
//
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_NAME, 0xb725f130, 0x47ef, 0x101a, 0xa5, 0xf1, 0x02, 0x60, 0x8c, 0x9e, 0xeb, 0xac, 10); // DEVPROP_TYPE_STRING
|
||||
|
||||
//
|
||||
// Device properties
|
||||
// These PKEYs correspond to the old setupapi SPDRP_XXX properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DeviceDesc, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_HardwareIds, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 3); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_CompatibleIds, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 4); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Service, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 6); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Class, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 9); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ClassGuid, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 10); // DEVPROP_TYPE_GUID
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Driver, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 11); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ConfigFlags, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 12); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Manufacturer, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 13); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_FriendlyName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 14); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LocationInfo, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 15); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_PDOName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 16); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Capabilities, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 17); // DEVPROP_TYPE_UNINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_UINumber, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 18); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_UpperFilters, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 19); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LowerFilters, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 20); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BusTypeGuid, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 21); // DEVPROP_TYPE_GUID
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LegacyBusType, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 22); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BusNumber, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 23); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_EnumeratorName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 24); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Security, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 25); // DEVPROP_TYPE_SECURITY_DESCRIPTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_SecuritySDS, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 26); // DEVPROP_TYPE_SECURITY_DESCRIPTOR_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DevType, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 27); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Exclusive, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 28); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Characteristics, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 29); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Address, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 30); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_UINumberDescFormat, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 31); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_PowerData, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 32); // DEVPROP_TYPE_BINARY
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalPolicy, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 33); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalPolicyDefault, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 34); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalPolicyOverride, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 35); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_InstallState, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 36); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LocationPaths, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 37); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Device properties
|
||||
// These PKEYs correspond to a device's status and problem code
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DevNodeStatus, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 2); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ProblemCode, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 3); // DEVPROP_TYPE_UINT32
|
||||
|
||||
//
|
||||
// Device properties
|
||||
// These PKEYs correspond to device relations
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_EjectionRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 4); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 5); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_PowerRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 6); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BusRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 7); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Parent, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 8); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Children, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 9); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Siblings, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 10); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Other Device properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Reported, 0x80497100, 0x8c73, 0x48b9, 0xaa, 0xd9, 0xce, 0x38, 0x7e, 0x19, 0xc5, 0x6e, 2); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Legacy, 0x80497100, 0x8c73, 0x48b9, 0xaa, 0xd9, 0xce, 0x38, 0x7e, 0x19, 0xc5, 0x6e, 3); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_InstanceId, 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 256); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Numa_Proximity_Domain, 0x540b947e, 0x8b40, 0x45bc, 0xa8, 0xa2, 0x6a, 0x0b, 0x89, 0x4c, 0xbd, 0xa2, 1); // DEVPROP_TYPE_UINT32
|
||||
|
||||
//
|
||||
// Device driver properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverDate, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 2); // DEVPROP_TYPE_FILETIME
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverVersion, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 3); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverDesc, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 4); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverInfPath, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 5); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverInfSection, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 6); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverInfSectionExt, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 7); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_MatchingDeviceId, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 8); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverProvider, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 9); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverPropPageProvider, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 10); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverCoInstallers, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 11); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ResourcePickerTags, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 12); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ResourcePickerExceptions, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 13); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverRank, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 14); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverLogoLevel, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 15); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_NoConnectSound, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 17); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_GenericDriverInstalled, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 18); // DEVPROP_TYPE_BOOLEAN
|
||||
|
||||
|
||||
//
|
||||
// Device properties that were set by the driver package that was installed
|
||||
// on the device.
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_Model, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_VendorWebSite, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 3); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_DetailedDescription, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 4); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_DocumentationLink, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 5); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_Icon, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 6); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_BrandingIcon, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 7); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Device setup class properties
|
||||
// These PKEYs correspond to the old setupapi SPCRP_XXX properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_UpperFilters, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 19); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_LowerFilters, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 20); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Security, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 25); // DEVPROP_TYPE_SECURITY_DESCRIPTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_SecuritySDS, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 26); // DEVPROP_TYPE_SECURITY_DESCRIPTOR_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_DevType, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 27); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Exclusive, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 28); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Characteristics, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 29); // DEVPROP_TYPE_UINT32
|
||||
|
||||
//
|
||||
// Device setup class properties
|
||||
// These PKEYs correspond to registry values under the device class GUID key
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Name, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_ClassName, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 3); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Icon, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 4); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_ClassInstaller, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 5); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_PropPageProvider, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 6); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_NoInstallClass, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 7); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_NoDisplayClass, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 8); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_SilentInstall, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 9); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_NoUseClass, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 10); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_DefaultService, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 11); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_IconPath, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 12); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Other Device setup class properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_ClassCoInstallers, 0x713d1703, 0xa2e2, 0x49f5, 0x92, 0x14, 0x56, 0x47, 0x2e, 0xf3, 0xda, 0x5c, 2); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Device interface properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterface_FriendlyName, 0x026e516e, 0xb814, 0x414b, 0x83, 0xcd, 0x85, 0x6d, 0x6f, 0xef, 0x48, 0x22, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterface_Enabled, 0x026e516e, 0xb814, 0x414b, 0x83, 0xcd, 0x85, 0x6d, 0x6f, 0xef, 0x48, 0x22, 3); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterface_ClassGuid, 0x026e516e, 0xb814, 0x414b, 0x83, 0xcd, 0x85, 0x6d, 0x6f, 0xef, 0x48, 0x22, 4); // DEVPROP_TYPE_GUID
|
||||
|
||||
//
|
||||
// Device interface class properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterfaceClass_DefaultInterface, 0x14c83a99, 0x0b3f, 0x44b7, 0xbe, 0x4c, 0xa1, 0x78, 0xd3, 0x99, 0x05, 0x64, 2); // DEVPROP_TYPE_STRING
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*++
|
||||
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
|
||||
Module Name:
|
||||
|
||||
devpkey.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Defines property keys for the Plug and Play Device Property API.
|
||||
|
||||
Author:
|
||||
|
||||
Jim Cavalaris (jamesca) 10-14-2003
|
||||
|
||||
Environment:
|
||||
|
||||
User-mode only.
|
||||
|
||||
Revision History:
|
||||
|
||||
14-October-2003 jamesca
|
||||
|
||||
Creation and initial implementation.
|
||||
|
||||
20-June-2006 dougb
|
||||
|
||||
Copied Jim's version replaced "DEFINE_DEVPROPKEY(DEVPKEY_" with "DEFINE_PROPERTYKEY(PKEY_"
|
||||
|
||||
--*/
|
||||
|
||||
//#include <devpropdef.h>
|
||||
|
||||
//
|
||||
// _NAME
|
||||
//
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_NAME, 0xb725f130, 0x47ef, 0x101a, 0xa5, 0xf1, 0x02, 0x60, 0x8c, 0x9e, 0xeb, 0xac, 10); // DEVPROP_TYPE_STRING
|
||||
|
||||
//
|
||||
// Device properties
|
||||
// These PKEYs correspond to the old setupapi SPDRP_XXX properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DeviceDesc, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_HardwareIds, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 3); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_CompatibleIds, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 4); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Service, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 6); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Class, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 9); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ClassGuid, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 10); // DEVPROP_TYPE_GUID
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Driver, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 11); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ConfigFlags, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 12); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Manufacturer, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 13); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_FriendlyName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 14); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LocationInfo, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 15); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_PDOName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 16); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Capabilities, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 17); // DEVPROP_TYPE_UNINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_UINumber, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 18); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_UpperFilters, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 19); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LowerFilters, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 20); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BusTypeGuid, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 21); // DEVPROP_TYPE_GUID
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LegacyBusType, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 22); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BusNumber, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 23); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_EnumeratorName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 24); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Security, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 25); // DEVPROP_TYPE_SECURITY_DESCRIPTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_SecuritySDS, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 26); // DEVPROP_TYPE_SECURITY_DESCRIPTOR_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DevType, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 27); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Exclusive, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 28); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Characteristics, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 29); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Address, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 30); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_UINumberDescFormat, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 31); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_PowerData, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 32); // DEVPROP_TYPE_BINARY
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalPolicy, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 33); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalPolicyDefault, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 34); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalPolicyOverride, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 35); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_InstallState, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 36); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_LocationPaths, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 37); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Device properties
|
||||
// These PKEYs correspond to a device's status and problem code
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DevNodeStatus, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 2); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ProblemCode, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 3); // DEVPROP_TYPE_UINT32
|
||||
|
||||
//
|
||||
// Device properties
|
||||
// These PKEYs correspond to device relations
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_EjectionRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 4); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_RemovalRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 5); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_PowerRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 6); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BusRelations, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 7); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Parent, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 8); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Children, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 9); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Siblings, 0x4340a6c5, 0x93fa, 0x4706, 0x97, 0x2c, 0x7b, 0x64, 0x80, 0x08, 0xa5, 0xa7, 10); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Other Device properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Reported, 0x80497100, 0x8c73, 0x48b9, 0xaa, 0xd9, 0xce, 0x38, 0x7e, 0x19, 0xc5, 0x6e, 2); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_Legacy, 0x80497100, 0x8c73, 0x48b9, 0xaa, 0xd9, 0xce, 0x38, 0x7e, 0x19, 0xc5, 0x6e, 3); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_InstanceId, 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 256); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Numa_Proximity_Domain, 0x540b947e, 0x8b40, 0x45bc, 0xa8, 0xa2, 0x6a, 0x0b, 0x89, 0x4c, 0xbd, 0xa2, 1); // DEVPROP_TYPE_UINT32
|
||||
|
||||
//
|
||||
// Device driver properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverDate, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 2); // DEVPROP_TYPE_FILETIME
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverVersion, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 3); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverDesc, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 4); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverInfPath, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 5); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverInfSection, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 6); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverInfSectionExt, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 7); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_MatchingDeviceId, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 8); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverProvider, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 9); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverPropPageProvider, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 10); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverCoInstallers, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 11); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ResourcePickerTags, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 12); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_ResourcePickerExceptions, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 13); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverRank, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 14); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_DriverLogoLevel, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 15); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_NoConnectSound, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 17); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_GenericDriverInstalled, 0xa8b865dd, 0x2e3d, 0x4094, 0xad, 0x97, 0xe5, 0x93, 0xa7, 0xc, 0x75, 0xd6, 18); // DEVPROP_TYPE_BOOLEAN
|
||||
|
||||
|
||||
//
|
||||
// Device properties that were set by the driver package that was installed
|
||||
// on the device.
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_Model, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_VendorWebSite, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 3); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_DetailedDescription, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 4); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_DocumentationLink, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 5); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_Icon, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 6); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_DrvPkg_BrandingIcon, 0xcf73bb51, 0x3abf, 0x44a2, 0x85, 0xe0, 0x9a, 0x3d, 0xc7, 0xa1, 0x21, 0x32, 7); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Device setup class properties
|
||||
// These PKEYs correspond to the old setupapi SPCRP_XXX properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_UpperFilters, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 19); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_LowerFilters, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 20); // DEVPROP_TYPE_STRING_LIST
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Security, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 25); // DEVPROP_TYPE_SECURITY_DESCRIPTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_SecuritySDS, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 26); // DEVPROP_TYPE_SECURITY_DESCRIPTOR_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_DevType, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 27); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Exclusive, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 28); // DEVPROP_TYPE_UINT32
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Characteristics, 0x4321918b, 0xf69e, 0x470d, 0xa5, 0xde, 0x4d, 0x88, 0xc7, 0x5a, 0xd2, 0x4b, 29); // DEVPROP_TYPE_UINT32
|
||||
|
||||
//
|
||||
// Device setup class properties
|
||||
// These PKEYs correspond to registry values under the device class GUID key
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Name, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_ClassName, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 3); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_Icon, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 4); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_ClassInstaller, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 5); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_PropPageProvider, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 6); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_NoInstallClass, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 7); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_NoDisplayClass, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 8); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_SilentInstall, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 9); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_NoUseClass, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 10); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_DefaultService, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 11); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_IconPath, 0x259abffc, 0x50a7, 0x47ce, 0xaf, 0x8, 0x68, 0xc9, 0xa7, 0xd7, 0x33, 0x66, 12); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Other Device setup class properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceClass_ClassCoInstallers, 0x713d1703, 0xa2e2, 0x49f5, 0x92, 0x14, 0x56, 0x47, 0x2e, 0xf3, 0xda, 0x5c, 2); // DEVPROP_TYPE_STRING_LIST
|
||||
|
||||
//
|
||||
// Device interface properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterface_FriendlyName, 0x026e516e, 0xb814, 0x414b, 0x83, 0xcd, 0x85, 0x6d, 0x6f, 0xef, 0x48, 0x22, 2); // DEVPROP_TYPE_STRING
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterface_Enabled, 0x026e516e, 0xb814, 0x414b, 0x83, 0xcd, 0x85, 0x6d, 0x6f, 0xef, 0x48, 0x22, 3); // DEVPROP_TYPE_BOOLEAN
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterface_ClassGuid, 0x026e516e, 0xb814, 0x414b, 0x83, 0xcd, 0x85, 0x6d, 0x6f, 0xef, 0x48, 0x22, 4); // DEVPROP_TYPE_GUID
|
||||
|
||||
//
|
||||
// Device interface class properties
|
||||
//
|
||||
DEFINE_PROPERTYKEY(PKEY_DeviceInterfaceClass_DefaultInterface, 0x14c83a99, 0x0b3f, 0x44b7, 0xbe, 0x4c, 0xa1, 0x78, 0xd3, 0x99, 0x05, 0x64, 2); // DEVPROP_TYPE_STRING
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -1,255 +1,255 @@
|
|||
#pragma once
|
||||
|
||||
#if __GNUC__ >=3
|
||||
#pragma GCC system_header
|
||||
#endif
|
||||
|
||||
#ifndef DEFINE_API_PKEY
|
||||
#include <propkey.h>
|
||||
#endif
|
||||
|
||||
#include <FunctionDiscoveryKeys_devpkey.h>
|
||||
|
||||
// FMTID_FD = {904b03a2-471d-423c-a584-f3483238a146}
|
||||
DEFINE_GUID(FMTID_FD, 0x904b03a2, 0x471d, 0x423c, 0xa5, 0x84, 0xf3, 0x48, 0x32, 0x38, 0xa1, 0x46);
|
||||
DEFINE_API_PKEY(PKEY_FD_Visibility, VisibilityFlags, 0x904b03a2, 0x471d, 0x423c, 0xa5, 0x84, 0xf3, 0x48, 0x32, 0x38, 0xa1, 0x46, 0x00000001); // VT_UINT
|
||||
#define FD_Visibility_Default 0
|
||||
#define FD_Visibility_Hidden 1
|
||||
|
||||
// FMTID_Device = {78C34FC8-104A-4aca-9EA4-524D52996E57}
|
||||
DEFINE_GUID(FMTID_Device, 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57);
|
||||
|
||||
DEFINE_API_PKEY(PKEY_Device_NotPresent, DeviceNotPresent , 0x904b03a2, 0x471d, 0x423c, 0xa5, 0x84, 0xf3, 0x48, 0x32, 0x38, 0xa1, 0x46, 0x00000002); // VT_UINT
|
||||
DEFINE_API_PKEY(PKEY_Device_QueueSize, DeviceQueueSize , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000024); // VT_UI4
|
||||
DEFINE_API_PKEY(PKEY_Device_Status, DeviceStatus , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000025); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_Device_Comment, DeviceComment , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000026); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_Device_Model, DeviceModel , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000027); // VT_LPWSTR
|
||||
|
||||
// Name: System.Device.BIOSVersion -- PKEY_Device_BIOSVersion
|
||||
// Type: String -- VT_LPWSTR (For variants: VT_BSTR) Legacy code may treat this as VT_BSTR.
|
||||
// FormatID: EAEE7F1D-6A33-44D1-9441-5F46DEF23198, 9
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BIOSVersion, 0xEAEE7F1D, 0x6A33, 0x44D1, 0x94, 0x41, 0x5F, 0x46, 0xDE, 0xF2, 0x31, 0x98, 9);
|
||||
|
||||
DEFINE_API_PKEY(PKEY_Write_Time, WriteTime , 0xf53b7e1c, 0x77e0, 0x4450, 0x8c, 0x5f, 0xa7, 0x6c, 0xc7, 0xfd, 0xe0, 0x58, 0x00000100); // VT_FILETIME
|
||||
|
||||
#ifdef FD_XP
|
||||
DEFINE_API_PKEY(PKEY_Device_InstanceId, DeviceInstanceId , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000100); // VT_LPWSTR
|
||||
#endif
|
||||
DEFINE_API_PKEY(PKEY_Device_Interface, DeviceInterface , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000101); // VT_CLSID
|
||||
|
||||
DEFINE_API_PKEY(PKEY_ExposedIIDs, ExposedIIDs , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00003002); // VT_VECTOR | VT_CLSID
|
||||
DEFINE_API_PKEY(PKEY_ExposedCLSIDs, ExposedCLSIDs , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00003003); // VT_VECTOR | VT_CLSID
|
||||
DEFINE_API_PKEY(PKEY_InstanceValidatorClsid,InstanceValidator , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00003004); // VT_CLSID
|
||||
|
||||
// FMTID_WSD = {92506491-FF95-4724-A05A-5B81885A7C92}
|
||||
DEFINE_GUID(FMTID_WSD, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92);
|
||||
|
||||
DEFINE_API_PKEY(PKEY_WSD_AddressURI, WSD_AddressURI, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001000); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_Types, WSD_Types, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001001); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_Scopes, WSD_Scopes, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001002); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_MetadataVersion, WSD_MetadataVersion, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001003); //VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_WSD_AppSeqInstanceID, WSD_AppSeqInstanceID, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001004); // VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_WSD_AppSeqSessionID, WSD_AppSeqSessionID, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001005); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_AppSeqMessageNumber, WSD_AppSeqMessageNumber, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001006); // VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_WSD_XAddrs, WSD_XAddrs, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00002000); // VT_LPWSTR or VT_VECTOR | VT_LPWSTR
|
||||
|
||||
DEFINE_API_PKEY(PKEY_WSD_MetadataClean, WSD_MetadataClean, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00000001); // VT_BOOL
|
||||
DEFINE_API_PKEY(PKEY_WSD_ServiceInfo, WSD_ServiceInfo, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00000002); // VT_VECTOR|VT_VARIANT (variants are VT_UNKNOWN)
|
||||
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_TYPE, PUBSVCS_TYPE, 0xF1B88AD3, 0x109C, 0x4FD2, 0xBA, 0x3F, 0x53, 0x5A, 0x76, 0x5F, 0x82, 0xF4, 0x00005001); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_SCOPE, PUBSVCS_SCOPE, 0x2AE2B567, 0xEECB, 0x4A3E, 0xB7, 0x53, 0x54, 0xC7, 0x25, 0x49, 0x43, 0x66, 0x00005002); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_METADATA, PUBSVCS_METADATA, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005003); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_METADATA_VERSION, PUBSVCS_METADATA_VERSION, 0xC0C96C15, 0x1823, 0x4E5B, 0x93, 0x48, 0xE8, 0x25, 0x19, 0x92, 0x3F, 0x04, 0x00005004); // VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_NETWORK_PROFILES_ALLOWED, PUBSVCS_NETWORK_PROFILES_ALLOWED, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005005); // VT_VECTOR | VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_NETWORK_PROFILES_DENIED, PUBSVCS_NETWORK_PROFILES_DENIED, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005006); // VT_VECTOR | VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_NETWORK_PROFILES_DEFAULT, PUBSVCS_NETWORK_PROFILES_DEFAULT, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005007); // VT_BOOL
|
||||
|
||||
// FMTID_PNPX = {656A3BB3-ECC0-43FD-8477-4AE0404A96CD}
|
||||
DEFINE_GUID(FMTID_PNPX, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD);
|
||||
// from Discovery messages
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_GlobalIdentity, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001000); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Types, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001001); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Scopes, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001002); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_XAddrs, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001003); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_MetadataVersion, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001004); // VT_UI8
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ID, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001005); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_RootProxy, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001006); // VT_BOOL
|
||||
|
||||
// for Directed Discovery
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_RemoteAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001006); // VT_LPWSTR
|
||||
|
||||
// from ThisModel metadata
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Manufacturer, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002000); // VT_LPWSTR (localizable)
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ManufacturerUrl, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ModelName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002002); // VT_LPWSTR (localizable)
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ModelNumber, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002003); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ModelUrl, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002004); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Upc, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002005); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_PresentationUrl, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002006); // VT_LPWSTR
|
||||
// from ThisDevice metadata
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_FriendlyName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003000); // VT_LPWSTR (localizable)
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_FirmwareVersion, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_SerialNumber, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003002); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_DeviceCategory, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003004); // VT_LPWSTR | VT_VECTOR
|
||||
// DeviceCategory values
|
||||
#define PNPX_DEVICECATEGORY_COMPUTER L"Computers"
|
||||
#define PNPX_DEVICECATEGORY_INPUTDEVICE L"Input"
|
||||
#define PNPX_DEVICECATEGORY_PRINTER L"Printers"
|
||||
#define PNPX_DEVICECATEGORY_SCANNER L"Scanners"
|
||||
#define PNPX_DEVICECATEGORY_FAX L"FAX"
|
||||
#define PNPX_DEVICECATEGORY_MFP L"MFP"
|
||||
#define PNPX_DEVICECATEGORY_CAMERA L"Cameras"
|
||||
#define PNPX_DEVICECATEGORY_STORAGE L"Storage"
|
||||
#define PNPX_DEVICECATEGORY_NETWORK_INFRASTRUCTURE L"NetworkInfrastructure"
|
||||
#define PNPX_DEVICECATEGORY_DISPLAYS L"Displays"
|
||||
#define PNPX_DEVICECATEGORY_MULTIMEDIA_DEVICE L"MediaDevices"
|
||||
#define PNPX_DEVICECATEGORY_GAMING_DEVICE L"Gaming"
|
||||
#define PNPX_DEVICECATEGORY_TELEPHONE L"Phones"
|
||||
#define PNPX_DEVICECATEGORY_HOME_AUTOMATION_SYSTEM L"HomeAutomation"
|
||||
#define PNPX_DEVICECATEGORY_HOME_SECURITY_SYSTEM L"HomeSecurity"
|
||||
#define PNPX_DEVICECATEGORY_OTHER L"Other"
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_DeviceCategory_Desc, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003005); // VT_LPWSTR | VT_VECTOR
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_PhysicalAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003006); // VT_UI1 | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_NetworkInterfaceLuid, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003007); // VT_UI8
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_NetworkInterfaceGuid, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003008); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_IpAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003009); // VT_LPWSTR | VT_VECTOR
|
||||
// from Relationship metadata
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ServiceAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00004000); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ServiceId, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00004001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ServiceTypes, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00004002); // VT_LPWSTR | VT_VECTOR
|
||||
// Association DB PKEYs
|
||||
DEFINE_API_PKEY(PKEY_PNPX_Devnode, PnPXDevNode, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00000001); // VT_BOOL
|
||||
DEFINE_API_PKEY(PKEY_PNPX_AssociationState, AssociationState, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00000002); // VT_UINT
|
||||
DEFINE_API_PKEY(PKEY_PNPX_AssociatedInstanceId, AssociatedInstanceId, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00000003); // VT_LPWSTR
|
||||
// for Computer Discovery
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_DomainName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00005000); // VT_LPWSTR
|
||||
// Use PKEY_ComputerName (propkey.h) DEFINE_PROPERTYKEY(PKEY_PNPX_MachineName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00005001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ShareName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00005002); // VT_LPWSTR
|
||||
|
||||
// SSDP Provider custom properties
|
||||
DEFINE_PROPERTYKEY(PKEY_SSDP_AltLocationInfo, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00006000); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_SSDP_DevLifeTime, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00006001); // VT_UI4
|
||||
DEFINE_PROPERTYKEY(PKEY_SSDP_NetworkInterface, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00006002); // VT_BOOL
|
||||
|
||||
// FMTID_PNPXDynamicProperty = {4FC5077E-B686-44BE-93E3-86CAFE368CCD}
|
||||
DEFINE_GUID(FMTID_PNPXDynamicProperty, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD);
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Installable, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD, 0x00000001); // VT_BOOL
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Associated, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD, 0x00000002); // VT_BOOL
|
||||
// PKEY_PNPX_Installed to be deprecated in Longhorn Server timeframe
|
||||
// this PKEY really represents Associated state
|
||||
#define PKEY_PNPX_Installed PKEY_PNPX_Associated // Deprecated! Please use PKEY_PNPX_Associated
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_CompatibleTypes, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD, 0x00000003); // VT_LPWSTR | VT_VECTOR
|
||||
|
||||
// WNET Provider properties
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Scope, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000001); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Type, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000002); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_DisplayType, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000003); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Usage, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000004); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_LocalName, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000005); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_RemoteName, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000006); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Comment, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000007); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Provider, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000008); // VT_LPWSTR
|
||||
|
||||
|
||||
// WCN Provider properties
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_Version, 0x88190b80, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000001); // VT_UI1
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_RequestType, 0x88190b81, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000002); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_AuthType, 0x88190b82, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000003); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_EncryptType, 0x88190b83, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000004); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConnType, 0x88190b84, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000005); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConfigMethods, 0x88190b85, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000006); // VT_INT
|
||||
// map WCN DeviceType to PKEY_PNPX_DeviceCategory
|
||||
//DEFINE_PROPERTYKEY(PKEY_WCN_DeviceType, 0x88190b86, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000007); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_RfBand, 0x88190b87, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000008); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_AssocState, 0x88190b88, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000009); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConfigError, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000a); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConfigState, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000b); // VT_UI1
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_DevicePasswordId, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000c); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_OSVersion, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000d); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_VendorExtension, 0x88190b8a, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000e); // VT_UI1 | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_RegistrarType, 0x88190b8b, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000f); // VT_INT
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// DriverPackage properties
|
||||
|
||||
#define PKEY_DriverPackage_Model PKEY_DrvPkg_Model
|
||||
#define PKEY_DriverPackage_VendorWebSite PKEY_DrvPkg_VendorWebSite
|
||||
#define PKEY_DriverPackage_DetailedDescription PKEY_DrvPkg_DetailedDescription
|
||||
#define PKEY_DriverPackage_DocumentationLink PKEY_DrvPkg_DocumentationLink
|
||||
#define PKEY_DriverPackage_Icon PKEY_DrvPkg_Icon
|
||||
#define PKEY_DriverPackage_BrandingIcon PKEY_DrvPkg_BrandingIcon
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Hardware properties
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Devinst, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4097);
|
||||
|
||||
// Name: System.Hardware.DisplayAttribute -- PKEY_Hardware_DisplayAttribute
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 5
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DisplayAttribute, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 5);
|
||||
|
||||
// Name: System.Hardware.DriverDate -- PKEY_Hardware_DriverDate
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 11
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DriverDate, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 11);
|
||||
|
||||
// Name: System.Hardware.DriverProvider -- PKEY_Hardware_DriverProvider
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 10
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DriverProvider, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 10);
|
||||
|
||||
// Name: System.Hardware.DriverVersion -- PKEY_Hardware_DriverVersion
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 9
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DriverVersion, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 9);
|
||||
|
||||
// Name: System.Hardware.Function -- PKEY_Hardware_Function
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4099
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Function, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4099);
|
||||
|
||||
// Name: System.Hardware.Icon -- PKEY_Hardware_Icon
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 3
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Icon, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 3);
|
||||
|
||||
// Name: System.Hardware.Image -- PKEY_Hardware_Image
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4098
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Image, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4098);
|
||||
|
||||
// Name: System.Hardware.Manufacturer -- PKEY_Hardware_Manufacturer
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 6
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Manufacturer, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 6);
|
||||
|
||||
// Name: System.Hardware.Model -- PKEY_Hardware_Model
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 7
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Model, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 7);
|
||||
|
||||
// Name: System.Hardware.Name -- PKEY_Hardware_Name
|
||||
// Type: String -- VT_LPWSTR (For variants: VT_BSTR)
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 2
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Name, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 2);
|
||||
|
||||
// Name: System.Hardware.SerialNumber -- PKEY_Hardware_SerialNumber
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 8
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_SerialNumber, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 8);
|
||||
|
||||
// Name: System.Hardware.ShellAttributes -- PKEY_Hardware_ShellAttributes
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4100
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_ShellAttributes, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4100);
|
||||
|
||||
// Name: System.Hardware.Status -- PKEY_Hardware_Status
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4096
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Status, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4096);
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
#if __GNUC__ >=3
|
||||
#pragma GCC system_header
|
||||
#endif
|
||||
|
||||
#ifndef DEFINE_API_PKEY
|
||||
#include <propkey.h>
|
||||
#endif
|
||||
|
||||
#include <FunctionDiscoveryKeys_devpkey.h>
|
||||
|
||||
// FMTID_FD = {904b03a2-471d-423c-a584-f3483238a146}
|
||||
DEFINE_GUID(FMTID_FD, 0x904b03a2, 0x471d, 0x423c, 0xa5, 0x84, 0xf3, 0x48, 0x32, 0x38, 0xa1, 0x46);
|
||||
DEFINE_API_PKEY(PKEY_FD_Visibility, VisibilityFlags, 0x904b03a2, 0x471d, 0x423c, 0xa5, 0x84, 0xf3, 0x48, 0x32, 0x38, 0xa1, 0x46, 0x00000001); // VT_UINT
|
||||
#define FD_Visibility_Default 0
|
||||
#define FD_Visibility_Hidden 1
|
||||
|
||||
// FMTID_Device = {78C34FC8-104A-4aca-9EA4-524D52996E57}
|
||||
DEFINE_GUID(FMTID_Device, 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57);
|
||||
|
||||
DEFINE_API_PKEY(PKEY_Device_NotPresent, DeviceNotPresent , 0x904b03a2, 0x471d, 0x423c, 0xa5, 0x84, 0xf3, 0x48, 0x32, 0x38, 0xa1, 0x46, 0x00000002); // VT_UINT
|
||||
DEFINE_API_PKEY(PKEY_Device_QueueSize, DeviceQueueSize , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000024); // VT_UI4
|
||||
DEFINE_API_PKEY(PKEY_Device_Status, DeviceStatus , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000025); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_Device_Comment, DeviceComment , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000026); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_Device_Model, DeviceModel , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000027); // VT_LPWSTR
|
||||
|
||||
// Name: System.Device.BIOSVersion -- PKEY_Device_BIOSVersion
|
||||
// Type: String -- VT_LPWSTR (For variants: VT_BSTR) Legacy code may treat this as VT_BSTR.
|
||||
// FormatID: EAEE7F1D-6A33-44D1-9441-5F46DEF23198, 9
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_BIOSVersion, 0xEAEE7F1D, 0x6A33, 0x44D1, 0x94, 0x41, 0x5F, 0x46, 0xDE, 0xF2, 0x31, 0x98, 9);
|
||||
|
||||
DEFINE_API_PKEY(PKEY_Write_Time, WriteTime , 0xf53b7e1c, 0x77e0, 0x4450, 0x8c, 0x5f, 0xa7, 0x6c, 0xc7, 0xfd, 0xe0, 0x58, 0x00000100); // VT_FILETIME
|
||||
|
||||
#ifdef FD_XP
|
||||
DEFINE_API_PKEY(PKEY_Device_InstanceId, DeviceInstanceId , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000100); // VT_LPWSTR
|
||||
#endif
|
||||
DEFINE_API_PKEY(PKEY_Device_Interface, DeviceInterface , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00000101); // VT_CLSID
|
||||
|
||||
DEFINE_API_PKEY(PKEY_ExposedIIDs, ExposedIIDs , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00003002); // VT_VECTOR | VT_CLSID
|
||||
DEFINE_API_PKEY(PKEY_ExposedCLSIDs, ExposedCLSIDs , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00003003); // VT_VECTOR | VT_CLSID
|
||||
DEFINE_API_PKEY(PKEY_InstanceValidatorClsid,InstanceValidator , 0x78c34fc8, 0x104a, 0x4aca, 0x9e, 0xa4, 0x52, 0x4d, 0x52, 0x99, 0x6e, 0x57, 0x00003004); // VT_CLSID
|
||||
|
||||
// FMTID_WSD = {92506491-FF95-4724-A05A-5B81885A7C92}
|
||||
DEFINE_GUID(FMTID_WSD, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92);
|
||||
|
||||
DEFINE_API_PKEY(PKEY_WSD_AddressURI, WSD_AddressURI, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001000); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_Types, WSD_Types, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001001); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_Scopes, WSD_Scopes, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001002); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_MetadataVersion, WSD_MetadataVersion, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001003); //VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_WSD_AppSeqInstanceID, WSD_AppSeqInstanceID, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001004); // VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_WSD_AppSeqSessionID, WSD_AppSeqSessionID, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001005); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_WSD_AppSeqMessageNumber, WSD_AppSeqMessageNumber, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00001006); // VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_WSD_XAddrs, WSD_XAddrs, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00002000); // VT_LPWSTR or VT_VECTOR | VT_LPWSTR
|
||||
|
||||
DEFINE_API_PKEY(PKEY_WSD_MetadataClean, WSD_MetadataClean, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00000001); // VT_BOOL
|
||||
DEFINE_API_PKEY(PKEY_WSD_ServiceInfo, WSD_ServiceInfo, 0x92506491, 0xFF95, 0x4724, 0xA0, 0x5A, 0x5B, 0x81, 0x88, 0x5A, 0x7C, 0x92, 0x00000002); // VT_VECTOR|VT_VARIANT (variants are VT_UNKNOWN)
|
||||
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_TYPE, PUBSVCS_TYPE, 0xF1B88AD3, 0x109C, 0x4FD2, 0xBA, 0x3F, 0x53, 0x5A, 0x76, 0x5F, 0x82, 0xF4, 0x00005001); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_SCOPE, PUBSVCS_SCOPE, 0x2AE2B567, 0xEECB, 0x4A3E, 0xB7, 0x53, 0x54, 0xC7, 0x25, 0x49, 0x43, 0x66, 0x00005002); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_METADATA, PUBSVCS_METADATA, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005003); // VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_METADATA_VERSION, PUBSVCS_METADATA_VERSION, 0xC0C96C15, 0x1823, 0x4E5B, 0x93, 0x48, 0xE8, 0x25, 0x19, 0x92, 0x3F, 0x04, 0x00005004); // VT_UI8
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_NETWORK_PROFILES_ALLOWED, PUBSVCS_NETWORK_PROFILES_ALLOWED, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005005); // VT_VECTOR | VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_NETWORK_PROFILES_DENIED, PUBSVCS_NETWORK_PROFILES_DENIED, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005006); // VT_VECTOR | VT_LPWSTR
|
||||
DEFINE_API_PKEY(PKEY_PUBSVCS_NETWORK_PROFILES_DEFAULT, PUBSVCS_NETWORK_PROFILES_DEFAULT, 0x63C6D5B8, 0xF73A, 0x4ACA, 0x96, 0x7E, 0x0C, 0xC7, 0x87, 0xE0, 0xB5, 0x59, 0x00005007); // VT_BOOL
|
||||
|
||||
// FMTID_PNPX = {656A3BB3-ECC0-43FD-8477-4AE0404A96CD}
|
||||
DEFINE_GUID(FMTID_PNPX, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD);
|
||||
// from Discovery messages
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_GlobalIdentity, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001000); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Types, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001001); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Scopes, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001002); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_XAddrs, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001003); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_MetadataVersion, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001004); // VT_UI8
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ID, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001005); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_RootProxy, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001006); // VT_BOOL
|
||||
|
||||
// for Directed Discovery
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_RemoteAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00001006); // VT_LPWSTR
|
||||
|
||||
// from ThisModel metadata
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Manufacturer, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002000); // VT_LPWSTR (localizable)
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ManufacturerUrl, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ModelName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002002); // VT_LPWSTR (localizable)
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ModelNumber, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002003); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ModelUrl, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002004); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Upc, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002005); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_PresentationUrl, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00002006); // VT_LPWSTR
|
||||
// from ThisDevice metadata
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_FriendlyName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003000); // VT_LPWSTR (localizable)
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_FirmwareVersion, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_SerialNumber, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003002); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_DeviceCategory, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003004); // VT_LPWSTR | VT_VECTOR
|
||||
// DeviceCategory values
|
||||
#define PNPX_DEVICECATEGORY_COMPUTER L"Computers"
|
||||
#define PNPX_DEVICECATEGORY_INPUTDEVICE L"Input"
|
||||
#define PNPX_DEVICECATEGORY_PRINTER L"Printers"
|
||||
#define PNPX_DEVICECATEGORY_SCANNER L"Scanners"
|
||||
#define PNPX_DEVICECATEGORY_FAX L"FAX"
|
||||
#define PNPX_DEVICECATEGORY_MFP L"MFP"
|
||||
#define PNPX_DEVICECATEGORY_CAMERA L"Cameras"
|
||||
#define PNPX_DEVICECATEGORY_STORAGE L"Storage"
|
||||
#define PNPX_DEVICECATEGORY_NETWORK_INFRASTRUCTURE L"NetworkInfrastructure"
|
||||
#define PNPX_DEVICECATEGORY_DISPLAYS L"Displays"
|
||||
#define PNPX_DEVICECATEGORY_MULTIMEDIA_DEVICE L"MediaDevices"
|
||||
#define PNPX_DEVICECATEGORY_GAMING_DEVICE L"Gaming"
|
||||
#define PNPX_DEVICECATEGORY_TELEPHONE L"Phones"
|
||||
#define PNPX_DEVICECATEGORY_HOME_AUTOMATION_SYSTEM L"HomeAutomation"
|
||||
#define PNPX_DEVICECATEGORY_HOME_SECURITY_SYSTEM L"HomeSecurity"
|
||||
#define PNPX_DEVICECATEGORY_OTHER L"Other"
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_DeviceCategory_Desc, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003005); // VT_LPWSTR | VT_VECTOR
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_PhysicalAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003006); // VT_UI1 | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_NetworkInterfaceLuid, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003007); // VT_UI8
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_NetworkInterfaceGuid, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003008); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_IpAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00003009); // VT_LPWSTR | VT_VECTOR
|
||||
// from Relationship metadata
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ServiceAddress, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00004000); // VT_LPWSTR | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ServiceId, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00004001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ServiceTypes, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00004002); // VT_LPWSTR | VT_VECTOR
|
||||
// Association DB PKEYs
|
||||
DEFINE_API_PKEY(PKEY_PNPX_Devnode, PnPXDevNode, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00000001); // VT_BOOL
|
||||
DEFINE_API_PKEY(PKEY_PNPX_AssociationState, AssociationState, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00000002); // VT_UINT
|
||||
DEFINE_API_PKEY(PKEY_PNPX_AssociatedInstanceId, AssociatedInstanceId, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00000003); // VT_LPWSTR
|
||||
// for Computer Discovery
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_DomainName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00005000); // VT_LPWSTR
|
||||
// Use PKEY_ComputerName (propkey.h) DEFINE_PROPERTYKEY(PKEY_PNPX_MachineName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00005001); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_ShareName, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00005002); // VT_LPWSTR
|
||||
|
||||
// SSDP Provider custom properties
|
||||
DEFINE_PROPERTYKEY(PKEY_SSDP_AltLocationInfo, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00006000); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_SSDP_DevLifeTime, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00006001); // VT_UI4
|
||||
DEFINE_PROPERTYKEY(PKEY_SSDP_NetworkInterface, 0x656A3BB3, 0xECC0, 0x43FD, 0x84, 0x77, 0x4A, 0xE0, 0x40, 0x4A, 0x96, 0xCD, 0x00006002); // VT_BOOL
|
||||
|
||||
// FMTID_PNPXDynamicProperty = {4FC5077E-B686-44BE-93E3-86CAFE368CCD}
|
||||
DEFINE_GUID(FMTID_PNPXDynamicProperty, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD);
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Installable, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD, 0x00000001); // VT_BOOL
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_Associated, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD, 0x00000002); // VT_BOOL
|
||||
// PKEY_PNPX_Installed to be deprecated in Longhorn Server timeframe
|
||||
// this PKEY really represents Associated state
|
||||
#define PKEY_PNPX_Installed PKEY_PNPX_Associated // Deprecated! Please use PKEY_PNPX_Associated
|
||||
DEFINE_PROPERTYKEY(PKEY_PNPX_CompatibleTypes, 0x4FC5077E, 0xB686, 0x44BE, 0x93, 0xE3, 0x86, 0xCA, 0xFE, 0x36, 0x8C, 0xCD, 0x00000003); // VT_LPWSTR | VT_VECTOR
|
||||
|
||||
// WNET Provider properties
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Scope, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000001); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Type, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000002); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_DisplayType, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000003); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Usage, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000004); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_LocalName, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000005); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_RemoteName, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000006); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Comment, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000007); // VT_LPWSTR
|
||||
DEFINE_PROPERTYKEY(PKEY_WNET_Provider, 0xdebda43a, 0x37b3, 0x4383, 0x91, 0xE7, 0x44, 0x98, 0xda, 0x29, 0x95, 0xab, 0x00000008); // VT_LPWSTR
|
||||
|
||||
|
||||
// WCN Provider properties
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_Version, 0x88190b80, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000001); // VT_UI1
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_RequestType, 0x88190b81, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000002); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_AuthType, 0x88190b82, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000003); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_EncryptType, 0x88190b83, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000004); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConnType, 0x88190b84, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000005); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConfigMethods, 0x88190b85, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000006); // VT_INT
|
||||
// map WCN DeviceType to PKEY_PNPX_DeviceCategory
|
||||
//DEFINE_PROPERTYKEY(PKEY_WCN_DeviceType, 0x88190b86, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000007); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_RfBand, 0x88190b87, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000008); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_AssocState, 0x88190b88, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x00000009); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConfigError, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000a); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_ConfigState, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000b); // VT_UI1
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_DevicePasswordId, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000c); // VT_INT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_OSVersion, 0x88190b89, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000d); // VT_UINT
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_VendorExtension, 0x88190b8a, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000e); // VT_UI1 | VT_VECTOR
|
||||
DEFINE_PROPERTYKEY(PKEY_WCN_RegistrarType, 0x88190b8b, 0x4684, 0x11da, 0xa2, 0x6a, 0x00, 0x02, 0xb3, 0x98, 0x8e, 0x81, 0x0000000f); // VT_INT
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// DriverPackage properties
|
||||
|
||||
#define PKEY_DriverPackage_Model PKEY_DrvPkg_Model
|
||||
#define PKEY_DriverPackage_VendorWebSite PKEY_DrvPkg_VendorWebSite
|
||||
#define PKEY_DriverPackage_DetailedDescription PKEY_DrvPkg_DetailedDescription
|
||||
#define PKEY_DriverPackage_DocumentationLink PKEY_DrvPkg_DocumentationLink
|
||||
#define PKEY_DriverPackage_Icon PKEY_DrvPkg_Icon
|
||||
#define PKEY_DriverPackage_BrandingIcon PKEY_DrvPkg_BrandingIcon
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Hardware properties
|
||||
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Devinst, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4097);
|
||||
|
||||
// Name: System.Hardware.DisplayAttribute -- PKEY_Hardware_DisplayAttribute
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 5
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DisplayAttribute, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 5);
|
||||
|
||||
// Name: System.Hardware.DriverDate -- PKEY_Hardware_DriverDate
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 11
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DriverDate, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 11);
|
||||
|
||||
// Name: System.Hardware.DriverProvider -- PKEY_Hardware_DriverProvider
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 10
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DriverProvider, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 10);
|
||||
|
||||
// Name: System.Hardware.DriverVersion -- PKEY_Hardware_DriverVersion
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 9
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_DriverVersion, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 9);
|
||||
|
||||
// Name: System.Hardware.Function -- PKEY_Hardware_Function
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4099
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Function, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4099);
|
||||
|
||||
// Name: System.Hardware.Icon -- PKEY_Hardware_Icon
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 3
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Icon, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 3);
|
||||
|
||||
// Name: System.Hardware.Image -- PKEY_Hardware_Image
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4098
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Image, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4098);
|
||||
|
||||
// Name: System.Hardware.Manufacturer -- PKEY_Hardware_Manufacturer
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 6
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Manufacturer, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 6);
|
||||
|
||||
// Name: System.Hardware.Model -- PKEY_Hardware_Model
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 7
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Model, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 7);
|
||||
|
||||
// Name: System.Hardware.Name -- PKEY_Hardware_Name
|
||||
// Type: String -- VT_LPWSTR (For variants: VT_BSTR)
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 2
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Name, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 2);
|
||||
|
||||
// Name: System.Hardware.SerialNumber -- PKEY_Hardware_SerialNumber
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 8
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_SerialNumber, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 8);
|
||||
|
||||
// Name: System.Hardware.ShellAttributes -- PKEY_Hardware_ShellAttributes
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4100
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_ShellAttributes, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4100);
|
||||
|
||||
// Name: System.Hardware.Status -- PKEY_Hardware_Status
|
||||
// Type: Unspecified -- VT_NULL
|
||||
// FormatID: 5EAF3EF2-E0CA-4598-BF06-71ED1D9DD953, 4096
|
||||
DEFINE_PROPERTYKEY(PKEY_Hardware_Status, 0x5EAF3EF2, 0xE0CA, 0x4598, 0xBF, 0x06, 0x71, 0xED, 0x1D, 0x9D, 0xD9, 0x53, 4096);
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -417,11 +417,11 @@ DEFINE_GUIDSTRUCT("6994AD04-93EF-11D0-A3CC-00A0C9223196",KSCATEGORY_AUDIO);
|
|||
DEFINE_GUIDSTRUCT("6994AD05-93EF-11D0-A3CC-00A0C9223196",KSCATEGORY_VIDEO);
|
||||
#define KSCATEGORY_VIDEO DEFINE_GUIDNAMED(KSCATEGORY_VIDEO)
|
||||
|
||||
/* Added for Vista and later */
|
||||
#define STATIC_KSCATEGORY_REALTIME \
|
||||
0xEB115FFCL, 0x10C8, 0x4964, 0x83, 0x1D, 0x6D, 0xCB, 0x02, 0xE6, 0xF2, 0x3F
|
||||
DEFINE_GUIDSTRUCT("EB115FFC-10C8-4964-831D-6DCB02E6F23F", KSCATEGORY_REALTIME);
|
||||
#define KSCATEGORY_REALTIME DEFINE_GUIDNAMED(KSCATEGORY_REALTIME)
|
||||
/* Added for Vista and later */
|
||||
#define STATIC_KSCATEGORY_REALTIME \
|
||||
0xEB115FFCL, 0x10C8, 0x4964, 0x83, 0x1D, 0x6D, 0xCB, 0x02, 0xE6, 0xF2, 0x3F
|
||||
DEFINE_GUIDSTRUCT("EB115FFC-10C8-4964-831D-6DCB02E6F23F", KSCATEGORY_REALTIME);
|
||||
#define KSCATEGORY_REALTIME DEFINE_GUIDNAMED(KSCATEGORY_REALTIME)
|
||||
|
||||
#define STATIC_KSCATEGORY_TEXT \
|
||||
0x6994AD06L,0x93EF,0x11D0,0xA3,0xCC,0x00,0xA0,0xC9,0x22,0x31,0x96
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -1,26 +1,26 @@
|
|||
#ifndef PID_FIRST_USABLE
|
||||
#define PID_FIRST_USABLE 2
|
||||
#endif
|
||||
|
||||
#ifndef REFPROPERTYKEY
|
||||
#ifdef __cplusplus
|
||||
#define REFPROPERTYKEY const PROPERTYKEY &
|
||||
#else // !__cplusplus
|
||||
#define REFPROPERTYKEY const PROPERTYKEY * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
#endif //REFPROPERTYKEY
|
||||
|
||||
#ifdef DEFINE_PROPERTYKEY
|
||||
#undef DEFINE_PROPERTYKEY
|
||||
#endif
|
||||
|
||||
#ifdef INITGUID
|
||||
#define DEFINE_PROPERTYKEY(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8, pid) EXTERN_C const PROPERTYKEY DECLSPEC_SELECTANY name = { { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } }, pid }
|
||||
#else
|
||||
#define DEFINE_PROPERTYKEY(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8, pid) EXTERN_C const PROPERTYKEY name
|
||||
#endif // INITGUID
|
||||
|
||||
#ifndef IsEqualPropertyKey
|
||||
#define IsEqualPropertyKey(a, b) (((a).pid == (b).pid) && IsEqualIID((a).fmtid, (b).fmtid) )
|
||||
#endif // IsEqualPropertyKey
|
||||
|
||||
#ifndef PID_FIRST_USABLE
|
||||
#define PID_FIRST_USABLE 2
|
||||
#endif
|
||||
|
||||
#ifndef REFPROPERTYKEY
|
||||
#ifdef __cplusplus
|
||||
#define REFPROPERTYKEY const PROPERTYKEY &
|
||||
#else // !__cplusplus
|
||||
#define REFPROPERTYKEY const PROPERTYKEY * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
#endif //REFPROPERTYKEY
|
||||
|
||||
#ifdef DEFINE_PROPERTYKEY
|
||||
#undef DEFINE_PROPERTYKEY
|
||||
#endif
|
||||
|
||||
#ifdef INITGUID
|
||||
#define DEFINE_PROPERTYKEY(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8, pid) EXTERN_C const PROPERTYKEY DECLSPEC_SELECTANY name = { { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } }, pid }
|
||||
#else
|
||||
#define DEFINE_PROPERTYKEY(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8, pid) EXTERN_C const PROPERTYKEY name
|
||||
#endif // INITGUID
|
||||
|
||||
#ifndef IsEqualPropertyKey
|
||||
#define IsEqualPropertyKey(a, b) (((a).pid == (b).pid) && IsEqualIID((a).fmtid, (b).fmtid) )
|
||||
#endif // IsEqualPropertyKey
|
||||
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -1,113 +1,113 @@
|
|||
#pragma once
|
||||
|
||||
#if __GNUC__ >=3
|
||||
#pragma GCC system_header
|
||||
#endif
|
||||
|
||||
#define RPC_range(min,max)
|
||||
|
||||
#define __RPC__in
|
||||
#define __RPC__in_string
|
||||
#define __RPC__in_opt_string
|
||||
#define __RPC__deref_opt_in_opt
|
||||
#define __RPC__opt_in_opt_string
|
||||
#define __RPC__in_ecount(size)
|
||||
#define __RPC__in_ecount_full(size)
|
||||
#define __RPC__in_ecount_full_string(size)
|
||||
#define __RPC__in_ecount_part(size, length)
|
||||
#define __RPC__in_ecount_full_opt(size)
|
||||
#define __RPC__in_ecount_full_opt_string(size)
|
||||
#define __RPC__inout_ecount_full_opt_string(size)
|
||||
#define __RPC__in_ecount_part_opt(size, length)
|
||||
|
||||
#define __RPC__deref_in
|
||||
#define __RPC__deref_in_string
|
||||
#define __RPC__deref_opt_in
|
||||
#define __RPC__deref_in_opt
|
||||
#define __RPC__deref_in_ecount(size)
|
||||
#define __RPC__deref_in_ecount_part(size, length)
|
||||
#define __RPC__deref_in_ecount_full(size)
|
||||
#define __RPC__deref_in_ecount_full_opt(size)
|
||||
#define __RPC__deref_in_ecount_full_string(size)
|
||||
#define __RPC__deref_in_ecount_full_opt_string(size)
|
||||
#define __RPC__deref_in_ecount_opt(size)
|
||||
#define __RPC__deref_in_ecount_opt_string(size)
|
||||
#define __RPC__deref_in_ecount_part_opt(size, length)
|
||||
|
||||
// [out]
|
||||
#define __RPC__out
|
||||
#define __RPC__out_ecount(size)
|
||||
#define __RPC__out_ecount_part(size, length)
|
||||
#define __RPC__out_ecount_full(size)
|
||||
#define __RPC__out_ecount_full_string(size)
|
||||
|
||||
// [in,out]
|
||||
#define __RPC__inout
|
||||
#define __RPC__inout_string
|
||||
#define __RPC__opt_inout
|
||||
#define __RPC__inout_ecount(size)
|
||||
#define __RPC__inout_ecount_part(size, length)
|
||||
#define __RPC__inout_ecount_full(size)
|
||||
#define __RPC__inout_ecount_full_string(size)
|
||||
|
||||
// [in,unique]
|
||||
#define __RPC__in_opt
|
||||
#define __RPC__in_ecount_opt(size)
|
||||
|
||||
|
||||
// [in,out,unique]
|
||||
#define __RPC__inout_opt
|
||||
#define __RPC__inout_ecount_opt(size)
|
||||
#define __RPC__inout_ecount_part_opt(size, length)
|
||||
#define __RPC__inout_ecount_full_opt(size)
|
||||
#define __RPC__inout_ecount_full_string(size)
|
||||
|
||||
// [out] **
|
||||
#define __RPC__deref_out
|
||||
#define __RPC__deref_out_string
|
||||
#define __RPC__deref_out_opt
|
||||
#define __RPC__deref_out_opt_string
|
||||
#define __RPC__deref_out_ecount(size)
|
||||
#define __RPC__deref_out_ecount_part(size, length)
|
||||
#define __RPC__deref_out_ecount_full(size)
|
||||
#define __RPC__deref_out_ecount_full_string(size)
|
||||
|
||||
|
||||
// [in,out] **, second pointer decoration.
|
||||
#define __RPC__deref_inout
|
||||
#define __RPC__deref_inout_string
|
||||
#define __RPC__deref_inout_opt
|
||||
#define __RPC__deref_inout_opt_string
|
||||
#define __RPC__deref_inout_ecount_full(size)
|
||||
#define __RPC__deref_inout_ecount_full_string(size)
|
||||
#define __RPC__deref_inout_ecount_opt(size)
|
||||
#define __RPC__deref_inout_ecount_part_opt(size, length)
|
||||
#define __RPC__deref_inout_ecount_full_opt(size)
|
||||
#define __RPC__deref_inout_ecount_full_opt_string(size)
|
||||
|
||||
// #define __RPC_out_opt out_opt is not allowed in rpc
|
||||
|
||||
// [in,out,unique]
|
||||
#define __RPC__deref_opt_inout
|
||||
#define __RPC__deref_opt_inout_string
|
||||
#define __RPC__deref_opt_inout_ecount(size)
|
||||
#define __RPC__deref_opt_inout_ecount_part(size, length)
|
||||
#define __RPC__deref_opt_inout_ecount_full(size)
|
||||
#define __RPC__deref_opt_inout_ecount_full_string(size)
|
||||
|
||||
#define __RPC__deref_out_ecount_opt(size)
|
||||
#define __RPC__deref_out_ecount_part_opt(size, length)
|
||||
#define __RPC__deref_out_ecount_full_opt(size)
|
||||
#define __RPC__deref_out_ecount_full_opt_string(size)
|
||||
|
||||
#define __RPC__deref_opt_inout_opt
|
||||
#define __RPC__deref_opt_inout_opt_string
|
||||
#define __RPC__deref_opt_inout_ecount_opt(size)
|
||||
#define __RPC__deref_opt_inout_ecount_part_opt(size, length)
|
||||
#define __RPC__deref_opt_inout_ecount_full_opt(size)
|
||||
#define __RPC__deref_opt_inout_ecount_full_opt_string(size)
|
||||
|
||||
#define __RPC_full_pointer
|
||||
#define __RPC_unique_pointer
|
||||
#define __RPC_ref_pointer
|
||||
#define __RPC_string
|
||||
#pragma once
|
||||
|
||||
#if __GNUC__ >=3
|
||||
#pragma GCC system_header
|
||||
#endif
|
||||
|
||||
#define RPC_range(min,max)
|
||||
|
||||
#define __RPC__in
|
||||
#define __RPC__in_string
|
||||
#define __RPC__in_opt_string
|
||||
#define __RPC__deref_opt_in_opt
|
||||
#define __RPC__opt_in_opt_string
|
||||
#define __RPC__in_ecount(size)
|
||||
#define __RPC__in_ecount_full(size)
|
||||
#define __RPC__in_ecount_full_string(size)
|
||||
#define __RPC__in_ecount_part(size, length)
|
||||
#define __RPC__in_ecount_full_opt(size)
|
||||
#define __RPC__in_ecount_full_opt_string(size)
|
||||
#define __RPC__inout_ecount_full_opt_string(size)
|
||||
#define __RPC__in_ecount_part_opt(size, length)
|
||||
|
||||
#define __RPC__deref_in
|
||||
#define __RPC__deref_in_string
|
||||
#define __RPC__deref_opt_in
|
||||
#define __RPC__deref_in_opt
|
||||
#define __RPC__deref_in_ecount(size)
|
||||
#define __RPC__deref_in_ecount_part(size, length)
|
||||
#define __RPC__deref_in_ecount_full(size)
|
||||
#define __RPC__deref_in_ecount_full_opt(size)
|
||||
#define __RPC__deref_in_ecount_full_string(size)
|
||||
#define __RPC__deref_in_ecount_full_opt_string(size)
|
||||
#define __RPC__deref_in_ecount_opt(size)
|
||||
#define __RPC__deref_in_ecount_opt_string(size)
|
||||
#define __RPC__deref_in_ecount_part_opt(size, length)
|
||||
|
||||
// [out]
|
||||
#define __RPC__out
|
||||
#define __RPC__out_ecount(size)
|
||||
#define __RPC__out_ecount_part(size, length)
|
||||
#define __RPC__out_ecount_full(size)
|
||||
#define __RPC__out_ecount_full_string(size)
|
||||
|
||||
// [in,out]
|
||||
#define __RPC__inout
|
||||
#define __RPC__inout_string
|
||||
#define __RPC__opt_inout
|
||||
#define __RPC__inout_ecount(size)
|
||||
#define __RPC__inout_ecount_part(size, length)
|
||||
#define __RPC__inout_ecount_full(size)
|
||||
#define __RPC__inout_ecount_full_string(size)
|
||||
|
||||
// [in,unique]
|
||||
#define __RPC__in_opt
|
||||
#define __RPC__in_ecount_opt(size)
|
||||
|
||||
|
||||
// [in,out,unique]
|
||||
#define __RPC__inout_opt
|
||||
#define __RPC__inout_ecount_opt(size)
|
||||
#define __RPC__inout_ecount_part_opt(size, length)
|
||||
#define __RPC__inout_ecount_full_opt(size)
|
||||
#define __RPC__inout_ecount_full_string(size)
|
||||
|
||||
// [out] **
|
||||
#define __RPC__deref_out
|
||||
#define __RPC__deref_out_string
|
||||
#define __RPC__deref_out_opt
|
||||
#define __RPC__deref_out_opt_string
|
||||
#define __RPC__deref_out_ecount(size)
|
||||
#define __RPC__deref_out_ecount_part(size, length)
|
||||
#define __RPC__deref_out_ecount_full(size)
|
||||
#define __RPC__deref_out_ecount_full_string(size)
|
||||
|
||||
|
||||
// [in,out] **, second pointer decoration.
|
||||
#define __RPC__deref_inout
|
||||
#define __RPC__deref_inout_string
|
||||
#define __RPC__deref_inout_opt
|
||||
#define __RPC__deref_inout_opt_string
|
||||
#define __RPC__deref_inout_ecount_full(size)
|
||||
#define __RPC__deref_inout_ecount_full_string(size)
|
||||
#define __RPC__deref_inout_ecount_opt(size)
|
||||
#define __RPC__deref_inout_ecount_part_opt(size, length)
|
||||
#define __RPC__deref_inout_ecount_full_opt(size)
|
||||
#define __RPC__deref_inout_ecount_full_opt_string(size)
|
||||
|
||||
// #define __RPC_out_opt out_opt is not allowed in rpc
|
||||
|
||||
// [in,out,unique]
|
||||
#define __RPC__deref_opt_inout
|
||||
#define __RPC__deref_opt_inout_string
|
||||
#define __RPC__deref_opt_inout_ecount(size)
|
||||
#define __RPC__deref_opt_inout_ecount_part(size, length)
|
||||
#define __RPC__deref_opt_inout_ecount_full(size)
|
||||
#define __RPC__deref_opt_inout_ecount_full_string(size)
|
||||
|
||||
#define __RPC__deref_out_ecount_opt(size)
|
||||
#define __RPC__deref_out_ecount_part_opt(size, length)
|
||||
#define __RPC__deref_out_ecount_full_opt(size)
|
||||
#define __RPC__deref_out_ecount_full_opt_string(size)
|
||||
|
||||
#define __RPC__deref_opt_inout_opt
|
||||
#define __RPC__deref_opt_inout_opt_string
|
||||
#define __RPC__deref_opt_inout_ecount_opt(size)
|
||||
#define __RPC__deref_opt_inout_ecount_part_opt(size, length)
|
||||
#define __RPC__deref_opt_inout_ecount_full_opt(size)
|
||||
#define __RPC__deref_opt_inout_ecount_full_opt_string(size)
|
||||
|
||||
#define __RPC_full_pointer
|
||||
#define __RPC_unique_pointer
|
||||
#define __RPC_ref_pointer
|
||||
#define __RPC_string
|
||||
|
|
|
|||
|
|
@ -1,252 +1,252 @@
|
|||
#pragma once
|
||||
|
||||
#if __GNUC__ >=3
|
||||
#pragma GCC system_header
|
||||
#endif
|
||||
|
||||
/*#define __null*/ // << Conflicts with GCC internal type __null
|
||||
#define __notnull
|
||||
#define __maybenull
|
||||
#define __readonly
|
||||
#define __notreadonly
|
||||
#define __maybereadonly
|
||||
#define __valid
|
||||
#define __notvalid
|
||||
#define __maybevalid
|
||||
#define __readableTo(extent)
|
||||
#define __elem_readableTo(size)
|
||||
#define __byte_readableTo(size)
|
||||
#define __writableTo(size)
|
||||
#define __elem_writableTo(size)
|
||||
#define __byte_writableTo(size)
|
||||
#define __deref
|
||||
#define __pre
|
||||
#define __post
|
||||
#define __precond(expr)
|
||||
#define __postcond(expr)
|
||||
#define __exceptthat
|
||||
#define __execeptthat
|
||||
#define __inner_success(expr)
|
||||
#define __inner_checkReturn
|
||||
#define __inner_typefix(ctype)
|
||||
#define __inner_override
|
||||
#define __inner_callback
|
||||
#define __inner_blocksOn(resource)
|
||||
#define __inner_fallthrough_dec
|
||||
#define __inner_fallthrough
|
||||
#define __refparam
|
||||
#define __inner_control_entrypoint(category)
|
||||
#define __inner_data_entrypoint(category)
|
||||
|
||||
#define __ecount(size)
|
||||
#define __bcount(size)
|
||||
#define __in
|
||||
#define __in_ecount(size)
|
||||
#define __in_bcount(size)
|
||||
#define __in_z
|
||||
#define __in_ecount_z(size)
|
||||
#define __in_bcount_z(size)
|
||||
#define __in_nz
|
||||
#define __in_ecount_nz(size)
|
||||
#define __in_bcount_nz(size)
|
||||
#define __out
|
||||
#define __out_ecount(size)
|
||||
#define __out_bcount(size)
|
||||
#define __out_ecount_part(size,length)
|
||||
#define __out_bcount_part(size,length)
|
||||
#define __out_ecount_full(size)
|
||||
#define __out_bcount_full(size)
|
||||
#define __out_z
|
||||
#define __out_z_opt
|
||||
#define __out_ecount_z(size)
|
||||
#define __out_bcount_z(size)
|
||||
#define __out_ecount_part_z(size,length)
|
||||
#define __out_bcount_part_z(size,length)
|
||||
#define __out_ecount_full_z(size)
|
||||
#define __out_bcount_full_z(size)
|
||||
#define __out_nz
|
||||
#define __out_nz_opt
|
||||
#define __out_ecount_nz(size)
|
||||
#define __out_bcount_nz(size)
|
||||
#define __inout
|
||||
#define __inout_ecount(size)
|
||||
#define __inout_bcount(size)
|
||||
#define __inout_ecount_part(size,length)
|
||||
#define __inout_bcount_part(size,length)
|
||||
#define __inout_ecount_full(size)
|
||||
#define __inout_bcount_full(size)
|
||||
#define __inout_z
|
||||
#define __inout_ecount_z(size)
|
||||
#define __inout_bcount_z(size)
|
||||
#define __inout_nz
|
||||
#define __inout_ecount_nz(size)
|
||||
#define __inout_bcount_nz(size)
|
||||
#define __ecount_opt(size)
|
||||
#define __bcount_opt(size)
|
||||
#define __in_opt
|
||||
#define __in_ecount_opt(size)
|
||||
#define __in_bcount_opt(size)
|
||||
#define __in_z_opt
|
||||
#define __in_ecount_z_opt(size)
|
||||
#define __in_bcount_z_opt(size)
|
||||
#define __in_nz_opt
|
||||
#define __in_ecount_nz_opt(size)
|
||||
#define __in_bcount_nz_opt(size)
|
||||
#define __out_opt
|
||||
#define __out_ecount_opt(size)
|
||||
#define __out_bcount_opt(size)
|
||||
#define __out_ecount_part_opt(size,length)
|
||||
#define __out_bcount_part_opt(size,length)
|
||||
#define __out_ecount_full_opt(size)
|
||||
#define __out_bcount_full_opt(size)
|
||||
#define __out_ecount_z_opt(size)
|
||||
#define __out_bcount_z_opt(size)
|
||||
#define __out_ecount_part_z_opt(size,length)
|
||||
#define __out_bcount_part_z_opt(size,length)
|
||||
#define __out_ecount_full_z_opt(size)
|
||||
#define __out_bcount_full_z_opt(size)
|
||||
#define __out_ecount_nz_opt(size)
|
||||
#define __out_bcount_nz_opt(size)
|
||||
#define __inout_opt
|
||||
#define __inout_ecount_opt(size)
|
||||
#define __inout_bcount_opt(size)
|
||||
#define __inout_ecount_part_opt(size,length)
|
||||
#define __inout_bcount_part_opt(size,length)
|
||||
#define __inout_ecount_full_opt(size)
|
||||
#define __inout_bcount_full_opt(size)
|
||||
#define __inout_z_opt
|
||||
#define __inout_ecount_z_opt(size)
|
||||
#define __inout_ecount_z_opt(size)
|
||||
#define __inout_bcount_z_opt(size)
|
||||
#define __inout_nz_opt
|
||||
#define __inout_ecount_nz_opt(size)
|
||||
#define __inout_bcount_nz_opt(size)
|
||||
#define __deref_ecount(size)
|
||||
#define __deref_bcount(size)
|
||||
#define __deref_out
|
||||
#define __deref_out_ecount(size)
|
||||
#define __deref_out_bcount(size)
|
||||
#define __deref_out_ecount_part(size,length)
|
||||
#define __deref_out_bcount_part(size,length)
|
||||
#define __deref_out_ecount_full(size)
|
||||
#define __deref_out_bcount_full(size)
|
||||
#define __deref_out_z
|
||||
#define __deref_out_ecount_z(size)
|
||||
#define __deref_out_bcount_z(size)
|
||||
#define __deref_out_nz
|
||||
#define __deref_out_ecount_nz(size)
|
||||
#define __deref_out_bcount_nz(size)
|
||||
#define __deref_inout
|
||||
#define __deref_inout_z
|
||||
#define __deref_inout_ecount(size)
|
||||
#define __deref_inout_bcount(size)
|
||||
#define __deref_inout_ecount_part(size,length)
|
||||
#define __deref_inout_bcount_part(size,length)
|
||||
#define __deref_inout_ecount_full(size)
|
||||
#define __deref_inout_bcount_full(size)
|
||||
#define __deref_inout_z
|
||||
#define __deref_inout_ecount_z(size)
|
||||
#define __deref_inout_bcount_z(size)
|
||||
#define __deref_inout_nz
|
||||
#define __deref_inout_ecount_nz(size)
|
||||
#define __deref_inout_bcount_nz(size)
|
||||
#define __deref_ecount_opt(size)
|
||||
#define __deref_bcount_opt(size)
|
||||
#define __deref_out_opt
|
||||
#define __deref_out_ecount_opt(size)
|
||||
#define __deref_out_bcount_opt(size)
|
||||
#define __deref_out_ecount_part_opt(size,length)
|
||||
#define __deref_out_bcount_part_opt(size,length)
|
||||
#define __deref_out_ecount_full_opt(size)
|
||||
#define __deref_out_bcount_full_opt(size)
|
||||
#define __deref_out_z_opt
|
||||
#define __deref_out_ecount_z_opt(size)
|
||||
#define __deref_out_bcount_z_opt(size)
|
||||
#define __deref_out_nz_opt
|
||||
#define __deref_out_ecount_nz_opt(size)
|
||||
#define __deref_out_bcount_nz_opt(size)
|
||||
#define __deref_inout_opt
|
||||
#define __deref_inout_ecount_opt(size)
|
||||
#define __deref_inout_bcount_opt(size)
|
||||
#define __deref_inout_ecount_part_opt(size,length)
|
||||
#define __deref_inout_bcount_part_opt(size,length)
|
||||
#define __deref_inout_ecount_full_opt(size)
|
||||
#define __deref_inout_bcount_full_opt(size)
|
||||
#define __deref_inout_z_opt
|
||||
#define __deref_inout_ecount_z_opt(size)
|
||||
#define __deref_inout_bcount_z_opt(size)
|
||||
#define __deref_inout_nz_opt
|
||||
#define __deref_inout_ecount_nz_opt(size)
|
||||
#define __deref_inout_bcount_nz_opt(size)
|
||||
#define __deref_opt_ecount(size)
|
||||
#define __deref_opt_bcount(size)
|
||||
#define __deref_opt_out
|
||||
#define __deref_opt_out_z
|
||||
#define __deref_opt_out_ecount(size)
|
||||
#define __deref_opt_out_bcount(size)
|
||||
#define __deref_opt_out_ecount_part(size,length)
|
||||
#define __deref_opt_out_bcount_part(size,length)
|
||||
#define __deref_opt_out_ecount_full(size)
|
||||
#define __deref_opt_out_bcount_full(size)
|
||||
#define __deref_opt_inout
|
||||
#define __deref_opt_inout_ecount(size)
|
||||
#define __deref_opt_inout_bcount(size)
|
||||
#define __deref_opt_inout_ecount_part(size,length)
|
||||
#define __deref_opt_inout_bcount_part(size,length)
|
||||
#define __deref_opt_inout_ecount_full(size)
|
||||
#define __deref_opt_inout_bcount_full(size)
|
||||
#define __deref_opt_inout_z
|
||||
#define __deref_opt_inout_ecount_z(size)
|
||||
#define __deref_opt_inout_bcount_z(size)
|
||||
#define __deref_opt_inout_nz
|
||||
#define __deref_opt_inout_ecount_nz(size)
|
||||
#define __deref_opt_inout_bcount_nz(size)
|
||||
#define __deref_opt_ecount_opt(size)
|
||||
#define __deref_opt_bcount_opt(size)
|
||||
#define __deref_opt_out_opt
|
||||
#define __deref_opt_out_ecount_opt(size)
|
||||
#define __deref_opt_out_bcount_opt(size)
|
||||
#define __deref_opt_out_ecount_part_opt(size,length)
|
||||
#define __deref_opt_out_bcount_part_opt(size,length)
|
||||
#define __deref_opt_out_ecount_full_opt(size)
|
||||
#define __deref_opt_out_bcount_full_opt(size)
|
||||
#define __deref_opt_out_z_opt
|
||||
#define __deref_opt_out_ecount_z_opt(size)
|
||||
#define __deref_opt_out_bcount_z_opt(size)
|
||||
#define __deref_opt_out_nz_opt
|
||||
#define __deref_opt_out_ecount_nz_opt(size)
|
||||
#define __deref_opt_out_bcount_nz_opt(size)
|
||||
#define __deref_opt_inout_opt
|
||||
#define __deref_opt_inout_ecount_opt(size)
|
||||
#define __deref_opt_inout_bcount_opt(size)
|
||||
#define __deref_opt_inout_ecount_part_opt(size,length)
|
||||
#define __deref_opt_inout_bcount_part_opt(size,length)
|
||||
#define __deref_opt_inout_ecount_full_opt(size)
|
||||
#define __deref_opt_inout_bcount_full_opt(size)
|
||||
#define __deref_opt_inout_z_opt
|
||||
#define __deref_opt_inout_ecount_z_opt(size)
|
||||
#define __deref_opt_inout_bcount_z_opt(size)
|
||||
#define __deref_opt_inout_nz_opt
|
||||
#define __deref_opt_inout_ecount_nz_opt(size)
|
||||
#define __deref_opt_inout_bcount_nz_opt(size)
|
||||
|
||||
#define __success(expr)
|
||||
#define __nullterminated
|
||||
#define __nullnullterminated
|
||||
#define __reserved
|
||||
#define __checkReturn
|
||||
#define __typefix(ctype)
|
||||
#define __override
|
||||
#define __callback
|
||||
#define __format_string
|
||||
#define __blocksOn(resource)
|
||||
#define __control_entrypoint(category)
|
||||
#define __data_entrypoint(category)
|
||||
|
||||
#ifndef __fallthrough
|
||||
#define __fallthrough __inner_fallthrough
|
||||
#endif
|
||||
|
||||
#ifndef __analysis_assume
|
||||
#define __analysis_assume(expr)
|
||||
#endif
|
||||
#pragma once
|
||||
|
||||
#if __GNUC__ >=3
|
||||
#pragma GCC system_header
|
||||
#endif
|
||||
|
||||
/*#define __null*/ // << Conflicts with GCC internal type __null
|
||||
#define __notnull
|
||||
#define __maybenull
|
||||
#define __readonly
|
||||
#define __notreadonly
|
||||
#define __maybereadonly
|
||||
#define __valid
|
||||
#define __notvalid
|
||||
#define __maybevalid
|
||||
#define __readableTo(extent)
|
||||
#define __elem_readableTo(size)
|
||||
#define __byte_readableTo(size)
|
||||
#define __writableTo(size)
|
||||
#define __elem_writableTo(size)
|
||||
#define __byte_writableTo(size)
|
||||
#define __deref
|
||||
#define __pre
|
||||
#define __post
|
||||
#define __precond(expr)
|
||||
#define __postcond(expr)
|
||||
#define __exceptthat
|
||||
#define __execeptthat
|
||||
#define __inner_success(expr)
|
||||
#define __inner_checkReturn
|
||||
#define __inner_typefix(ctype)
|
||||
#define __inner_override
|
||||
#define __inner_callback
|
||||
#define __inner_blocksOn(resource)
|
||||
#define __inner_fallthrough_dec
|
||||
#define __inner_fallthrough
|
||||
#define __refparam
|
||||
#define __inner_control_entrypoint(category)
|
||||
#define __inner_data_entrypoint(category)
|
||||
|
||||
#define __ecount(size)
|
||||
#define __bcount(size)
|
||||
#define __in
|
||||
#define __in_ecount(size)
|
||||
#define __in_bcount(size)
|
||||
#define __in_z
|
||||
#define __in_ecount_z(size)
|
||||
#define __in_bcount_z(size)
|
||||
#define __in_nz
|
||||
#define __in_ecount_nz(size)
|
||||
#define __in_bcount_nz(size)
|
||||
#define __out
|
||||
#define __out_ecount(size)
|
||||
#define __out_bcount(size)
|
||||
#define __out_ecount_part(size,length)
|
||||
#define __out_bcount_part(size,length)
|
||||
#define __out_ecount_full(size)
|
||||
#define __out_bcount_full(size)
|
||||
#define __out_z
|
||||
#define __out_z_opt
|
||||
#define __out_ecount_z(size)
|
||||
#define __out_bcount_z(size)
|
||||
#define __out_ecount_part_z(size,length)
|
||||
#define __out_bcount_part_z(size,length)
|
||||
#define __out_ecount_full_z(size)
|
||||
#define __out_bcount_full_z(size)
|
||||
#define __out_nz
|
||||
#define __out_nz_opt
|
||||
#define __out_ecount_nz(size)
|
||||
#define __out_bcount_nz(size)
|
||||
#define __inout
|
||||
#define __inout_ecount(size)
|
||||
#define __inout_bcount(size)
|
||||
#define __inout_ecount_part(size,length)
|
||||
#define __inout_bcount_part(size,length)
|
||||
#define __inout_ecount_full(size)
|
||||
#define __inout_bcount_full(size)
|
||||
#define __inout_z
|
||||
#define __inout_ecount_z(size)
|
||||
#define __inout_bcount_z(size)
|
||||
#define __inout_nz
|
||||
#define __inout_ecount_nz(size)
|
||||
#define __inout_bcount_nz(size)
|
||||
#define __ecount_opt(size)
|
||||
#define __bcount_opt(size)
|
||||
#define __in_opt
|
||||
#define __in_ecount_opt(size)
|
||||
#define __in_bcount_opt(size)
|
||||
#define __in_z_opt
|
||||
#define __in_ecount_z_opt(size)
|
||||
#define __in_bcount_z_opt(size)
|
||||
#define __in_nz_opt
|
||||
#define __in_ecount_nz_opt(size)
|
||||
#define __in_bcount_nz_opt(size)
|
||||
#define __out_opt
|
||||
#define __out_ecount_opt(size)
|
||||
#define __out_bcount_opt(size)
|
||||
#define __out_ecount_part_opt(size,length)
|
||||
#define __out_bcount_part_opt(size,length)
|
||||
#define __out_ecount_full_opt(size)
|
||||
#define __out_bcount_full_opt(size)
|
||||
#define __out_ecount_z_opt(size)
|
||||
#define __out_bcount_z_opt(size)
|
||||
#define __out_ecount_part_z_opt(size,length)
|
||||
#define __out_bcount_part_z_opt(size,length)
|
||||
#define __out_ecount_full_z_opt(size)
|
||||
#define __out_bcount_full_z_opt(size)
|
||||
#define __out_ecount_nz_opt(size)
|
||||
#define __out_bcount_nz_opt(size)
|
||||
#define __inout_opt
|
||||
#define __inout_ecount_opt(size)
|
||||
#define __inout_bcount_opt(size)
|
||||
#define __inout_ecount_part_opt(size,length)
|
||||
#define __inout_bcount_part_opt(size,length)
|
||||
#define __inout_ecount_full_opt(size)
|
||||
#define __inout_bcount_full_opt(size)
|
||||
#define __inout_z_opt
|
||||
#define __inout_ecount_z_opt(size)
|
||||
#define __inout_ecount_z_opt(size)
|
||||
#define __inout_bcount_z_opt(size)
|
||||
#define __inout_nz_opt
|
||||
#define __inout_ecount_nz_opt(size)
|
||||
#define __inout_bcount_nz_opt(size)
|
||||
#define __deref_ecount(size)
|
||||
#define __deref_bcount(size)
|
||||
#define __deref_out
|
||||
#define __deref_out_ecount(size)
|
||||
#define __deref_out_bcount(size)
|
||||
#define __deref_out_ecount_part(size,length)
|
||||
#define __deref_out_bcount_part(size,length)
|
||||
#define __deref_out_ecount_full(size)
|
||||
#define __deref_out_bcount_full(size)
|
||||
#define __deref_out_z
|
||||
#define __deref_out_ecount_z(size)
|
||||
#define __deref_out_bcount_z(size)
|
||||
#define __deref_out_nz
|
||||
#define __deref_out_ecount_nz(size)
|
||||
#define __deref_out_bcount_nz(size)
|
||||
#define __deref_inout
|
||||
#define __deref_inout_z
|
||||
#define __deref_inout_ecount(size)
|
||||
#define __deref_inout_bcount(size)
|
||||
#define __deref_inout_ecount_part(size,length)
|
||||
#define __deref_inout_bcount_part(size,length)
|
||||
#define __deref_inout_ecount_full(size)
|
||||
#define __deref_inout_bcount_full(size)
|
||||
#define __deref_inout_z
|
||||
#define __deref_inout_ecount_z(size)
|
||||
#define __deref_inout_bcount_z(size)
|
||||
#define __deref_inout_nz
|
||||
#define __deref_inout_ecount_nz(size)
|
||||
#define __deref_inout_bcount_nz(size)
|
||||
#define __deref_ecount_opt(size)
|
||||
#define __deref_bcount_opt(size)
|
||||
#define __deref_out_opt
|
||||
#define __deref_out_ecount_opt(size)
|
||||
#define __deref_out_bcount_opt(size)
|
||||
#define __deref_out_ecount_part_opt(size,length)
|
||||
#define __deref_out_bcount_part_opt(size,length)
|
||||
#define __deref_out_ecount_full_opt(size)
|
||||
#define __deref_out_bcount_full_opt(size)
|
||||
#define __deref_out_z_opt
|
||||
#define __deref_out_ecount_z_opt(size)
|
||||
#define __deref_out_bcount_z_opt(size)
|
||||
#define __deref_out_nz_opt
|
||||
#define __deref_out_ecount_nz_opt(size)
|
||||
#define __deref_out_bcount_nz_opt(size)
|
||||
#define __deref_inout_opt
|
||||
#define __deref_inout_ecount_opt(size)
|
||||
#define __deref_inout_bcount_opt(size)
|
||||
#define __deref_inout_ecount_part_opt(size,length)
|
||||
#define __deref_inout_bcount_part_opt(size,length)
|
||||
#define __deref_inout_ecount_full_opt(size)
|
||||
#define __deref_inout_bcount_full_opt(size)
|
||||
#define __deref_inout_z_opt
|
||||
#define __deref_inout_ecount_z_opt(size)
|
||||
#define __deref_inout_bcount_z_opt(size)
|
||||
#define __deref_inout_nz_opt
|
||||
#define __deref_inout_ecount_nz_opt(size)
|
||||
#define __deref_inout_bcount_nz_opt(size)
|
||||
#define __deref_opt_ecount(size)
|
||||
#define __deref_opt_bcount(size)
|
||||
#define __deref_opt_out
|
||||
#define __deref_opt_out_z
|
||||
#define __deref_opt_out_ecount(size)
|
||||
#define __deref_opt_out_bcount(size)
|
||||
#define __deref_opt_out_ecount_part(size,length)
|
||||
#define __deref_opt_out_bcount_part(size,length)
|
||||
#define __deref_opt_out_ecount_full(size)
|
||||
#define __deref_opt_out_bcount_full(size)
|
||||
#define __deref_opt_inout
|
||||
#define __deref_opt_inout_ecount(size)
|
||||
#define __deref_opt_inout_bcount(size)
|
||||
#define __deref_opt_inout_ecount_part(size,length)
|
||||
#define __deref_opt_inout_bcount_part(size,length)
|
||||
#define __deref_opt_inout_ecount_full(size)
|
||||
#define __deref_opt_inout_bcount_full(size)
|
||||
#define __deref_opt_inout_z
|
||||
#define __deref_opt_inout_ecount_z(size)
|
||||
#define __deref_opt_inout_bcount_z(size)
|
||||
#define __deref_opt_inout_nz
|
||||
#define __deref_opt_inout_ecount_nz(size)
|
||||
#define __deref_opt_inout_bcount_nz(size)
|
||||
#define __deref_opt_ecount_opt(size)
|
||||
#define __deref_opt_bcount_opt(size)
|
||||
#define __deref_opt_out_opt
|
||||
#define __deref_opt_out_ecount_opt(size)
|
||||
#define __deref_opt_out_bcount_opt(size)
|
||||
#define __deref_opt_out_ecount_part_opt(size,length)
|
||||
#define __deref_opt_out_bcount_part_opt(size,length)
|
||||
#define __deref_opt_out_ecount_full_opt(size)
|
||||
#define __deref_opt_out_bcount_full_opt(size)
|
||||
#define __deref_opt_out_z_opt
|
||||
#define __deref_opt_out_ecount_z_opt(size)
|
||||
#define __deref_opt_out_bcount_z_opt(size)
|
||||
#define __deref_opt_out_nz_opt
|
||||
#define __deref_opt_out_ecount_nz_opt(size)
|
||||
#define __deref_opt_out_bcount_nz_opt(size)
|
||||
#define __deref_opt_inout_opt
|
||||
#define __deref_opt_inout_ecount_opt(size)
|
||||
#define __deref_opt_inout_bcount_opt(size)
|
||||
#define __deref_opt_inout_ecount_part_opt(size,length)
|
||||
#define __deref_opt_inout_bcount_part_opt(size,length)
|
||||
#define __deref_opt_inout_ecount_full_opt(size)
|
||||
#define __deref_opt_inout_bcount_full_opt(size)
|
||||
#define __deref_opt_inout_z_opt
|
||||
#define __deref_opt_inout_ecount_z_opt(size)
|
||||
#define __deref_opt_inout_bcount_z_opt(size)
|
||||
#define __deref_opt_inout_nz_opt
|
||||
#define __deref_opt_inout_ecount_nz_opt(size)
|
||||
#define __deref_opt_inout_bcount_nz_opt(size)
|
||||
|
||||
#define __success(expr)
|
||||
#define __nullterminated
|
||||
#define __nullnullterminated
|
||||
#define __reserved
|
||||
#define __checkReturn
|
||||
#define __typefix(ctype)
|
||||
#define __override
|
||||
#define __callback
|
||||
#define __format_string
|
||||
#define __blocksOn(resource)
|
||||
#define __control_entrypoint(category)
|
||||
#define __data_entrypoint(category)
|
||||
|
||||
#ifndef __fallthrough
|
||||
#define __fallthrough __inner_fallthrough
|
||||
#endif
|
||||
|
||||
#ifndef __analysis_assume
|
||||
#define __analysis_assume(expr)
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,225 +1,225 @@
|
|||
/*
|
||||
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
|
||||
Module Name:
|
||||
|
||||
sdkddkver.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Master include file for versioning windows SDK/DDK.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _INC_SDKDDKVER
|
||||
#define _INC_SDKDDKVER
|
||||
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// _WIN32_WINNT version constants
|
||||
//
|
||||
#define _WIN32_WINNT_NT4 0x0400
|
||||
#define _WIN32_WINNT_WIN2K 0x0500
|
||||
#define _WIN32_WINNT_WINXP 0x0501
|
||||
#define _WIN32_WINNT_WS03 0x0502
|
||||
#define _WIN32_WINNT_LONGHORN 0x0600
|
||||
|
||||
//
|
||||
// _WIN32_IE_ version constants
|
||||
//
|
||||
#define _WIN32_IE_IE20 0x0200
|
||||
#define _WIN32_IE_IE30 0x0300
|
||||
#define _WIN32_IE_IE302 0x0302
|
||||
#define _WIN32_IE_IE40 0x0400
|
||||
#define _WIN32_IE_IE401 0x0401
|
||||
#define _WIN32_IE_IE50 0x0500
|
||||
#define _WIN32_IE_IE501 0x0501
|
||||
#define _WIN32_IE_IE55 0x0550
|
||||
#define _WIN32_IE_IE60 0x0600
|
||||
#define _WIN32_IE_IE60SP1 0x0601
|
||||
#define _WIN32_IE_IE60SP2 0x0603
|
||||
#define _WIN32_IE_IE70 0x0700
|
||||
|
||||
//
|
||||
// IE <-> OS version mapping
|
||||
//
|
||||
// NT4 supports IE versions 2.0 -> 6.0 SP1
|
||||
#define _WIN32_IE_NT4 _WIN32_IE_IE20
|
||||
#define _WIN32_IE_NT4SP1 _WIN32_IE_IE20
|
||||
#define _WIN32_IE_NT4SP2 _WIN32_IE_IE20
|
||||
#define _WIN32_IE_NT4SP3 _WIN32_IE_IE302
|
||||
#define _WIN32_IE_NT4SP4 _WIN32_IE_IE401
|
||||
#define _WIN32_IE_NT4SP5 _WIN32_IE_IE401
|
||||
#define _WIN32_IE_NT4SP6 _WIN32_IE_IE50
|
||||
// Win98 supports IE versions 4.01 -> 6.0 SP1
|
||||
#define _WIN32_IE_WIN98 _WIN32_IE_IE401
|
||||
// Win98SE supports IE versions 5.0 -> 6.0 SP1
|
||||
#define _WIN32_IE_WIN98SE _WIN32_IE_IE50
|
||||
// WinME supports IE versions 5.5 -> 6.0 SP1
|
||||
#define _WIN32_IE_WINME _WIN32_IE_IE55
|
||||
// Win2k supports IE versions 5.01 -> 6.0 SP1
|
||||
#define _WIN32_IE_WIN2K _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP1 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP2 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP3 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP4 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_XP _WIN32_IE_IE60
|
||||
#define _WIN32_IE_XPSP1 _WIN32_IE_IE60SP1
|
||||
#define _WIN32_IE_XPSP2 _WIN32_IE_IE60SP2
|
||||
#define _WIN32_IE_WS03 0x0602
|
||||
#define _WIN32_IE_WS03SP1 _WIN32_IE_IE60SP2
|
||||
#define _WIN32_IE_LONGHORN _WIN32_IE_IE70
|
||||
|
||||
|
||||
//
|
||||
// NTDDI version constants
|
||||
//
|
||||
#define NTDDI_WIN2K 0x05000000
|
||||
#define NTDDI_WIN2KSP1 0x05000100
|
||||
#define NTDDI_WIN2KSP2 0x05000200
|
||||
#define NTDDI_WIN2KSP3 0x05000300
|
||||
#define NTDDI_WIN2KSP4 0x05000400
|
||||
|
||||
#define NTDDI_WINXP 0x05010000
|
||||
#define NTDDI_WINXPSP1 0x05010100
|
||||
#define NTDDI_WINXPSP2 0x05010200
|
||||
|
||||
#define NTDDI_WS03 0x05020000
|
||||
#define NTDDI_WS03SP1 0x05020100
|
||||
|
||||
#define NTDDI_LONGHORN 0x06000000
|
||||
|
||||
//
|
||||
// masks for version macros
|
||||
//
|
||||
#define OSVERSION_MASK 0xFFFF0000
|
||||
#define SPVERSION_MASK 0x0000FF00
|
||||
#define SUBVERSION_MASK 0x000000FF
|
||||
|
||||
|
||||
//
|
||||
// macros to extract various version fields from the NTDDI version
|
||||
//
|
||||
#define OSVER(Version) ((Version) & OSVERSION_MASK)
|
||||
#define SPVER(Version) (((Version) & SPVERSION_MASK) >> 8)
|
||||
#define SUBVER(Version) (((Version) & SUBVERSION_MASK) )
|
||||
|
||||
|
||||
#if defined(DECLSPEC_DEPRECATED_DDK)
|
||||
|
||||
// deprecate in 2k or later
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN2K)
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2K DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2K
|
||||
#endif
|
||||
|
||||
// deprecate in XP or later
|
||||
#if (NTDDI_VERSION >= NTDDI_WINXP)
|
||||
#define DECLSPEC_DEPRECATED_DDK_WINXP DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_WINXP
|
||||
#endif
|
||||
|
||||
// deprecate in WS03 or later
|
||||
#if (NTDDI_VERSION >= NTDDI_WS03)
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2003 DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2003
|
||||
#endif
|
||||
|
||||
// deprecate in WS03 or later
|
||||
#if (NTDDI_VERSION >= NTDDI_LONGHORN)
|
||||
#define DECLSPEC_DEPRECATED_DDK_LONGHORN DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_LONGHORN
|
||||
#endif
|
||||
|
||||
#endif // defined(DECLSPEC_DEPRECATED_DDK)
|
||||
|
||||
|
||||
//
|
||||
// if versions aren't already defined, default to most current
|
||||
//
|
||||
|
||||
#define NTDDI_VERSION_FROM_WIN32_WINNT2(ver) ver##0000
|
||||
#define NTDDI_VERSION_FROM_WIN32_WINNT(ver) NTDDI_VERSION_FROM_WIN32_WINNT2(ver)
|
||||
|
||||
#if !defined(_WIN32_WINNT) && !defined(_CHICAGO_)
|
||||
#define _WIN32_WINNT 0x0600
|
||||
#endif
|
||||
|
||||
#ifndef NTDDI_VERSION
|
||||
#ifdef _WIN32_WINNT
|
||||
// set NTDDI_VERSION based on _WIN32_WINNT
|
||||
#define NTDDI_VERSION NTDDI_VERSION_FROM_WIN32_WINNT(_WIN32_WINNT)
|
||||
#else
|
||||
#define NTDDI_VERSION 0x06000000
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef WINVER
|
||||
#ifdef _WIN32_WINNT
|
||||
// set WINVER based on _WIN32_WINNT
|
||||
#define WINVER _WIN32_WINNT
|
||||
#else
|
||||
#define WINVER 0x0600
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32_IE
|
||||
#ifdef _WIN32_WINNT
|
||||
// set _WIN32_IE based on _WIN32_WINNT
|
||||
#if (_WIN32_WINNT <= _WIN32_WINNT_NT4)
|
||||
#define _WIN32_IE _WIN32_IE_IE50
|
||||
#elif (_WIN32_WINNT <= _WIN32_WINNT_WIN2K)
|
||||
#define _WIN32_IE _WIN32_IE_IE501
|
||||
#elif (_WIN32_WINNT <= _WIN32_WINNT_WINXP)
|
||||
#define _WIN32_IE _WIN32_IE_IE60
|
||||
#elif (_WIN32_WINNT <= _WIN32_WINNT_WS03)
|
||||
#define _WIN32_IE 0x0602
|
||||
#else
|
||||
#define _WIN32_IE 0x0700
|
||||
#endif
|
||||
#else
|
||||
#define _WIN32_IE 0x0700
|
||||
#endif
|
||||
#endif
|
||||
|
||||
//
|
||||
// Sanity check for compatible versions
|
||||
//
|
||||
#if defined(_WIN32_WINNT) && !defined(MIDL_PASS) && !defined(RC_INVOKED)
|
||||
|
||||
#if (defined(WINVER) && (WINVER < 0x0400) && (_WIN32_WINNT > 0x0400))
|
||||
#error WINVER setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_WIN2K) && (_WIN32_WINNT != _WIN32_WINNT_WIN2K))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_WINXP) && (_WIN32_WINNT != _WIN32_WINNT_WINXP))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_WS03) && (_WIN32_WINNT != _WIN32_WINNT_WS03))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_LONGHORN) && (_WIN32_WINNT != _WIN32_WINNT_LONGHORN))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if ((_WIN32_WINNT < _WIN32_WINNT_WIN2K) && (_WIN32_IE > _WIN32_IE_IE60SP1))
|
||||
#error _WIN32_WINNT settings conflicts with _WIN32_IE setting
|
||||
#endif
|
||||
|
||||
#endif // defined(_WIN32_WINNT) && !defined(MIDL_PASS) && !defined(_WINRESRC_)
|
||||
|
||||
|
||||
#endif // !_INC_SDKDDKVER
|
||||
|
||||
|
||||
/*
|
||||
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
|
||||
Module Name:
|
||||
|
||||
sdkddkver.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Master include file for versioning windows SDK/DDK.
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _INC_SDKDDKVER
|
||||
#define _INC_SDKDDKVER
|
||||
|
||||
#pragma once
|
||||
|
||||
//
|
||||
// _WIN32_WINNT version constants
|
||||
//
|
||||
#define _WIN32_WINNT_NT4 0x0400
|
||||
#define _WIN32_WINNT_WIN2K 0x0500
|
||||
#define _WIN32_WINNT_WINXP 0x0501
|
||||
#define _WIN32_WINNT_WS03 0x0502
|
||||
#define _WIN32_WINNT_LONGHORN 0x0600
|
||||
|
||||
//
|
||||
// _WIN32_IE_ version constants
|
||||
//
|
||||
#define _WIN32_IE_IE20 0x0200
|
||||
#define _WIN32_IE_IE30 0x0300
|
||||
#define _WIN32_IE_IE302 0x0302
|
||||
#define _WIN32_IE_IE40 0x0400
|
||||
#define _WIN32_IE_IE401 0x0401
|
||||
#define _WIN32_IE_IE50 0x0500
|
||||
#define _WIN32_IE_IE501 0x0501
|
||||
#define _WIN32_IE_IE55 0x0550
|
||||
#define _WIN32_IE_IE60 0x0600
|
||||
#define _WIN32_IE_IE60SP1 0x0601
|
||||
#define _WIN32_IE_IE60SP2 0x0603
|
||||
#define _WIN32_IE_IE70 0x0700
|
||||
|
||||
//
|
||||
// IE <-> OS version mapping
|
||||
//
|
||||
// NT4 supports IE versions 2.0 -> 6.0 SP1
|
||||
#define _WIN32_IE_NT4 _WIN32_IE_IE20
|
||||
#define _WIN32_IE_NT4SP1 _WIN32_IE_IE20
|
||||
#define _WIN32_IE_NT4SP2 _WIN32_IE_IE20
|
||||
#define _WIN32_IE_NT4SP3 _WIN32_IE_IE302
|
||||
#define _WIN32_IE_NT4SP4 _WIN32_IE_IE401
|
||||
#define _WIN32_IE_NT4SP5 _WIN32_IE_IE401
|
||||
#define _WIN32_IE_NT4SP6 _WIN32_IE_IE50
|
||||
// Win98 supports IE versions 4.01 -> 6.0 SP1
|
||||
#define _WIN32_IE_WIN98 _WIN32_IE_IE401
|
||||
// Win98SE supports IE versions 5.0 -> 6.0 SP1
|
||||
#define _WIN32_IE_WIN98SE _WIN32_IE_IE50
|
||||
// WinME supports IE versions 5.5 -> 6.0 SP1
|
||||
#define _WIN32_IE_WINME _WIN32_IE_IE55
|
||||
// Win2k supports IE versions 5.01 -> 6.0 SP1
|
||||
#define _WIN32_IE_WIN2K _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP1 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP2 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP3 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_WIN2KSP4 _WIN32_IE_IE501
|
||||
#define _WIN32_IE_XP _WIN32_IE_IE60
|
||||
#define _WIN32_IE_XPSP1 _WIN32_IE_IE60SP1
|
||||
#define _WIN32_IE_XPSP2 _WIN32_IE_IE60SP2
|
||||
#define _WIN32_IE_WS03 0x0602
|
||||
#define _WIN32_IE_WS03SP1 _WIN32_IE_IE60SP2
|
||||
#define _WIN32_IE_LONGHORN _WIN32_IE_IE70
|
||||
|
||||
|
||||
//
|
||||
// NTDDI version constants
|
||||
//
|
||||
#define NTDDI_WIN2K 0x05000000
|
||||
#define NTDDI_WIN2KSP1 0x05000100
|
||||
#define NTDDI_WIN2KSP2 0x05000200
|
||||
#define NTDDI_WIN2KSP3 0x05000300
|
||||
#define NTDDI_WIN2KSP4 0x05000400
|
||||
|
||||
#define NTDDI_WINXP 0x05010000
|
||||
#define NTDDI_WINXPSP1 0x05010100
|
||||
#define NTDDI_WINXPSP2 0x05010200
|
||||
|
||||
#define NTDDI_WS03 0x05020000
|
||||
#define NTDDI_WS03SP1 0x05020100
|
||||
|
||||
#define NTDDI_LONGHORN 0x06000000
|
||||
|
||||
//
|
||||
// masks for version macros
|
||||
//
|
||||
#define OSVERSION_MASK 0xFFFF0000
|
||||
#define SPVERSION_MASK 0x0000FF00
|
||||
#define SUBVERSION_MASK 0x000000FF
|
||||
|
||||
|
||||
//
|
||||
// macros to extract various version fields from the NTDDI version
|
||||
//
|
||||
#define OSVER(Version) ((Version) & OSVERSION_MASK)
|
||||
#define SPVER(Version) (((Version) & SPVERSION_MASK) >> 8)
|
||||
#define SUBVER(Version) (((Version) & SUBVERSION_MASK) )
|
||||
|
||||
|
||||
#if defined(DECLSPEC_DEPRECATED_DDK)
|
||||
|
||||
// deprecate in 2k or later
|
||||
#if (NTDDI_VERSION >= NTDDI_WIN2K)
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2K DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2K
|
||||
#endif
|
||||
|
||||
// deprecate in XP or later
|
||||
#if (NTDDI_VERSION >= NTDDI_WINXP)
|
||||
#define DECLSPEC_DEPRECATED_DDK_WINXP DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_WINXP
|
||||
#endif
|
||||
|
||||
// deprecate in WS03 or later
|
||||
#if (NTDDI_VERSION >= NTDDI_WS03)
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2003 DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_WIN2003
|
||||
#endif
|
||||
|
||||
// deprecate in WS03 or later
|
||||
#if (NTDDI_VERSION >= NTDDI_LONGHORN)
|
||||
#define DECLSPEC_DEPRECATED_DDK_LONGHORN DECLSPEC_DEPRECATED_DDK
|
||||
#else
|
||||
#define DECLSPEC_DEPRECATED_DDK_LONGHORN
|
||||
#endif
|
||||
|
||||
#endif // defined(DECLSPEC_DEPRECATED_DDK)
|
||||
|
||||
|
||||
//
|
||||
// if versions aren't already defined, default to most current
|
||||
//
|
||||
|
||||
#define NTDDI_VERSION_FROM_WIN32_WINNT2(ver) ver##0000
|
||||
#define NTDDI_VERSION_FROM_WIN32_WINNT(ver) NTDDI_VERSION_FROM_WIN32_WINNT2(ver)
|
||||
|
||||
#if !defined(_WIN32_WINNT) && !defined(_CHICAGO_)
|
||||
#define _WIN32_WINNT 0x0600
|
||||
#endif
|
||||
|
||||
#ifndef NTDDI_VERSION
|
||||
#ifdef _WIN32_WINNT
|
||||
// set NTDDI_VERSION based on _WIN32_WINNT
|
||||
#define NTDDI_VERSION NTDDI_VERSION_FROM_WIN32_WINNT(_WIN32_WINNT)
|
||||
#else
|
||||
#define NTDDI_VERSION 0x06000000
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef WINVER
|
||||
#ifdef _WIN32_WINNT
|
||||
// set WINVER based on _WIN32_WINNT
|
||||
#define WINVER _WIN32_WINNT
|
||||
#else
|
||||
#define WINVER 0x0600
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32_IE
|
||||
#ifdef _WIN32_WINNT
|
||||
// set _WIN32_IE based on _WIN32_WINNT
|
||||
#if (_WIN32_WINNT <= _WIN32_WINNT_NT4)
|
||||
#define _WIN32_IE _WIN32_IE_IE50
|
||||
#elif (_WIN32_WINNT <= _WIN32_WINNT_WIN2K)
|
||||
#define _WIN32_IE _WIN32_IE_IE501
|
||||
#elif (_WIN32_WINNT <= _WIN32_WINNT_WINXP)
|
||||
#define _WIN32_IE _WIN32_IE_IE60
|
||||
#elif (_WIN32_WINNT <= _WIN32_WINNT_WS03)
|
||||
#define _WIN32_IE 0x0602
|
||||
#else
|
||||
#define _WIN32_IE 0x0700
|
||||
#endif
|
||||
#else
|
||||
#define _WIN32_IE 0x0700
|
||||
#endif
|
||||
#endif
|
||||
|
||||
//
|
||||
// Sanity check for compatible versions
|
||||
//
|
||||
#if defined(_WIN32_WINNT) && !defined(MIDL_PASS) && !defined(RC_INVOKED)
|
||||
|
||||
#if (defined(WINVER) && (WINVER < 0x0400) && (_WIN32_WINNT > 0x0400))
|
||||
#error WINVER setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_WIN2K) && (_WIN32_WINNT != _WIN32_WINNT_WIN2K))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_WINXP) && (_WIN32_WINNT != _WIN32_WINNT_WINXP))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_WS03) && (_WIN32_WINNT != _WIN32_WINNT_WS03))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if (((OSVERSION_MASK & NTDDI_VERSION) == NTDDI_LONGHORN) && (_WIN32_WINNT != _WIN32_WINNT_LONGHORN))
|
||||
#error NTDDI_VERSION setting conflicts with _WIN32_WINNT setting
|
||||
#endif
|
||||
|
||||
#if ((_WIN32_WINNT < _WIN32_WINNT_WIN2K) && (_WIN32_IE > _WIN32_IE_IE60SP1))
|
||||
#error _WIN32_WINNT settings conflicts with _WIN32_IE setting
|
||||
#endif
|
||||
|
||||
#endif // defined(_WIN32_WINNT) && !defined(MIDL_PASS) && !defined(_WINRESRC_)
|
||||
|
||||
|
||||
#endif // !_INC_SDKDDKVER
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,468 +1,468 @@
|
|||
|
||||
|
||||
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
|
||||
|
||||
|
||||
/* File created by MIDL compiler version 7.00.0499 */
|
||||
/* Compiler settings for shtypes.idl:
|
||||
Oicf, W1, Zp8, env=Win32 (32b run)
|
||||
protocol : dce , ms_ext, c_ext, robust
|
||||
error checks: allocation ref bounds_check enum stub_data
|
||||
VC __declspec() decoration level:
|
||||
__declspec(uuid()), __declspec(selectany), __declspec(novtable)
|
||||
DECLSPEC_UUID(), MIDL_INTERFACE()
|
||||
*/
|
||||
//@@MIDL_FILE_HEADING( )
|
||||
|
||||
#pragma warning( disable: 4049 ) /* more than 64k source lines */
|
||||
|
||||
|
||||
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||
#endif
|
||||
|
||||
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||
#endif
|
||||
|
||||
#include "rpc.h"
|
||||
#include "rpcndr.h"
|
||||
|
||||
#ifndef __RPCNDR_H_VERSION__
|
||||
#error this stub requires an updated version of <rpcndr.h>
|
||||
#endif // __RPCNDR_H_VERSION__
|
||||
|
||||
|
||||
#ifndef __shtypes_h__
|
||||
#define __shtypes_h__
|
||||
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||
#pragma once
|
||||
#endif
|
||||
|
||||
/* Forward Declarations */
|
||||
|
||||
/* header files for imported files */
|
||||
#include "wtypes.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"{
|
||||
#endif
|
||||
|
||||
|
||||
/* interface __MIDL_itf_shtypes_0000_0000 */
|
||||
/* [local] */
|
||||
|
||||
//+-------------------------------------------------------------------------
|
||||
//
|
||||
// Microsoft Windows
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
//
|
||||
//--------------------------------------------------------------------------
|
||||
//===========================================================================
|
||||
//
|
||||
// Object identifiers in the explorer's name space (ItemID and IDList)
|
||||
//
|
||||
// All the items that the user can browse with the explorer (such as files,
|
||||
// directories, servers, work-groups, etc.) has an identifier which is unique
|
||||
// among items within the parent folder. Those identifiers are called item
|
||||
// IDs (SHITEMID). Since all its parent folders have their own item IDs,
|
||||
// any items can be uniquely identified by a list of item IDs, which is called
|
||||
// an ID list (ITEMIDLIST).
|
||||
//
|
||||
// ID lists are almost always allocated by the task allocator (see some
|
||||
// description below as well as OLE 2.0 SDK) and may be passed across
|
||||
// some of shell interfaces (such as IShellFolder). Each item ID in an ID list
|
||||
// is only meaningful to its parent folder (which has generated it), and all
|
||||
// the clients must treat it as an opaque binary data except the first two
|
||||
// bytes, which indicates the size of the item ID.
|
||||
//
|
||||
// When a shell extension -- which implements the IShellFolder interace --
|
||||
// generates an item ID, it may put any information in it, not only the data
|
||||
// with that it needs to identifies the item, but also some additional
|
||||
// information, which would help implementing some other functions efficiently.
|
||||
// For example, the shell's IShellFolder implementation of file system items
|
||||
// stores the primary (long) name of a file or a directory as the item
|
||||
// identifier, but it also stores its alternative (short) name, size and date
|
||||
// etc.
|
||||
//
|
||||
// When an ID list is passed to one of shell APIs (such as SHGetPathFromIDList),
|
||||
// it is always an absolute path -- relative from the root of the name space,
|
||||
// which is the desktop folder. When an ID list is passed to one of IShellFolder
|
||||
// member function, it is always a relative path from the folder (unless it
|
||||
// is explicitly specified).
|
||||
//
|
||||
//===========================================================================
|
||||
//
|
||||
// SHITEMID -- Item ID (mkid)
|
||||
// USHORT cb; // Size of the ID (including cb itself)
|
||||
// BYTE abID[]; // The item ID (variable length)
|
||||
//
|
||||
#include <pshpack1.h>
|
||||
typedef struct _SHITEMID
|
||||
{
|
||||
USHORT cb;
|
||||
BYTE abID[ 1 ];
|
||||
} SHITEMID;
|
||||
|
||||
#include <poppack.h>
|
||||
#if defined(_M_IX86)
|
||||
#define __unaligned
|
||||
#endif // __unaligned
|
||||
typedef SHITEMID __unaligned *LPSHITEMID;
|
||||
|
||||
typedef const SHITEMID __unaligned *LPCSHITEMID;
|
||||
|
||||
//
|
||||
// ITEMIDLIST -- List if item IDs (combined with 0-terminator)
|
||||
//
|
||||
#include <pshpack1.h>
|
||||
typedef struct _ITEMIDLIST
|
||||
{
|
||||
SHITEMID mkid;
|
||||
} ITEMIDLIST;
|
||||
|
||||
#if defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
typedef struct _ITEMIDLIST_RELATIVE : ITEMIDLIST {} ITEMIDLIST_RELATIVE;
|
||||
typedef struct _ITEMID_CHILD : ITEMIDLIST_RELATIVE {} ITEMID_CHILD;
|
||||
typedef struct _ITEMIDLIST_ABSOLUTE : ITEMIDLIST_RELATIVE {} ITEMIDLIST_ABSOLUTE;
|
||||
#else // !(defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus))
|
||||
typedef ITEMIDLIST ITEMIDLIST_RELATIVE;
|
||||
|
||||
typedef ITEMIDLIST ITEMID_CHILD;
|
||||
|
||||
typedef ITEMIDLIST ITEMIDLIST_ABSOLUTE;
|
||||
|
||||
#endif // defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
#include <poppack.h>
|
||||
typedef /* [unique] */ __RPC_unique_pointer BYTE_BLOB *wirePIDL;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST __unaligned *LPITEMIDLIST;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST __unaligned *LPCITEMIDLIST;
|
||||
|
||||
#if defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST_ABSOLUTE *PIDLIST_ABSOLUTE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_ABSOLUTE *PCIDLIST_ABSOLUTE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_ABSOLUTE __unaligned *PCUIDLIST_ABSOLUTE;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST_RELATIVE *PIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_RELATIVE *PCIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST_RELATIVE __unaligned *PUIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_RELATIVE __unaligned *PCUIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMID_CHILD *PITEMID_CHILD;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMID_CHILD *PCITEMID_CHILD;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMID_CHILD __unaligned *PUITEMID_CHILD;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMID_CHILD __unaligned *PCUITEMID_CHILD;
|
||||
|
||||
typedef const PCUITEMID_CHILD *PCUITEMID_CHILD_ARRAY;
|
||||
|
||||
typedef const PCUIDLIST_RELATIVE *PCUIDLIST_RELATIVE_ARRAY;
|
||||
|
||||
typedef const PCIDLIST_ABSOLUTE *PCIDLIST_ABSOLUTE_ARRAY;
|
||||
|
||||
typedef const PCUIDLIST_ABSOLUTE *PCUIDLIST_ABSOLUTE_ARRAY;
|
||||
|
||||
#else // !(defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus))
|
||||
#define PIDLIST_ABSOLUTE LPITEMIDLIST
|
||||
#define PCIDLIST_ABSOLUTE LPCITEMIDLIST
|
||||
#define PCUIDLIST_ABSOLUTE LPCITEMIDLIST
|
||||
#define PIDLIST_RELATIVE LPITEMIDLIST
|
||||
#define PCIDLIST_RELATIVE LPCITEMIDLIST
|
||||
#define PUIDLIST_RELATIVE LPITEMIDLIST
|
||||
#define PCUIDLIST_RELATIVE LPCITEMIDLIST
|
||||
#define PITEMID_CHILD LPITEMIDLIST
|
||||
#define PCITEMID_CHILD LPCITEMIDLIST
|
||||
#define PUITEMID_CHILD LPITEMIDLIST
|
||||
#define PCUITEMID_CHILD LPCITEMIDLIST
|
||||
#define PCUITEMID_CHILD_ARRAY LPCITEMIDLIST *
|
||||
#define PCUIDLIST_RELATIVE_ARRAY LPCITEMIDLIST *
|
||||
#define PCIDLIST_ABSOLUTE_ARRAY LPCITEMIDLIST *
|
||||
#define PCUIDLIST_ABSOLUTE_ARRAY LPCITEMIDLIST *
|
||||
#endif // defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
#ifdef MIDL_PASS
|
||||
typedef struct _WIN32_FIND_DATAA
|
||||
{
|
||||
DWORD dwFileAttributes;
|
||||
FILETIME ftCreationTime;
|
||||
FILETIME ftLastAccessTime;
|
||||
FILETIME ftLastWriteTime;
|
||||
DWORD nFileSizeHigh;
|
||||
DWORD nFileSizeLow;
|
||||
DWORD dwReserved0;
|
||||
DWORD dwReserved1;
|
||||
CHAR cFileName[ 260 ];
|
||||
CHAR cAlternateFileName[ 14 ];
|
||||
} WIN32_FIND_DATAA;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAA *PWIN32_FIND_DATAA;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAA *LPWIN32_FIND_DATAA;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAW
|
||||
{
|
||||
DWORD dwFileAttributes;
|
||||
FILETIME ftCreationTime;
|
||||
FILETIME ftLastAccessTime;
|
||||
FILETIME ftLastWriteTime;
|
||||
DWORD nFileSizeHigh;
|
||||
DWORD nFileSizeLow;
|
||||
DWORD dwReserved0;
|
||||
DWORD dwReserved1;
|
||||
WCHAR cFileName[ 260 ];
|
||||
WCHAR cAlternateFileName[ 14 ];
|
||||
} WIN32_FIND_DATAW;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAW *PWIN32_FIND_DATAW;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAW *LPWIN32_FIND_DATAW;
|
||||
|
||||
#endif // MIDL_PASS
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// struct STRRET
|
||||
//
|
||||
// structure for returning strings from IShellFolder member functions
|
||||
//
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// uType indicate which union member to use
|
||||
// STRRET_WSTR Use STRRET.pOleStr must be freed by caller of GetDisplayNameOf
|
||||
// STRRET_OFFSET Use STRRET.uOffset Offset into SHITEMID for ANSI string
|
||||
// STRRET_CSTR Use STRRET.cStr ANSI Buffer
|
||||
//
|
||||
typedef /* [v1_enum] */
|
||||
enum tagSTRRET_TYPE
|
||||
{ STRRET_WSTR = 0,
|
||||
STRRET_OFFSET = 0x1,
|
||||
STRRET_CSTR = 0x2
|
||||
} STRRET_TYPE;
|
||||
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1200)
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4201) /* nonstandard extension used : nameless struct/union */
|
||||
#pragma once
|
||||
#endif
|
||||
#include <pshpack8.h>
|
||||
typedef struct _STRRET
|
||||
{
|
||||
UINT uType;
|
||||
union
|
||||
{
|
||||
LPWSTR pOleStr;
|
||||
UINT uOffset;
|
||||
char cStr[ 260 ];
|
||||
} DUMMYUNIONNAME;
|
||||
} STRRET;
|
||||
|
||||
#include <poppack.h>
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1200)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
typedef STRRET *LPSTRRET;
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// struct SHELLDETAILS
|
||||
//
|
||||
// structure for returning strings from IShellDetails
|
||||
//
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// fmt; // LVCFMT_* value (header only)
|
||||
// cxChar; // Number of 'average' characters (header only)
|
||||
// str; // String information
|
||||
//
|
||||
#include <pshpack1.h>
|
||||
typedef struct _SHELLDETAILS
|
||||
{
|
||||
int fmt;
|
||||
int cxChar;
|
||||
STRRET str;
|
||||
} SHELLDETAILS;
|
||||
|
||||
typedef struct _SHELLDETAILS *LPSHELLDETAILS;
|
||||
|
||||
#include <poppack.h>
|
||||
|
||||
#if (_WIN32_IE >= _WIN32_IE_IE60SP2)
|
||||
typedef /* [v1_enum] */
|
||||
enum tagPERCEIVED
|
||||
{ PERCEIVED_TYPE_FIRST = -3,
|
||||
PERCEIVED_TYPE_CUSTOM = -3,
|
||||
PERCEIVED_TYPE_UNSPECIFIED = -2,
|
||||
PERCEIVED_TYPE_FOLDER = -1,
|
||||
PERCEIVED_TYPE_UNKNOWN = 0,
|
||||
PERCEIVED_TYPE_TEXT = 1,
|
||||
PERCEIVED_TYPE_IMAGE = 2,
|
||||
PERCEIVED_TYPE_AUDIO = 3,
|
||||
PERCEIVED_TYPE_VIDEO = 4,
|
||||
PERCEIVED_TYPE_COMPRESSED = 5,
|
||||
PERCEIVED_TYPE_DOCUMENT = 6,
|
||||
PERCEIVED_TYPE_SYSTEM = 7,
|
||||
PERCEIVED_TYPE_APPLICATION = 8,
|
||||
PERCEIVED_TYPE_GAMEMEDIA = 9,
|
||||
PERCEIVED_TYPE_CONTACTS = 10,
|
||||
PERCEIVED_TYPE_LAST = 10
|
||||
} PERCEIVED;
|
||||
|
||||
#define PERCEIVEDFLAG_UNDEFINED 0x0000
|
||||
#define PERCEIVEDFLAG_SOFTCODED 0x0001
|
||||
#define PERCEIVEDFLAG_HARDCODED 0x0002
|
||||
#define PERCEIVEDFLAG_NATIVESUPPORT 0x0004
|
||||
#define PERCEIVEDFLAG_GDIPLUS 0x0010
|
||||
#define PERCEIVEDFLAG_WMSDK 0x0020
|
||||
#define PERCEIVEDFLAG_ZIPFOLDER 0x0040
|
||||
typedef DWORD PERCEIVEDFLAG;
|
||||
|
||||
#endif // _WIN32_IE_IE60SP2
|
||||
|
||||
#if (NTDDI_VERSION >= NTDDI_LONGHORN)
|
||||
typedef struct _COMDLG_FILTERSPEC
|
||||
{
|
||||
LPCWSTR pszName;
|
||||
LPCWSTR pszSpec;
|
||||
} COMDLG_FILTERSPEC;
|
||||
|
||||
typedef struct tagMACHINE_ID
|
||||
{
|
||||
char szName[ 16 ];
|
||||
} MACHINE_ID;
|
||||
|
||||
typedef struct tagDOMAIN_RELATIVE_OBJECTID
|
||||
{
|
||||
GUID guidVolume;
|
||||
GUID guidObject;
|
||||
} DOMAIN_RELATIVE_OBJECTID;
|
||||
|
||||
typedef GUID KNOWNFOLDERID;
|
||||
|
||||
#if 0
|
||||
typedef KNOWNFOLDERID *REFKNOWNFOLDERID;
|
||||
|
||||
#endif // 0
|
||||
#ifdef __cplusplus
|
||||
#define REFKNOWNFOLDERID const KNOWNFOLDERID &
|
||||
#else // !__cplusplus
|
||||
#define REFKNOWNFOLDERID const KNOWNFOLDERID * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
#endif // NTDDI_LONGHORN
|
||||
typedef GUID FOLDERTYPEID;
|
||||
|
||||
#if 0
|
||||
typedef FOLDERTYPEID *REFFOLDERTYPEID;
|
||||
|
||||
#endif // 0
|
||||
#ifdef __cplusplus
|
||||
#define REFFOLDERTYPEID const FOLDERTYPEID &
|
||||
#else // !__cplusplus
|
||||
#define REFFOLDERTYPEID const FOLDERTYPEID * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
typedef GUID TASKOWNERID;
|
||||
|
||||
#if 0
|
||||
typedef TASKOWNERID *REFTASKOWNERID;
|
||||
|
||||
#endif // 0
|
||||
#ifdef __cplusplus
|
||||
#define REFTASKOWNERID const TASKOWNERID &
|
||||
#else // !__cplusplus
|
||||
#define REFTASKOWNERID const TASKOWNERID * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
#ifndef LF_FACESIZE
|
||||
typedef struct tagLOGFONTA
|
||||
{
|
||||
LONG lfHeight;
|
||||
LONG lfWidth;
|
||||
LONG lfEscapement;
|
||||
LONG lfOrientation;
|
||||
LONG lfWeight;
|
||||
BYTE lfItalic;
|
||||
BYTE lfUnderline;
|
||||
BYTE lfStrikeOut;
|
||||
BYTE lfCharSet;
|
||||
BYTE lfOutPrecision;
|
||||
BYTE lfClipPrecision;
|
||||
BYTE lfQuality;
|
||||
BYTE lfPitchAndFamily;
|
||||
CHAR lfFaceName[ 32 ];
|
||||
} LOGFONTA;
|
||||
|
||||
typedef struct tagLOGFONTW
|
||||
{
|
||||
LONG lfHeight;
|
||||
LONG lfWidth;
|
||||
LONG lfEscapement;
|
||||
LONG lfOrientation;
|
||||
LONG lfWeight;
|
||||
BYTE lfItalic;
|
||||
BYTE lfUnderline;
|
||||
BYTE lfStrikeOut;
|
||||
BYTE lfCharSet;
|
||||
BYTE lfOutPrecision;
|
||||
BYTE lfClipPrecision;
|
||||
BYTE lfQuality;
|
||||
BYTE lfPitchAndFamily;
|
||||
WCHAR lfFaceName[ 32 ];
|
||||
} LOGFONTW;
|
||||
|
||||
typedef LOGFONTA LOGFONT;
|
||||
|
||||
#endif // LF_FACESIZE
|
||||
typedef /* [v1_enum] */
|
||||
enum tagSHCOLSTATE
|
||||
{ SHCOLSTATE_TYPE_STR = 0x1,
|
||||
SHCOLSTATE_TYPE_INT = 0x2,
|
||||
SHCOLSTATE_TYPE_DATE = 0x3,
|
||||
SHCOLSTATE_TYPEMASK = 0xf,
|
||||
SHCOLSTATE_ONBYDEFAULT = 0x10,
|
||||
SHCOLSTATE_SLOW = 0x20,
|
||||
SHCOLSTATE_EXTENDED = 0x40,
|
||||
SHCOLSTATE_SECONDARYUI = 0x80,
|
||||
SHCOLSTATE_HIDDEN = 0x100,
|
||||
SHCOLSTATE_PREFER_VARCMP = 0x200,
|
||||
SHCOLSTATE_PREFER_FMTCMP = 0x400,
|
||||
SHCOLSTATE_NOSORTBYFOLDERNESS = 0x800,
|
||||
SHCOLSTATE_VIEWONLY = 0x10000,
|
||||
SHCOLSTATE_BATCHREAD = 0x20000,
|
||||
SHCOLSTATE_NO_GROUPBY = 0x40000,
|
||||
SHCOLSTATE_FIXED_WIDTH = 0x1000,
|
||||
SHCOLSTATE_NODPISCALE = 0x2000,
|
||||
SHCOLSTATE_FIXED_RATIO = 0x4000,
|
||||
SHCOLSTATE_DISPLAYMASK = 0xf000
|
||||
} SHCOLSTATE;
|
||||
|
||||
typedef DWORD SHCOLSTATEF;
|
||||
|
||||
typedef PROPERTYKEY SHCOLUMNID;
|
||||
|
||||
typedef const SHCOLUMNID *LPCSHCOLUMNID;
|
||||
|
||||
|
||||
|
||||
extern RPC_IF_HANDLE __MIDL_itf_shtypes_0000_0000_v0_0_c_ifspec;
|
||||
extern RPC_IF_HANDLE __MIDL_itf_shtypes_0000_0000_v0_0_s_ifspec;
|
||||
|
||||
/* Additional Prototypes for ALL interfaces */
|
||||
|
||||
/* end of Additional Prototypes */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
|
||||
|
||||
|
||||
/* File created by MIDL compiler version 7.00.0499 */
|
||||
/* Compiler settings for shtypes.idl:
|
||||
Oicf, W1, Zp8, env=Win32 (32b run)
|
||||
protocol : dce , ms_ext, c_ext, robust
|
||||
error checks: allocation ref bounds_check enum stub_data
|
||||
VC __declspec() decoration level:
|
||||
__declspec(uuid()), __declspec(selectany), __declspec(novtable)
|
||||
DECLSPEC_UUID(), MIDL_INTERFACE()
|
||||
*/
|
||||
//@@MIDL_FILE_HEADING( )
|
||||
|
||||
#pragma warning( disable: 4049 ) /* more than 64k source lines */
|
||||
|
||||
|
||||
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||
#endif
|
||||
|
||||
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||
#endif
|
||||
|
||||
#include "rpc.h"
|
||||
#include "rpcndr.h"
|
||||
|
||||
#ifndef __RPCNDR_H_VERSION__
|
||||
#error this stub requires an updated version of <rpcndr.h>
|
||||
#endif // __RPCNDR_H_VERSION__
|
||||
|
||||
|
||||
#ifndef __shtypes_h__
|
||||
#define __shtypes_h__
|
||||
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||
#pragma once
|
||||
#endif
|
||||
|
||||
/* Forward Declarations */
|
||||
|
||||
/* header files for imported files */
|
||||
#include "wtypes.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"{
|
||||
#endif
|
||||
|
||||
|
||||
/* interface __MIDL_itf_shtypes_0000_0000 */
|
||||
/* [local] */
|
||||
|
||||
//+-------------------------------------------------------------------------
|
||||
//
|
||||
// Microsoft Windows
|
||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
//
|
||||
//--------------------------------------------------------------------------
|
||||
//===========================================================================
|
||||
//
|
||||
// Object identifiers in the explorer's name space (ItemID and IDList)
|
||||
//
|
||||
// All the items that the user can browse with the explorer (such as files,
|
||||
// directories, servers, work-groups, etc.) has an identifier which is unique
|
||||
// among items within the parent folder. Those identifiers are called item
|
||||
// IDs (SHITEMID). Since all its parent folders have their own item IDs,
|
||||
// any items can be uniquely identified by a list of item IDs, which is called
|
||||
// an ID list (ITEMIDLIST).
|
||||
//
|
||||
// ID lists are almost always allocated by the task allocator (see some
|
||||
// description below as well as OLE 2.0 SDK) and may be passed across
|
||||
// some of shell interfaces (such as IShellFolder). Each item ID in an ID list
|
||||
// is only meaningful to its parent folder (which has generated it), and all
|
||||
// the clients must treat it as an opaque binary data except the first two
|
||||
// bytes, which indicates the size of the item ID.
|
||||
//
|
||||
// When a shell extension -- which implements the IShellFolder interace --
|
||||
// generates an item ID, it may put any information in it, not only the data
|
||||
// with that it needs to identifies the item, but also some additional
|
||||
// information, which would help implementing some other functions efficiently.
|
||||
// For example, the shell's IShellFolder implementation of file system items
|
||||
// stores the primary (long) name of a file or a directory as the item
|
||||
// identifier, but it also stores its alternative (short) name, size and date
|
||||
// etc.
|
||||
//
|
||||
// When an ID list is passed to one of shell APIs (such as SHGetPathFromIDList),
|
||||
// it is always an absolute path -- relative from the root of the name space,
|
||||
// which is the desktop folder. When an ID list is passed to one of IShellFolder
|
||||
// member function, it is always a relative path from the folder (unless it
|
||||
// is explicitly specified).
|
||||
//
|
||||
//===========================================================================
|
||||
//
|
||||
// SHITEMID -- Item ID (mkid)
|
||||
// USHORT cb; // Size of the ID (including cb itself)
|
||||
// BYTE abID[]; // The item ID (variable length)
|
||||
//
|
||||
#include <pshpack1.h>
|
||||
typedef struct _SHITEMID
|
||||
{
|
||||
USHORT cb;
|
||||
BYTE abID[ 1 ];
|
||||
} SHITEMID;
|
||||
|
||||
#include <poppack.h>
|
||||
#if defined(_M_IX86)
|
||||
#define __unaligned
|
||||
#endif // __unaligned
|
||||
typedef SHITEMID __unaligned *LPSHITEMID;
|
||||
|
||||
typedef const SHITEMID __unaligned *LPCSHITEMID;
|
||||
|
||||
//
|
||||
// ITEMIDLIST -- List if item IDs (combined with 0-terminator)
|
||||
//
|
||||
#include <pshpack1.h>
|
||||
typedef struct _ITEMIDLIST
|
||||
{
|
||||
SHITEMID mkid;
|
||||
} ITEMIDLIST;
|
||||
|
||||
#if defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
typedef struct _ITEMIDLIST_RELATIVE : ITEMIDLIST {} ITEMIDLIST_RELATIVE;
|
||||
typedef struct _ITEMID_CHILD : ITEMIDLIST_RELATIVE {} ITEMID_CHILD;
|
||||
typedef struct _ITEMIDLIST_ABSOLUTE : ITEMIDLIST_RELATIVE {} ITEMIDLIST_ABSOLUTE;
|
||||
#else // !(defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus))
|
||||
typedef ITEMIDLIST ITEMIDLIST_RELATIVE;
|
||||
|
||||
typedef ITEMIDLIST ITEMID_CHILD;
|
||||
|
||||
typedef ITEMIDLIST ITEMIDLIST_ABSOLUTE;
|
||||
|
||||
#endif // defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
#include <poppack.h>
|
||||
typedef /* [unique] */ __RPC_unique_pointer BYTE_BLOB *wirePIDL;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST __unaligned *LPITEMIDLIST;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST __unaligned *LPCITEMIDLIST;
|
||||
|
||||
#if defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST_ABSOLUTE *PIDLIST_ABSOLUTE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_ABSOLUTE *PCIDLIST_ABSOLUTE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_ABSOLUTE __unaligned *PCUIDLIST_ABSOLUTE;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST_RELATIVE *PIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_RELATIVE *PCIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMIDLIST_RELATIVE __unaligned *PUIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMIDLIST_RELATIVE __unaligned *PCUIDLIST_RELATIVE;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMID_CHILD *PITEMID_CHILD;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMID_CHILD *PCITEMID_CHILD;
|
||||
|
||||
typedef /* [wire_marshal] */ ITEMID_CHILD __unaligned *PUITEMID_CHILD;
|
||||
|
||||
typedef /* [wire_marshal] */ const ITEMID_CHILD __unaligned *PCUITEMID_CHILD;
|
||||
|
||||
typedef const PCUITEMID_CHILD *PCUITEMID_CHILD_ARRAY;
|
||||
|
||||
typedef const PCUIDLIST_RELATIVE *PCUIDLIST_RELATIVE_ARRAY;
|
||||
|
||||
typedef const PCIDLIST_ABSOLUTE *PCIDLIST_ABSOLUTE_ARRAY;
|
||||
|
||||
typedef const PCUIDLIST_ABSOLUTE *PCUIDLIST_ABSOLUTE_ARRAY;
|
||||
|
||||
#else // !(defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus))
|
||||
#define PIDLIST_ABSOLUTE LPITEMIDLIST
|
||||
#define PCIDLIST_ABSOLUTE LPCITEMIDLIST
|
||||
#define PCUIDLIST_ABSOLUTE LPCITEMIDLIST
|
||||
#define PIDLIST_RELATIVE LPITEMIDLIST
|
||||
#define PCIDLIST_RELATIVE LPCITEMIDLIST
|
||||
#define PUIDLIST_RELATIVE LPITEMIDLIST
|
||||
#define PCUIDLIST_RELATIVE LPCITEMIDLIST
|
||||
#define PITEMID_CHILD LPITEMIDLIST
|
||||
#define PCITEMID_CHILD LPCITEMIDLIST
|
||||
#define PUITEMID_CHILD LPITEMIDLIST
|
||||
#define PCUITEMID_CHILD LPCITEMIDLIST
|
||||
#define PCUITEMID_CHILD_ARRAY LPCITEMIDLIST *
|
||||
#define PCUIDLIST_RELATIVE_ARRAY LPCITEMIDLIST *
|
||||
#define PCIDLIST_ABSOLUTE_ARRAY LPCITEMIDLIST *
|
||||
#define PCUIDLIST_ABSOLUTE_ARRAY LPCITEMIDLIST *
|
||||
#endif // defined(STRICT_TYPED_ITEMIDS) && defined(__cplusplus)
|
||||
#ifdef MIDL_PASS
|
||||
typedef struct _WIN32_FIND_DATAA
|
||||
{
|
||||
DWORD dwFileAttributes;
|
||||
FILETIME ftCreationTime;
|
||||
FILETIME ftLastAccessTime;
|
||||
FILETIME ftLastWriteTime;
|
||||
DWORD nFileSizeHigh;
|
||||
DWORD nFileSizeLow;
|
||||
DWORD dwReserved0;
|
||||
DWORD dwReserved1;
|
||||
CHAR cFileName[ 260 ];
|
||||
CHAR cAlternateFileName[ 14 ];
|
||||
} WIN32_FIND_DATAA;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAA *PWIN32_FIND_DATAA;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAA *LPWIN32_FIND_DATAA;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAW
|
||||
{
|
||||
DWORD dwFileAttributes;
|
||||
FILETIME ftCreationTime;
|
||||
FILETIME ftLastAccessTime;
|
||||
FILETIME ftLastWriteTime;
|
||||
DWORD nFileSizeHigh;
|
||||
DWORD nFileSizeLow;
|
||||
DWORD dwReserved0;
|
||||
DWORD dwReserved1;
|
||||
WCHAR cFileName[ 260 ];
|
||||
WCHAR cAlternateFileName[ 14 ];
|
||||
} WIN32_FIND_DATAW;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAW *PWIN32_FIND_DATAW;
|
||||
|
||||
typedef struct _WIN32_FIND_DATAW *LPWIN32_FIND_DATAW;
|
||||
|
||||
#endif // MIDL_PASS
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// struct STRRET
|
||||
//
|
||||
// structure for returning strings from IShellFolder member functions
|
||||
//
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// uType indicate which union member to use
|
||||
// STRRET_WSTR Use STRRET.pOleStr must be freed by caller of GetDisplayNameOf
|
||||
// STRRET_OFFSET Use STRRET.uOffset Offset into SHITEMID for ANSI string
|
||||
// STRRET_CSTR Use STRRET.cStr ANSI Buffer
|
||||
//
|
||||
typedef /* [v1_enum] */
|
||||
enum tagSTRRET_TYPE
|
||||
{ STRRET_WSTR = 0,
|
||||
STRRET_OFFSET = 0x1,
|
||||
STRRET_CSTR = 0x2
|
||||
} STRRET_TYPE;
|
||||
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1200)
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4201) /* nonstandard extension used : nameless struct/union */
|
||||
#pragma once
|
||||
#endif
|
||||
#include <pshpack8.h>
|
||||
typedef struct _STRRET
|
||||
{
|
||||
UINT uType;
|
||||
union
|
||||
{
|
||||
LPWSTR pOleStr;
|
||||
UINT uOffset;
|
||||
char cStr[ 260 ];
|
||||
} DUMMYUNIONNAME;
|
||||
} STRRET;
|
||||
|
||||
#include <poppack.h>
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1200)
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
typedef STRRET *LPSTRRET;
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// struct SHELLDETAILS
|
||||
//
|
||||
// structure for returning strings from IShellDetails
|
||||
//
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
// fmt; // LVCFMT_* value (header only)
|
||||
// cxChar; // Number of 'average' characters (header only)
|
||||
// str; // String information
|
||||
//
|
||||
#include <pshpack1.h>
|
||||
typedef struct _SHELLDETAILS
|
||||
{
|
||||
int fmt;
|
||||
int cxChar;
|
||||
STRRET str;
|
||||
} SHELLDETAILS;
|
||||
|
||||
typedef struct _SHELLDETAILS *LPSHELLDETAILS;
|
||||
|
||||
#include <poppack.h>
|
||||
|
||||
#if (_WIN32_IE >= _WIN32_IE_IE60SP2)
|
||||
typedef /* [v1_enum] */
|
||||
enum tagPERCEIVED
|
||||
{ PERCEIVED_TYPE_FIRST = -3,
|
||||
PERCEIVED_TYPE_CUSTOM = -3,
|
||||
PERCEIVED_TYPE_UNSPECIFIED = -2,
|
||||
PERCEIVED_TYPE_FOLDER = -1,
|
||||
PERCEIVED_TYPE_UNKNOWN = 0,
|
||||
PERCEIVED_TYPE_TEXT = 1,
|
||||
PERCEIVED_TYPE_IMAGE = 2,
|
||||
PERCEIVED_TYPE_AUDIO = 3,
|
||||
PERCEIVED_TYPE_VIDEO = 4,
|
||||
PERCEIVED_TYPE_COMPRESSED = 5,
|
||||
PERCEIVED_TYPE_DOCUMENT = 6,
|
||||
PERCEIVED_TYPE_SYSTEM = 7,
|
||||
PERCEIVED_TYPE_APPLICATION = 8,
|
||||
PERCEIVED_TYPE_GAMEMEDIA = 9,
|
||||
PERCEIVED_TYPE_CONTACTS = 10,
|
||||
PERCEIVED_TYPE_LAST = 10
|
||||
} PERCEIVED;
|
||||
|
||||
#define PERCEIVEDFLAG_UNDEFINED 0x0000
|
||||
#define PERCEIVEDFLAG_SOFTCODED 0x0001
|
||||
#define PERCEIVEDFLAG_HARDCODED 0x0002
|
||||
#define PERCEIVEDFLAG_NATIVESUPPORT 0x0004
|
||||
#define PERCEIVEDFLAG_GDIPLUS 0x0010
|
||||
#define PERCEIVEDFLAG_WMSDK 0x0020
|
||||
#define PERCEIVEDFLAG_ZIPFOLDER 0x0040
|
||||
typedef DWORD PERCEIVEDFLAG;
|
||||
|
||||
#endif // _WIN32_IE_IE60SP2
|
||||
|
||||
#if (NTDDI_VERSION >= NTDDI_LONGHORN)
|
||||
typedef struct _COMDLG_FILTERSPEC
|
||||
{
|
||||
LPCWSTR pszName;
|
||||
LPCWSTR pszSpec;
|
||||
} COMDLG_FILTERSPEC;
|
||||
|
||||
typedef struct tagMACHINE_ID
|
||||
{
|
||||
char szName[ 16 ];
|
||||
} MACHINE_ID;
|
||||
|
||||
typedef struct tagDOMAIN_RELATIVE_OBJECTID
|
||||
{
|
||||
GUID guidVolume;
|
||||
GUID guidObject;
|
||||
} DOMAIN_RELATIVE_OBJECTID;
|
||||
|
||||
typedef GUID KNOWNFOLDERID;
|
||||
|
||||
#if 0
|
||||
typedef KNOWNFOLDERID *REFKNOWNFOLDERID;
|
||||
|
||||
#endif // 0
|
||||
#ifdef __cplusplus
|
||||
#define REFKNOWNFOLDERID const KNOWNFOLDERID &
|
||||
#else // !__cplusplus
|
||||
#define REFKNOWNFOLDERID const KNOWNFOLDERID * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
#endif // NTDDI_LONGHORN
|
||||
typedef GUID FOLDERTYPEID;
|
||||
|
||||
#if 0
|
||||
typedef FOLDERTYPEID *REFFOLDERTYPEID;
|
||||
|
||||
#endif // 0
|
||||
#ifdef __cplusplus
|
||||
#define REFFOLDERTYPEID const FOLDERTYPEID &
|
||||
#else // !__cplusplus
|
||||
#define REFFOLDERTYPEID const FOLDERTYPEID * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
typedef GUID TASKOWNERID;
|
||||
|
||||
#if 0
|
||||
typedef TASKOWNERID *REFTASKOWNERID;
|
||||
|
||||
#endif // 0
|
||||
#ifdef __cplusplus
|
||||
#define REFTASKOWNERID const TASKOWNERID &
|
||||
#else // !__cplusplus
|
||||
#define REFTASKOWNERID const TASKOWNERID * __MIDL_CONST
|
||||
#endif // __cplusplus
|
||||
#ifndef LF_FACESIZE
|
||||
typedef struct tagLOGFONTA
|
||||
{
|
||||
LONG lfHeight;
|
||||
LONG lfWidth;
|
||||
LONG lfEscapement;
|
||||
LONG lfOrientation;
|
||||
LONG lfWeight;
|
||||
BYTE lfItalic;
|
||||
BYTE lfUnderline;
|
||||
BYTE lfStrikeOut;
|
||||
BYTE lfCharSet;
|
||||
BYTE lfOutPrecision;
|
||||
BYTE lfClipPrecision;
|
||||
BYTE lfQuality;
|
||||
BYTE lfPitchAndFamily;
|
||||
CHAR lfFaceName[ 32 ];
|
||||
} LOGFONTA;
|
||||
|
||||
typedef struct tagLOGFONTW
|
||||
{
|
||||
LONG lfHeight;
|
||||
LONG lfWidth;
|
||||
LONG lfEscapement;
|
||||
LONG lfOrientation;
|
||||
LONG lfWeight;
|
||||
BYTE lfItalic;
|
||||
BYTE lfUnderline;
|
||||
BYTE lfStrikeOut;
|
||||
BYTE lfCharSet;
|
||||
BYTE lfOutPrecision;
|
||||
BYTE lfClipPrecision;
|
||||
BYTE lfQuality;
|
||||
BYTE lfPitchAndFamily;
|
||||
WCHAR lfFaceName[ 32 ];
|
||||
} LOGFONTW;
|
||||
|
||||
typedef LOGFONTA LOGFONT;
|
||||
|
||||
#endif // LF_FACESIZE
|
||||
typedef /* [v1_enum] */
|
||||
enum tagSHCOLSTATE
|
||||
{ SHCOLSTATE_TYPE_STR = 0x1,
|
||||
SHCOLSTATE_TYPE_INT = 0x2,
|
||||
SHCOLSTATE_TYPE_DATE = 0x3,
|
||||
SHCOLSTATE_TYPEMASK = 0xf,
|
||||
SHCOLSTATE_ONBYDEFAULT = 0x10,
|
||||
SHCOLSTATE_SLOW = 0x20,
|
||||
SHCOLSTATE_EXTENDED = 0x40,
|
||||
SHCOLSTATE_SECONDARYUI = 0x80,
|
||||
SHCOLSTATE_HIDDEN = 0x100,
|
||||
SHCOLSTATE_PREFER_VARCMP = 0x200,
|
||||
SHCOLSTATE_PREFER_FMTCMP = 0x400,
|
||||
SHCOLSTATE_NOSORTBYFOLDERNESS = 0x800,
|
||||
SHCOLSTATE_VIEWONLY = 0x10000,
|
||||
SHCOLSTATE_BATCHREAD = 0x20000,
|
||||
SHCOLSTATE_NO_GROUPBY = 0x40000,
|
||||
SHCOLSTATE_FIXED_WIDTH = 0x1000,
|
||||
SHCOLSTATE_NODPISCALE = 0x2000,
|
||||
SHCOLSTATE_FIXED_RATIO = 0x4000,
|
||||
SHCOLSTATE_DISPLAYMASK = 0xf000
|
||||
} SHCOLSTATE;
|
||||
|
||||
typedef DWORD SHCOLSTATEF;
|
||||
|
||||
typedef PROPERTYKEY SHCOLUMNID;
|
||||
|
||||
typedef const SHCOLUMNID *LPCSHCOLUMNID;
|
||||
|
||||
|
||||
|
||||
extern RPC_IF_HANDLE __MIDL_itf_shtypes_0000_0000_v0_0_c_ifspec;
|
||||
extern RPC_IF_HANDLE __MIDL_itf_shtypes_0000_0000_v0_0_s_ifspec;
|
||||
|
||||
/* Additional Prototypes for ALL interfaces */
|
||||
|
||||
/* end of Additional Prototypes */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -1,144 +1,144 @@
|
|||
/*
|
||||
* Microsoft COM initialization routines
|
||||
* Copyright (c) 1999-2011 Ross Bencina, Dmitry Kostjuchenko
|
||||
*
|
||||
* Based on the Open Source API proposed by Ross Bencina
|
||||
* Copyright (c) 1999-2011 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup win_src
|
||||
|
||||
@brief Microsoft COM initialization routines.
|
||||
*/
|
||||
|
||||
#include <windows.h>
|
||||
#include <objbase.h>
|
||||
|
||||
#include "portaudio.h"
|
||||
#include "pa_util.h"
|
||||
#include "pa_debugprint.h"
|
||||
|
||||
#include "pa_win_coinitialize.h"
|
||||
|
||||
|
||||
#if (defined(WIN32) && (defined(_MSC_VER) && (_MSC_VER >= 1200))) && !defined(_WIN32_WCE) /* MSC version 6 and above */
|
||||
#pragma comment( lib, "ole32.lib" )
|
||||
#endif
|
||||
|
||||
|
||||
/* use some special bit patterns here to try to guard against uninitialized memory errors */
|
||||
#define PAWINUTIL_COM_INITIALIZED (0xb38f)
|
||||
#define PAWINUTIL_COM_NOT_INITIALIZED (0xf1cd)
|
||||
|
||||
|
||||
PaError PaWinUtil_CoInitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult )
|
||||
{
|
||||
HRESULT hr;
|
||||
|
||||
comInitializationResult->state = PAWINUTIL_COM_NOT_INITIALIZED;
|
||||
|
||||
/*
|
||||
If COM is already initialized CoInitialize will either return
|
||||
FALSE, or RPC_E_CHANGED_MODE if it was initialised in a different
|
||||
threading mode. In either case we shouldn't consider it an error
|
||||
but we need to be careful to not call CoUninitialize() if
|
||||
RPC_E_CHANGED_MODE was returned.
|
||||
*/
|
||||
|
||||
hr = CoInitialize(0); /* use legacy-safe equivalent to CoInitializeEx(NULL, COINIT_APARTMENTTHREADED) */
|
||||
if( FAILED(hr) && hr != RPC_E_CHANGED_MODE )
|
||||
{
|
||||
PA_DEBUG(("CoInitialize(0) failed. hr=%d\n", hr));
|
||||
|
||||
if( hr == E_OUTOFMEMORY )
|
||||
return paInsufficientMemory;
|
||||
|
||||
{
|
||||
char *lpMsgBuf;
|
||||
FormatMessage(
|
||||
FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
|
||||
NULL,
|
||||
hr,
|
||||
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
|
||||
(LPTSTR) &lpMsgBuf,
|
||||
0,
|
||||
NULL
|
||||
);
|
||||
PaUtil_SetLastHostErrorInfo( hostApiType, hr, lpMsgBuf );
|
||||
LocalFree( lpMsgBuf );
|
||||
}
|
||||
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
|
||||
if( hr != RPC_E_CHANGED_MODE )
|
||||
{
|
||||
comInitializationResult->state = PAWINUTIL_COM_INITIALIZED;
|
||||
|
||||
/*
|
||||
Memorize calling thread id and report warning on Uninitialize if
|
||||
calling thread is different as CoInitialize must match CoUninitialize
|
||||
in the same thread.
|
||||
*/
|
||||
comInitializationResult->initializingThreadId = GetCurrentThreadId();
|
||||
}
|
||||
|
||||
return paNoError;
|
||||
}
|
||||
|
||||
|
||||
void PaWinUtil_CoUninitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult )
|
||||
{
|
||||
if( comInitializationResult->state != PAWINUTIL_COM_NOT_INITIALIZED
|
||||
&& comInitializationResult->state != PAWINUTIL_COM_INITIALIZED ){
|
||||
|
||||
PA_DEBUG(("ERROR: PaWinUtil_CoUninitialize called without calling PaWinUtil_CoInitialize\n"));
|
||||
}
|
||||
|
||||
if( comInitializationResult->state == PAWINUTIL_COM_INITIALIZED )
|
||||
{
|
||||
DWORD currentThreadId = GetCurrentThreadId();
|
||||
if( comInitializationResult->initializingThreadId != currentThreadId )
|
||||
{
|
||||
PA_DEBUG(("ERROR: failed PaWinUtil_CoUninitialize calling thread[%d] does not match initializing thread[%d]\n",
|
||||
currentThreadId, comInitializationResult->initializingThreadId));
|
||||
}
|
||||
else
|
||||
{
|
||||
CoUninitialize();
|
||||
|
||||
comInitializationResult->state = PAWINUTIL_COM_NOT_INITIALIZED;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* Microsoft COM initialization routines
|
||||
* Copyright (c) 1999-2011 Ross Bencina, Dmitry Kostjuchenko
|
||||
*
|
||||
* Based on the Open Source API proposed by Ross Bencina
|
||||
* Copyright (c) 1999-2011 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup win_src
|
||||
|
||||
@brief Microsoft COM initialization routines.
|
||||
*/
|
||||
|
||||
#include <windows.h>
|
||||
#include <objbase.h>
|
||||
|
||||
#include "portaudio.h"
|
||||
#include "pa_util.h"
|
||||
#include "pa_debugprint.h"
|
||||
|
||||
#include "pa_win_coinitialize.h"
|
||||
|
||||
|
||||
#if (defined(WIN32) && (defined(_MSC_VER) && (_MSC_VER >= 1200))) && !defined(_WIN32_WCE) /* MSC version 6 and above */
|
||||
#pragma comment( lib, "ole32.lib" )
|
||||
#endif
|
||||
|
||||
|
||||
/* use some special bit patterns here to try to guard against uninitialized memory errors */
|
||||
#define PAWINUTIL_COM_INITIALIZED (0xb38f)
|
||||
#define PAWINUTIL_COM_NOT_INITIALIZED (0xf1cd)
|
||||
|
||||
|
||||
PaError PaWinUtil_CoInitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult )
|
||||
{
|
||||
HRESULT hr;
|
||||
|
||||
comInitializationResult->state = PAWINUTIL_COM_NOT_INITIALIZED;
|
||||
|
||||
/*
|
||||
If COM is already initialized CoInitialize will either return
|
||||
FALSE, or RPC_E_CHANGED_MODE if it was initialised in a different
|
||||
threading mode. In either case we shouldn't consider it an error
|
||||
but we need to be careful to not call CoUninitialize() if
|
||||
RPC_E_CHANGED_MODE was returned.
|
||||
*/
|
||||
|
||||
hr = CoInitialize(0); /* use legacy-safe equivalent to CoInitializeEx(NULL, COINIT_APARTMENTTHREADED) */
|
||||
if( FAILED(hr) && hr != RPC_E_CHANGED_MODE )
|
||||
{
|
||||
PA_DEBUG(("CoInitialize(0) failed. hr=%d\n", hr));
|
||||
|
||||
if( hr == E_OUTOFMEMORY )
|
||||
return paInsufficientMemory;
|
||||
|
||||
{
|
||||
char *lpMsgBuf;
|
||||
FormatMessage(
|
||||
FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
|
||||
NULL,
|
||||
hr,
|
||||
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
|
||||
(LPTSTR) &lpMsgBuf,
|
||||
0,
|
||||
NULL
|
||||
);
|
||||
PaUtil_SetLastHostErrorInfo( hostApiType, hr, lpMsgBuf );
|
||||
LocalFree( lpMsgBuf );
|
||||
}
|
||||
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
|
||||
if( hr != RPC_E_CHANGED_MODE )
|
||||
{
|
||||
comInitializationResult->state = PAWINUTIL_COM_INITIALIZED;
|
||||
|
||||
/*
|
||||
Memorize calling thread id and report warning on Uninitialize if
|
||||
calling thread is different as CoInitialize must match CoUninitialize
|
||||
in the same thread.
|
||||
*/
|
||||
comInitializationResult->initializingThreadId = GetCurrentThreadId();
|
||||
}
|
||||
|
||||
return paNoError;
|
||||
}
|
||||
|
||||
|
||||
void PaWinUtil_CoUninitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult )
|
||||
{
|
||||
if( comInitializationResult->state != PAWINUTIL_COM_NOT_INITIALIZED
|
||||
&& comInitializationResult->state != PAWINUTIL_COM_INITIALIZED ){
|
||||
|
||||
PA_DEBUG(("ERROR: PaWinUtil_CoUninitialize called without calling PaWinUtil_CoInitialize\n"));
|
||||
}
|
||||
|
||||
if( comInitializationResult->state == PAWINUTIL_COM_INITIALIZED )
|
||||
{
|
||||
DWORD currentThreadId = GetCurrentThreadId();
|
||||
if( comInitializationResult->initializingThreadId != currentThreadId )
|
||||
{
|
||||
PA_DEBUG(("ERROR: failed PaWinUtil_CoUninitialize calling thread[%d] does not match initializing thread[%d]\n",
|
||||
currentThreadId, comInitializationResult->initializingThreadId));
|
||||
}
|
||||
else
|
||||
{
|
||||
CoUninitialize();
|
||||
|
||||
comInitializationResult->state = PAWINUTIL_COM_NOT_INITIALIZED;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,94 +1,94 @@
|
|||
/*
|
||||
* Microsoft COM initialization routines
|
||||
* Copyright (c) 1999-2011 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup win_src
|
||||
|
||||
@brief Microsoft COM initialization routines.
|
||||
*/
|
||||
|
||||
#ifndef PA_WIN_COINITIALIZE_H
|
||||
#define PA_WIN_COINITIALIZE_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
/**
|
||||
@brief Data type used to hold the result of an attempt to initialize COM
|
||||
using PaWinUtil_CoInitialize. Must be retained between a call to
|
||||
PaWinUtil_CoInitialize and a matching call to PaWinUtil_CoUninitialize.
|
||||
*/
|
||||
typedef struct PaWinUtilComInitializationResult{
|
||||
int state;
|
||||
int initializingThreadId;
|
||||
} PaWinUtilComInitializationResult;
|
||||
|
||||
|
||||
/**
|
||||
@brief Initialize Microsoft COM subsystem on the current thread.
|
||||
|
||||
@param hostApiType the host API type id of the caller. Used for error reporting.
|
||||
|
||||
@param comInitializationResult An output parameter. The value pointed to by
|
||||
this parameter stores information required by PaWinUtil_CoUninitialize
|
||||
to correctly uninitialize COM. The value should be retained and later
|
||||
passed to PaWinUtil_CoUninitialize.
|
||||
|
||||
If PaWinUtil_CoInitialize returns paNoError, the caller must later call
|
||||
PaWinUtil_CoUninitialize once.
|
||||
*/
|
||||
PaError PaWinUtil_CoInitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult );
|
||||
|
||||
|
||||
/**
|
||||
@brief Uninitialize the Microsoft COM subsystem on the current thread using
|
||||
the result of a previous call to PaWinUtil_CoInitialize. Must be called on the same
|
||||
thread as PaWinUtil_CoInitialize.
|
||||
|
||||
@param hostApiType the host API type id of the caller. Used for error reporting.
|
||||
|
||||
@param comInitializationResult An input parameter. A pointer to a value previously
|
||||
initialized by a call to PaWinUtil_CoInitialize.
|
||||
*/
|
||||
void PaWinUtil_CoUninitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult );
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* PA_WIN_COINITIALIZE_H */
|
||||
/*
|
||||
* Microsoft COM initialization routines
|
||||
* Copyright (c) 1999-2011 Ross Bencina, Phil Burk
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@ingroup win_src
|
||||
|
||||
@brief Microsoft COM initialization routines.
|
||||
*/
|
||||
|
||||
#ifndef PA_WIN_COINITIALIZE_H
|
||||
#define PA_WIN_COINITIALIZE_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif /* __cplusplus */
|
||||
|
||||
|
||||
/**
|
||||
@brief Data type used to hold the result of an attempt to initialize COM
|
||||
using PaWinUtil_CoInitialize. Must be retained between a call to
|
||||
PaWinUtil_CoInitialize and a matching call to PaWinUtil_CoUninitialize.
|
||||
*/
|
||||
typedef struct PaWinUtilComInitializationResult{
|
||||
int state;
|
||||
int initializingThreadId;
|
||||
} PaWinUtilComInitializationResult;
|
||||
|
||||
|
||||
/**
|
||||
@brief Initialize Microsoft COM subsystem on the current thread.
|
||||
|
||||
@param hostApiType the host API type id of the caller. Used for error reporting.
|
||||
|
||||
@param comInitializationResult An output parameter. The value pointed to by
|
||||
this parameter stores information required by PaWinUtil_CoUninitialize
|
||||
to correctly uninitialize COM. The value should be retained and later
|
||||
passed to PaWinUtil_CoUninitialize.
|
||||
|
||||
If PaWinUtil_CoInitialize returns paNoError, the caller must later call
|
||||
PaWinUtil_CoUninitialize once.
|
||||
*/
|
||||
PaError PaWinUtil_CoInitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult );
|
||||
|
||||
|
||||
/**
|
||||
@brief Uninitialize the Microsoft COM subsystem on the current thread using
|
||||
the result of a previous call to PaWinUtil_CoInitialize. Must be called on the same
|
||||
thread as PaWinUtil_CoInitialize.
|
||||
|
||||
@param hostApiType the host API type id of the caller. Used for error reporting.
|
||||
|
||||
@param comInitializationResult An input parameter. A pointer to a value previously
|
||||
initialized by a call to PaWinUtil_CoInitialize.
|
||||
*/
|
||||
void PaWinUtil_CoUninitialize( PaHostApiTypeId hostApiType, PaWinUtilComInitializationResult *comInitializationResult );
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
#endif /* PA_WIN_COINITIALIZE_H */
|
||||
|
|
|
|||
|
|
@ -1,158 +1,158 @@
|
|||
/*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Windows WAVEFORMAT* data structure utilities
|
||||
* portaudio.h should be included before this file.
|
||||
*
|
||||
* Copyright (c) 2007 Ross Bencina
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
#include <windows.h>
|
||||
#include <mmsystem.h>
|
||||
|
||||
#include "portaudio.h"
|
||||
#include "pa_win_waveformat.h"
|
||||
|
||||
|
||||
#if !defined(WAVE_FORMAT_EXTENSIBLE)
|
||||
#define WAVE_FORMAT_EXTENSIBLE 0xFFFE
|
||||
#endif
|
||||
|
||||
static GUID pawin_ksDataFormatSubtypeGuidBase =
|
||||
{ (USHORT)(WAVE_FORMAT_PCM), 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 };
|
||||
|
||||
|
||||
int PaWin_SampleFormatToLinearWaveFormatTag( PaSampleFormat sampleFormat )
|
||||
{
|
||||
if( sampleFormat == paFloat32 )
|
||||
return PAWIN_WAVE_FORMAT_IEEE_FLOAT;
|
||||
|
||||
return PAWIN_WAVE_FORMAT_PCM;
|
||||
}
|
||||
|
||||
|
||||
void PaWin_InitializeWaveFormatEx( PaWinWaveFormat *waveFormat,
|
||||
int numChannels, PaSampleFormat sampleFormat, int waveFormatTag, double sampleRate )
|
||||
{
|
||||
WAVEFORMATEX *waveFormatEx = (WAVEFORMATEX*)waveFormat;
|
||||
int bytesPerSample = Pa_GetSampleSize(sampleFormat);
|
||||
unsigned long bytesPerFrame = numChannels * bytesPerSample;
|
||||
|
||||
waveFormatEx->wFormatTag = waveFormatTag;
|
||||
waveFormatEx->nChannels = (WORD)numChannels;
|
||||
waveFormatEx->nSamplesPerSec = (DWORD)sampleRate;
|
||||
waveFormatEx->nAvgBytesPerSec = waveFormatEx->nSamplesPerSec * bytesPerFrame;
|
||||
waveFormatEx->nBlockAlign = (WORD)bytesPerFrame;
|
||||
waveFormatEx->wBitsPerSample = bytesPerSample * 8;
|
||||
waveFormatEx->cbSize = 0;
|
||||
}
|
||||
|
||||
|
||||
void PaWin_InitializeWaveFormatExtensible( PaWinWaveFormat *waveFormat,
|
||||
int numChannels, PaSampleFormat sampleFormat, int waveFormatTag, double sampleRate,
|
||||
PaWinWaveFormatChannelMask channelMask )
|
||||
{
|
||||
WAVEFORMATEX *waveFormatEx = (WAVEFORMATEX*)waveFormat;
|
||||
int bytesPerSample = Pa_GetSampleSize(sampleFormat);
|
||||
unsigned long bytesPerFrame = numChannels * bytesPerSample;
|
||||
GUID guid;
|
||||
|
||||
waveFormatEx->wFormatTag = WAVE_FORMAT_EXTENSIBLE;
|
||||
waveFormatEx->nChannels = (WORD)numChannels;
|
||||
waveFormatEx->nSamplesPerSec = (DWORD)sampleRate;
|
||||
waveFormatEx->nAvgBytesPerSec = waveFormatEx->nSamplesPerSec * bytesPerFrame;
|
||||
waveFormatEx->nBlockAlign = (WORD)bytesPerFrame;
|
||||
waveFormatEx->wBitsPerSample = bytesPerSample * 8;
|
||||
waveFormatEx->cbSize = 22;
|
||||
|
||||
*((WORD*)&waveFormat->fields[PAWIN_INDEXOF_WVALIDBITSPERSAMPLE]) =
|
||||
waveFormatEx->wBitsPerSample;
|
||||
|
||||
*((DWORD*)&waveFormat->fields[PAWIN_INDEXOF_DWCHANNELMASK]) = channelMask;
|
||||
|
||||
guid = pawin_ksDataFormatSubtypeGuidBase;
|
||||
guid.Data1 = (USHORT)waveFormatTag;
|
||||
*((GUID*)&waveFormat->fields[PAWIN_INDEXOF_SUBFORMAT]) = guid;
|
||||
}
|
||||
|
||||
PaWinWaveFormatChannelMask PaWin_DefaultChannelMask( int numChannels )
|
||||
{
|
||||
switch( numChannels ){
|
||||
case 1:
|
||||
return PAWIN_SPEAKER_MONO;
|
||||
case 2:
|
||||
return PAWIN_SPEAKER_STEREO;
|
||||
case 3:
|
||||
return PAWIN_SPEAKER_FRONT_LEFT | PAWIN_SPEAKER_FRONT_CENTER | PAWIN_SPEAKER_FRONT_RIGHT;
|
||||
case 4:
|
||||
return PAWIN_SPEAKER_QUAD;
|
||||
case 5:
|
||||
return PAWIN_SPEAKER_QUAD | PAWIN_SPEAKER_FRONT_CENTER;
|
||||
case 6:
|
||||
/* The meaning of the PAWIN_SPEAKER_5POINT1 flag has changed over time:
|
||||
http://msdn2.microsoft.com/en-us/library/aa474707.aspx
|
||||
We use PAWIN_SPEAKER_5POINT1 (not PAWIN_SPEAKER_5POINT1_SURROUND)
|
||||
because on some cards (eg Audigy) PAWIN_SPEAKER_5POINT1_SURROUND
|
||||
results in a virtual mixdown placing the rear output in the
|
||||
front _and_ rear speakers.
|
||||
*/
|
||||
return PAWIN_SPEAKER_5POINT1;
|
||||
/* case 7: */
|
||||
case 8:
|
||||
/* RoBi: PAWIN_SPEAKER_7POINT1_SURROUND fits normal surround sound setups better than PAWIN_SPEAKER_7POINT1, f.i. NVidia HDMI Audio
|
||||
output is silent on channels 5&6 with NVidia drivers, and channel 7&8 with Micrsoft HD Audio driver using PAWIN_SPEAKER_7POINT1.
|
||||
With PAWIN_SPEAKER_7POINT1_SURROUND both setups work OK. */
|
||||
return PAWIN_SPEAKER_7POINT1_SURROUND;
|
||||
}
|
||||
|
||||
/* Apparently some Audigy drivers will output silence
|
||||
if the direct-out constant (0) is used. So this is not ideal.
|
||||
|
||||
RoBi 2012-12-19: Also, NVidia driver seem to output garbage instead. Again not very ideal.
|
||||
*/
|
||||
return PAWIN_SPEAKER_DIRECTOUT;
|
||||
|
||||
/* Note that Alec Rogers proposed the following as an alternate method to
|
||||
generate the default channel mask, however it doesn't seem to be an improvement
|
||||
over the above, since some drivers will matrix outputs mapping to non-present
|
||||
speakers accross multiple physical speakers.
|
||||
|
||||
if(nChannels==1) {
|
||||
pwfFormat->dwChannelMask = SPEAKER_FRONT_CENTER;
|
||||
}
|
||||
else {
|
||||
pwfFormat->dwChannelMask = 0;
|
||||
for(i=0; i<nChannels; i++)
|
||||
pwfFormat->dwChannelMask = (pwfFormat->dwChannelMask << 1) | 0x1;
|
||||
}
|
||||
*/
|
||||
}
|
||||
/*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Windows WAVEFORMAT* data structure utilities
|
||||
* portaudio.h should be included before this file.
|
||||
*
|
||||
* Copyright (c) 2007 Ross Bencina
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
#include <windows.h>
|
||||
#include <mmsystem.h>
|
||||
|
||||
#include "portaudio.h"
|
||||
#include "pa_win_waveformat.h"
|
||||
|
||||
|
||||
#if !defined(WAVE_FORMAT_EXTENSIBLE)
|
||||
#define WAVE_FORMAT_EXTENSIBLE 0xFFFE
|
||||
#endif
|
||||
|
||||
static GUID pawin_ksDataFormatSubtypeGuidBase =
|
||||
{ (USHORT)(WAVE_FORMAT_PCM), 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 };
|
||||
|
||||
|
||||
int PaWin_SampleFormatToLinearWaveFormatTag( PaSampleFormat sampleFormat )
|
||||
{
|
||||
if( sampleFormat == paFloat32 )
|
||||
return PAWIN_WAVE_FORMAT_IEEE_FLOAT;
|
||||
|
||||
return PAWIN_WAVE_FORMAT_PCM;
|
||||
}
|
||||
|
||||
|
||||
void PaWin_InitializeWaveFormatEx( PaWinWaveFormat *waveFormat,
|
||||
int numChannels, PaSampleFormat sampleFormat, int waveFormatTag, double sampleRate )
|
||||
{
|
||||
WAVEFORMATEX *waveFormatEx = (WAVEFORMATEX*)waveFormat;
|
||||
int bytesPerSample = Pa_GetSampleSize(sampleFormat);
|
||||
unsigned long bytesPerFrame = numChannels * bytesPerSample;
|
||||
|
||||
waveFormatEx->wFormatTag = waveFormatTag;
|
||||
waveFormatEx->nChannels = (WORD)numChannels;
|
||||
waveFormatEx->nSamplesPerSec = (DWORD)sampleRate;
|
||||
waveFormatEx->nAvgBytesPerSec = waveFormatEx->nSamplesPerSec * bytesPerFrame;
|
||||
waveFormatEx->nBlockAlign = (WORD)bytesPerFrame;
|
||||
waveFormatEx->wBitsPerSample = bytesPerSample * 8;
|
||||
waveFormatEx->cbSize = 0;
|
||||
}
|
||||
|
||||
|
||||
void PaWin_InitializeWaveFormatExtensible( PaWinWaveFormat *waveFormat,
|
||||
int numChannels, PaSampleFormat sampleFormat, int waveFormatTag, double sampleRate,
|
||||
PaWinWaveFormatChannelMask channelMask )
|
||||
{
|
||||
WAVEFORMATEX *waveFormatEx = (WAVEFORMATEX*)waveFormat;
|
||||
int bytesPerSample = Pa_GetSampleSize(sampleFormat);
|
||||
unsigned long bytesPerFrame = numChannels * bytesPerSample;
|
||||
GUID guid;
|
||||
|
||||
waveFormatEx->wFormatTag = WAVE_FORMAT_EXTENSIBLE;
|
||||
waveFormatEx->nChannels = (WORD)numChannels;
|
||||
waveFormatEx->nSamplesPerSec = (DWORD)sampleRate;
|
||||
waveFormatEx->nAvgBytesPerSec = waveFormatEx->nSamplesPerSec * bytesPerFrame;
|
||||
waveFormatEx->nBlockAlign = (WORD)bytesPerFrame;
|
||||
waveFormatEx->wBitsPerSample = bytesPerSample * 8;
|
||||
waveFormatEx->cbSize = 22;
|
||||
|
||||
*((WORD*)&waveFormat->fields[PAWIN_INDEXOF_WVALIDBITSPERSAMPLE]) =
|
||||
waveFormatEx->wBitsPerSample;
|
||||
|
||||
*((DWORD*)&waveFormat->fields[PAWIN_INDEXOF_DWCHANNELMASK]) = channelMask;
|
||||
|
||||
guid = pawin_ksDataFormatSubtypeGuidBase;
|
||||
guid.Data1 = (USHORT)waveFormatTag;
|
||||
*((GUID*)&waveFormat->fields[PAWIN_INDEXOF_SUBFORMAT]) = guid;
|
||||
}
|
||||
|
||||
PaWinWaveFormatChannelMask PaWin_DefaultChannelMask( int numChannels )
|
||||
{
|
||||
switch( numChannels ){
|
||||
case 1:
|
||||
return PAWIN_SPEAKER_MONO;
|
||||
case 2:
|
||||
return PAWIN_SPEAKER_STEREO;
|
||||
case 3:
|
||||
return PAWIN_SPEAKER_FRONT_LEFT | PAWIN_SPEAKER_FRONT_CENTER | PAWIN_SPEAKER_FRONT_RIGHT;
|
||||
case 4:
|
||||
return PAWIN_SPEAKER_QUAD;
|
||||
case 5:
|
||||
return PAWIN_SPEAKER_QUAD | PAWIN_SPEAKER_FRONT_CENTER;
|
||||
case 6:
|
||||
/* The meaning of the PAWIN_SPEAKER_5POINT1 flag has changed over time:
|
||||
http://msdn2.microsoft.com/en-us/library/aa474707.aspx
|
||||
We use PAWIN_SPEAKER_5POINT1 (not PAWIN_SPEAKER_5POINT1_SURROUND)
|
||||
because on some cards (eg Audigy) PAWIN_SPEAKER_5POINT1_SURROUND
|
||||
results in a virtual mixdown placing the rear output in the
|
||||
front _and_ rear speakers.
|
||||
*/
|
||||
return PAWIN_SPEAKER_5POINT1;
|
||||
/* case 7: */
|
||||
case 8:
|
||||
/* RoBi: PAWIN_SPEAKER_7POINT1_SURROUND fits normal surround sound setups better than PAWIN_SPEAKER_7POINT1, f.i. NVidia HDMI Audio
|
||||
output is silent on channels 5&6 with NVidia drivers, and channel 7&8 with Micrsoft HD Audio driver using PAWIN_SPEAKER_7POINT1.
|
||||
With PAWIN_SPEAKER_7POINT1_SURROUND both setups work OK. */
|
||||
return PAWIN_SPEAKER_7POINT1_SURROUND;
|
||||
}
|
||||
|
||||
/* Apparently some Audigy drivers will output silence
|
||||
if the direct-out constant (0) is used. So this is not ideal.
|
||||
|
||||
RoBi 2012-12-19: Also, NVidia driver seem to output garbage instead. Again not very ideal.
|
||||
*/
|
||||
return PAWIN_SPEAKER_DIRECTOUT;
|
||||
|
||||
/* Note that Alec Rogers proposed the following as an alternate method to
|
||||
generate the default channel mask, however it doesn't seem to be an improvement
|
||||
over the above, since some drivers will matrix outputs mapping to non-present
|
||||
speakers accross multiple physical speakers.
|
||||
|
||||
if(nChannels==1) {
|
||||
pwfFormat->dwChannelMask = SPEAKER_FRONT_CENTER;
|
||||
}
|
||||
else {
|
||||
pwfFormat->dwChannelMask = 0;
|
||||
for(i=0; i<nChannels; i++)
|
||||
pwfFormat->dwChannelMask = (pwfFormat->dwChannelMask << 1) | 0x1;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,309 +1,309 @@
|
|||
/*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Windows WDM KS utilities
|
||||
*
|
||||
* Copyright (c) 1999 - 2007 Andrew Baldwin, Ross Bencina
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
#include <windows.h>
|
||||
#include <mmreg.h>
|
||||
#ifndef WAVE_FORMAT_IEEE_FLOAT
|
||||
#define WAVE_FORMAT_IEEE_FLOAT 0x0003 // MinGW32 does not define this
|
||||
#endif
|
||||
#ifndef _WAVEFORMATEXTENSIBLE_
|
||||
#define _WAVEFORMATEXTENSIBLE_ // MinGW32 does not define this
|
||||
#endif
|
||||
#ifndef _INC_MMREG
|
||||
#define _INC_MMREG // for STATIC_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT
|
||||
#endif
|
||||
#include <winioctl.h> // MinGW32 does not define this automatically
|
||||
|
||||
#if defined(__GNUC__)
|
||||
|
||||
#include "../../hostapi/wasapi/mingw-include/ks.h"
|
||||
#include "../../hostapi/wasapi/mingw-include/ksmedia.h"
|
||||
|
||||
#else
|
||||
|
||||
#include <ks.h>
|
||||
#include <ksmedia.h>
|
||||
|
||||
#endif
|
||||
|
||||
#include <stdio.h> // just for some development printfs
|
||||
|
||||
#include "portaudio.h"
|
||||
#include "pa_util.h"
|
||||
#include "pa_win_wdmks_utils.h"
|
||||
|
||||
|
||||
/* PortAudio-local instances of GUIDs previously sourced from ksguid.lib */
|
||||
|
||||
/* GUID KSDATAFORMAT_TYPE_AUDIO */
|
||||
static const GUID pa_KSDATAFORMAT_TYPE_AUDIO = { STATIC_KSDATAFORMAT_TYPE_AUDIO };
|
||||
|
||||
/* GUID KSDATAFORMAT_SUBTYPE_IEEE_FLOAT */
|
||||
static const GUID pa_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT = { STATIC_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT };
|
||||
|
||||
/* GUID KSDATAFORMAT_SUBTYPE_PCM */
|
||||
static const GUID pa_KSDATAFORMAT_SUBTYPE_PCM = { STATIC_KSDATAFORMAT_SUBTYPE_PCM };
|
||||
|
||||
/* GUID KSDATAFORMAT_SUBTYPE_WAVEFORMATEX */
|
||||
static const GUID pa_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX = { STATIC_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX };
|
||||
|
||||
/* GUID KSMEDIUMSETID_Standard */
|
||||
static const GUID pa_KSMEDIUMSETID_Standard = { STATIC_KSMEDIUMSETID_Standard };
|
||||
|
||||
/* GUID KSINTERFACESETID_Standard */
|
||||
static const GUID pa_KSINTERFACESETID_Standard = { STATIC_KSINTERFACESETID_Standard };
|
||||
|
||||
/* GUID KSPROPSETID_Pin */
|
||||
static const GUID pa_KSPROPSETID_Pin = { STATIC_KSPROPSETID_Pin };
|
||||
|
||||
#define pa_IS_VALID_WAVEFORMATEX_GUID(Guid)\
|
||||
(!memcmp(((PUSHORT)&pa_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX) + 1, ((PUSHORT)(Guid)) + 1, sizeof(GUID) - sizeof(USHORT)))
|
||||
|
||||
|
||||
static PaError WdmGetPinPropertySimple(
|
||||
HANDLE handle,
|
||||
unsigned long pinId,
|
||||
unsigned long property,
|
||||
void* value,
|
||||
unsigned long valueSize )
|
||||
{
|
||||
DWORD bytesReturned;
|
||||
KSP_PIN ksPProp;
|
||||
ksPProp.Property.Set = pa_KSPROPSETID_Pin;
|
||||
ksPProp.Property.Id = property;
|
||||
ksPProp.Property.Flags = KSPROPERTY_TYPE_GET;
|
||||
ksPProp.PinId = pinId;
|
||||
ksPProp.Reserved = 0;
|
||||
|
||||
if( DeviceIoControl( handle, IOCTL_KS_PROPERTY, &ksPProp, sizeof(KSP_PIN),
|
||||
value, valueSize, &bytesReturned, NULL ) == 0 || bytesReturned != valueSize )
|
||||
{
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
else
|
||||
{
|
||||
return paNoError;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static PaError WdmGetPinPropertyMulti(
|
||||
HANDLE handle,
|
||||
unsigned long pinId,
|
||||
unsigned long property,
|
||||
KSMULTIPLE_ITEM** ksMultipleItem)
|
||||
{
|
||||
unsigned long multipleItemSize = 0;
|
||||
KSP_PIN ksPProp;
|
||||
DWORD bytesReturned;
|
||||
|
||||
*ksMultipleItem = 0;
|
||||
|
||||
ksPProp.Property.Set = pa_KSPROPSETID_Pin;
|
||||
ksPProp.Property.Id = property;
|
||||
ksPProp.Property.Flags = KSPROPERTY_TYPE_GET;
|
||||
ksPProp.PinId = pinId;
|
||||
ksPProp.Reserved = 0;
|
||||
|
||||
if( DeviceIoControl( handle, IOCTL_KS_PROPERTY, &ksPProp.Property,
|
||||
sizeof(KSP_PIN), NULL, 0, &multipleItemSize, NULL ) == 0 && GetLastError() != ERROR_MORE_DATA )
|
||||
{
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
|
||||
*ksMultipleItem = (KSMULTIPLE_ITEM*)PaUtil_AllocateMemory( multipleItemSize );
|
||||
if( !*ksMultipleItem )
|
||||
{
|
||||
return paInsufficientMemory;
|
||||
}
|
||||
|
||||
if( DeviceIoControl( handle, IOCTL_KS_PROPERTY, &ksPProp, sizeof(KSP_PIN),
|
||||
(void*)*ksMultipleItem, multipleItemSize, &bytesReturned, NULL ) == 0 || bytesReturned != multipleItemSize )
|
||||
{
|
||||
PaUtil_FreeMemory( ksMultipleItem );
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
|
||||
return paNoError;
|
||||
}
|
||||
|
||||
|
||||
static int GetKSFilterPinCount( HANDLE deviceHandle )
|
||||
{
|
||||
DWORD result;
|
||||
|
||||
if( WdmGetPinPropertySimple( deviceHandle, 0, KSPROPERTY_PIN_CTYPES, &result, sizeof(result) ) == paNoError ){
|
||||
return result;
|
||||
}else{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static KSPIN_COMMUNICATION GetKSFilterPinPropertyCommunication( HANDLE deviceHandle, int pinId )
|
||||
{
|
||||
KSPIN_COMMUNICATION result;
|
||||
|
||||
if( WdmGetPinPropertySimple( deviceHandle, pinId, KSPROPERTY_PIN_COMMUNICATION, &result, sizeof(result) ) == paNoError ){
|
||||
return result;
|
||||
}else{
|
||||
return KSPIN_COMMUNICATION_NONE;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static KSPIN_DATAFLOW GetKSFilterPinPropertyDataflow( HANDLE deviceHandle, int pinId )
|
||||
{
|
||||
KSPIN_DATAFLOW result;
|
||||
|
||||
if( WdmGetPinPropertySimple( deviceHandle, pinId, KSPROPERTY_PIN_DATAFLOW, &result, sizeof(result) ) == paNoError ){
|
||||
return result;
|
||||
}else{
|
||||
return (KSPIN_DATAFLOW)0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static int KSFilterPinPropertyIdentifiersInclude(
|
||||
HANDLE deviceHandle, int pinId, unsigned long property, const GUID *identifierSet, unsigned long identifierId )
|
||||
{
|
||||
KSMULTIPLE_ITEM* item = NULL;
|
||||
KSIDENTIFIER* identifier;
|
||||
int i;
|
||||
int result = 0;
|
||||
|
||||
if( WdmGetPinPropertyMulti( deviceHandle, pinId, property, &item) != paNoError )
|
||||
return 0;
|
||||
|
||||
identifier = (KSIDENTIFIER*)(item+1);
|
||||
|
||||
for( i = 0; i < (int)item->Count; i++ )
|
||||
{
|
||||
if( !memcmp( (void*)&identifier[i].Set, (void*)identifierSet, sizeof( GUID ) ) &&
|
||||
( identifier[i].Id == identifierId ) )
|
||||
{
|
||||
result = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
PaUtil_FreeMemory( item );
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/* return the maximum channel count supported by any pin on the device.
|
||||
if isInput is non-zero we query input pins, otherwise output pins.
|
||||
*/
|
||||
int PaWin_WDMKS_QueryFilterMaximumChannelCount( void *wcharDevicePath, int isInput )
|
||||
{
|
||||
HANDLE deviceHandle;
|
||||
ULONG i;
|
||||
int pinCount, pinId;
|
||||
int result = 0;
|
||||
KSPIN_DATAFLOW requiredDataflowDirection = (isInput ? KSPIN_DATAFLOW_OUT : KSPIN_DATAFLOW_IN );
|
||||
|
||||
if( !wcharDevicePath )
|
||||
return 0;
|
||||
|
||||
deviceHandle = CreateFileW( (LPCWSTR)wcharDevicePath, FILE_SHARE_READ|FILE_SHARE_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL );
|
||||
if( deviceHandle == INVALID_HANDLE_VALUE )
|
||||
return 0;
|
||||
|
||||
pinCount = GetKSFilterPinCount( deviceHandle );
|
||||
for( pinId = 0; pinId < pinCount; ++pinId )
|
||||
{
|
||||
KSPIN_COMMUNICATION communication = GetKSFilterPinPropertyCommunication( deviceHandle, pinId );
|
||||
KSPIN_DATAFLOW dataflow = GetKSFilterPinPropertyDataflow( deviceHandle, pinId );
|
||||
if( ( dataflow == requiredDataflowDirection ) &&
|
||||
(( communication == KSPIN_COMMUNICATION_SINK) ||
|
||||
( communication == KSPIN_COMMUNICATION_BOTH))
|
||||
&& ( KSFilterPinPropertyIdentifiersInclude( deviceHandle, pinId,
|
||||
KSPROPERTY_PIN_INTERFACES, &pa_KSINTERFACESETID_Standard, KSINTERFACE_STANDARD_STREAMING )
|
||||
|| KSFilterPinPropertyIdentifiersInclude( deviceHandle, pinId,
|
||||
KSPROPERTY_PIN_INTERFACES, &pa_KSINTERFACESETID_Standard, KSINTERFACE_STANDARD_LOOPED_STREAMING ) )
|
||||
&& KSFilterPinPropertyIdentifiersInclude( deviceHandle, pinId,
|
||||
KSPROPERTY_PIN_MEDIUMS, &pa_KSMEDIUMSETID_Standard, KSMEDIUM_STANDARD_DEVIO ) )
|
||||
{
|
||||
KSMULTIPLE_ITEM* item = NULL;
|
||||
if( WdmGetPinPropertyMulti( deviceHandle, pinId, KSPROPERTY_PIN_DATARANGES, &item ) == paNoError )
|
||||
{
|
||||
KSDATARANGE *dataRange = (KSDATARANGE*)(item+1);
|
||||
|
||||
for( i=0; i < item->Count; ++i ){
|
||||
|
||||
if( pa_IS_VALID_WAVEFORMATEX_GUID(&dataRange->SubFormat)
|
||||
|| memcmp( (void*)&dataRange->SubFormat, (void*)&pa_KSDATAFORMAT_SUBTYPE_PCM, sizeof(GUID) ) == 0
|
||||
|| memcmp( (void*)&dataRange->SubFormat, (void*)&pa_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT, sizeof(GUID) ) == 0
|
||||
|| ( ( memcmp( (void*)&dataRange->MajorFormat, (void*)&pa_KSDATAFORMAT_TYPE_AUDIO, sizeof(GUID) ) == 0 )
|
||||
&& ( memcmp( (void*)&dataRange->SubFormat, (void*)&KSDATAFORMAT_SUBTYPE_WILDCARD, sizeof(GUID) ) == 0 ) ) )
|
||||
{
|
||||
KSDATARANGE_AUDIO *dataRangeAudio = (KSDATARANGE_AUDIO*)dataRange;
|
||||
|
||||
/*
|
||||
printf( ">>> %d %d %d %d %S\n", isInput, dataflow, communication, dataRangeAudio->MaximumChannels, devicePath );
|
||||
|
||||
if( memcmp((void*)&dataRange->Specifier, (void*)&KSDATAFORMAT_SPECIFIER_WAVEFORMATEX, sizeof(GUID) ) == 0 )
|
||||
printf( "\tspecifier: KSDATAFORMAT_SPECIFIER_WAVEFORMATEX\n" );
|
||||
else if( memcmp((void*)&dataRange->Specifier, (void*)&KSDATAFORMAT_SPECIFIER_DSOUND, sizeof(GUID) ) == 0 )
|
||||
printf( "\tspecifier: KSDATAFORMAT_SPECIFIER_DSOUND\n" );
|
||||
else if( memcmp((void*)&dataRange->Specifier, (void*)&KSDATAFORMAT_SPECIFIER_WILDCARD, sizeof(GUID) ) == 0 )
|
||||
printf( "\tspecifier: KSDATAFORMAT_SPECIFIER_WILDCARD\n" );
|
||||
else
|
||||
printf( "\tspecifier: ?\n" );
|
||||
*/
|
||||
|
||||
/*
|
||||
We assume that very high values for MaximumChannels are not useful and indicate
|
||||
that the driver isn't prepared to tell us the real number of channels which it supports.
|
||||
*/
|
||||
if( dataRangeAudio->MaximumChannels < 0xFFFFUL && (int)dataRangeAudio->MaximumChannels > result )
|
||||
result = (int)dataRangeAudio->MaximumChannels;
|
||||
}
|
||||
|
||||
dataRange = (KSDATARANGE*)( ((char*)dataRange) + dataRange->FormatSize);
|
||||
}
|
||||
|
||||
PaUtil_FreeMemory( item );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
CloseHandle( deviceHandle );
|
||||
return result;
|
||||
}
|
||||
/*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Windows WDM KS utilities
|
||||
*
|
||||
* Copyright (c) 1999 - 2007 Andrew Baldwin, Ross Bencina
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
#include <windows.h>
|
||||
#include <mmreg.h>
|
||||
#ifndef WAVE_FORMAT_IEEE_FLOAT
|
||||
#define WAVE_FORMAT_IEEE_FLOAT 0x0003 // MinGW32 does not define this
|
||||
#endif
|
||||
#ifndef _WAVEFORMATEXTENSIBLE_
|
||||
#define _WAVEFORMATEXTENSIBLE_ // MinGW32 does not define this
|
||||
#endif
|
||||
#ifndef _INC_MMREG
|
||||
#define _INC_MMREG // for STATIC_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT
|
||||
#endif
|
||||
#include <winioctl.h> // MinGW32 does not define this automatically
|
||||
|
||||
#if defined(__GNUC__)
|
||||
|
||||
#include "../../hostapi/wasapi/mingw-include/ks.h"
|
||||
#include "../../hostapi/wasapi/mingw-include/ksmedia.h"
|
||||
|
||||
#else
|
||||
|
||||
#include <ks.h>
|
||||
#include <ksmedia.h>
|
||||
|
||||
#endif
|
||||
|
||||
#include <stdio.h> // just for some development printfs
|
||||
|
||||
#include "portaudio.h"
|
||||
#include "pa_util.h"
|
||||
#include "pa_win_wdmks_utils.h"
|
||||
|
||||
|
||||
/* PortAudio-local instances of GUIDs previously sourced from ksguid.lib */
|
||||
|
||||
/* GUID KSDATAFORMAT_TYPE_AUDIO */
|
||||
static const GUID pa_KSDATAFORMAT_TYPE_AUDIO = { STATIC_KSDATAFORMAT_TYPE_AUDIO };
|
||||
|
||||
/* GUID KSDATAFORMAT_SUBTYPE_IEEE_FLOAT */
|
||||
static const GUID pa_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT = { STATIC_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT };
|
||||
|
||||
/* GUID KSDATAFORMAT_SUBTYPE_PCM */
|
||||
static const GUID pa_KSDATAFORMAT_SUBTYPE_PCM = { STATIC_KSDATAFORMAT_SUBTYPE_PCM };
|
||||
|
||||
/* GUID KSDATAFORMAT_SUBTYPE_WAVEFORMATEX */
|
||||
static const GUID pa_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX = { STATIC_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX };
|
||||
|
||||
/* GUID KSMEDIUMSETID_Standard */
|
||||
static const GUID pa_KSMEDIUMSETID_Standard = { STATIC_KSMEDIUMSETID_Standard };
|
||||
|
||||
/* GUID KSINTERFACESETID_Standard */
|
||||
static const GUID pa_KSINTERFACESETID_Standard = { STATIC_KSINTERFACESETID_Standard };
|
||||
|
||||
/* GUID KSPROPSETID_Pin */
|
||||
static const GUID pa_KSPROPSETID_Pin = { STATIC_KSPROPSETID_Pin };
|
||||
|
||||
#define pa_IS_VALID_WAVEFORMATEX_GUID(Guid)\
|
||||
(!memcmp(((PUSHORT)&pa_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX) + 1, ((PUSHORT)(Guid)) + 1, sizeof(GUID) - sizeof(USHORT)))
|
||||
|
||||
|
||||
static PaError WdmGetPinPropertySimple(
|
||||
HANDLE handle,
|
||||
unsigned long pinId,
|
||||
unsigned long property,
|
||||
void* value,
|
||||
unsigned long valueSize )
|
||||
{
|
||||
DWORD bytesReturned;
|
||||
KSP_PIN ksPProp;
|
||||
ksPProp.Property.Set = pa_KSPROPSETID_Pin;
|
||||
ksPProp.Property.Id = property;
|
||||
ksPProp.Property.Flags = KSPROPERTY_TYPE_GET;
|
||||
ksPProp.PinId = pinId;
|
||||
ksPProp.Reserved = 0;
|
||||
|
||||
if( DeviceIoControl( handle, IOCTL_KS_PROPERTY, &ksPProp, sizeof(KSP_PIN),
|
||||
value, valueSize, &bytesReturned, NULL ) == 0 || bytesReturned != valueSize )
|
||||
{
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
else
|
||||
{
|
||||
return paNoError;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static PaError WdmGetPinPropertyMulti(
|
||||
HANDLE handle,
|
||||
unsigned long pinId,
|
||||
unsigned long property,
|
||||
KSMULTIPLE_ITEM** ksMultipleItem)
|
||||
{
|
||||
unsigned long multipleItemSize = 0;
|
||||
KSP_PIN ksPProp;
|
||||
DWORD bytesReturned;
|
||||
|
||||
*ksMultipleItem = 0;
|
||||
|
||||
ksPProp.Property.Set = pa_KSPROPSETID_Pin;
|
||||
ksPProp.Property.Id = property;
|
||||
ksPProp.Property.Flags = KSPROPERTY_TYPE_GET;
|
||||
ksPProp.PinId = pinId;
|
||||
ksPProp.Reserved = 0;
|
||||
|
||||
if( DeviceIoControl( handle, IOCTL_KS_PROPERTY, &ksPProp.Property,
|
||||
sizeof(KSP_PIN), NULL, 0, &multipleItemSize, NULL ) == 0 && GetLastError() != ERROR_MORE_DATA )
|
||||
{
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
|
||||
*ksMultipleItem = (KSMULTIPLE_ITEM*)PaUtil_AllocateMemory( multipleItemSize );
|
||||
if( !*ksMultipleItem )
|
||||
{
|
||||
return paInsufficientMemory;
|
||||
}
|
||||
|
||||
if( DeviceIoControl( handle, IOCTL_KS_PROPERTY, &ksPProp, sizeof(KSP_PIN),
|
||||
(void*)*ksMultipleItem, multipleItemSize, &bytesReturned, NULL ) == 0 || bytesReturned != multipleItemSize )
|
||||
{
|
||||
PaUtil_FreeMemory( ksMultipleItem );
|
||||
return paUnanticipatedHostError;
|
||||
}
|
||||
|
||||
return paNoError;
|
||||
}
|
||||
|
||||
|
||||
static int GetKSFilterPinCount( HANDLE deviceHandle )
|
||||
{
|
||||
DWORD result;
|
||||
|
||||
if( WdmGetPinPropertySimple( deviceHandle, 0, KSPROPERTY_PIN_CTYPES, &result, sizeof(result) ) == paNoError ){
|
||||
return result;
|
||||
}else{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static KSPIN_COMMUNICATION GetKSFilterPinPropertyCommunication( HANDLE deviceHandle, int pinId )
|
||||
{
|
||||
KSPIN_COMMUNICATION result;
|
||||
|
||||
if( WdmGetPinPropertySimple( deviceHandle, pinId, KSPROPERTY_PIN_COMMUNICATION, &result, sizeof(result) ) == paNoError ){
|
||||
return result;
|
||||
}else{
|
||||
return KSPIN_COMMUNICATION_NONE;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static KSPIN_DATAFLOW GetKSFilterPinPropertyDataflow( HANDLE deviceHandle, int pinId )
|
||||
{
|
||||
KSPIN_DATAFLOW result;
|
||||
|
||||
if( WdmGetPinPropertySimple( deviceHandle, pinId, KSPROPERTY_PIN_DATAFLOW, &result, sizeof(result) ) == paNoError ){
|
||||
return result;
|
||||
}else{
|
||||
return (KSPIN_DATAFLOW)0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static int KSFilterPinPropertyIdentifiersInclude(
|
||||
HANDLE deviceHandle, int pinId, unsigned long property, const GUID *identifierSet, unsigned long identifierId )
|
||||
{
|
||||
KSMULTIPLE_ITEM* item = NULL;
|
||||
KSIDENTIFIER* identifier;
|
||||
int i;
|
||||
int result = 0;
|
||||
|
||||
if( WdmGetPinPropertyMulti( deviceHandle, pinId, property, &item) != paNoError )
|
||||
return 0;
|
||||
|
||||
identifier = (KSIDENTIFIER*)(item+1);
|
||||
|
||||
for( i = 0; i < (int)item->Count; i++ )
|
||||
{
|
||||
if( !memcmp( (void*)&identifier[i].Set, (void*)identifierSet, sizeof( GUID ) ) &&
|
||||
( identifier[i].Id == identifierId ) )
|
||||
{
|
||||
result = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
PaUtil_FreeMemory( item );
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/* return the maximum channel count supported by any pin on the device.
|
||||
if isInput is non-zero we query input pins, otherwise output pins.
|
||||
*/
|
||||
int PaWin_WDMKS_QueryFilterMaximumChannelCount( void *wcharDevicePath, int isInput )
|
||||
{
|
||||
HANDLE deviceHandle;
|
||||
ULONG i;
|
||||
int pinCount, pinId;
|
||||
int result = 0;
|
||||
KSPIN_DATAFLOW requiredDataflowDirection = (isInput ? KSPIN_DATAFLOW_OUT : KSPIN_DATAFLOW_IN );
|
||||
|
||||
if( !wcharDevicePath )
|
||||
return 0;
|
||||
|
||||
deviceHandle = CreateFileW( (LPCWSTR)wcharDevicePath, FILE_SHARE_READ|FILE_SHARE_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL );
|
||||
if( deviceHandle == INVALID_HANDLE_VALUE )
|
||||
return 0;
|
||||
|
||||
pinCount = GetKSFilterPinCount( deviceHandle );
|
||||
for( pinId = 0; pinId < pinCount; ++pinId )
|
||||
{
|
||||
KSPIN_COMMUNICATION communication = GetKSFilterPinPropertyCommunication( deviceHandle, pinId );
|
||||
KSPIN_DATAFLOW dataflow = GetKSFilterPinPropertyDataflow( deviceHandle, pinId );
|
||||
if( ( dataflow == requiredDataflowDirection ) &&
|
||||
(( communication == KSPIN_COMMUNICATION_SINK) ||
|
||||
( communication == KSPIN_COMMUNICATION_BOTH))
|
||||
&& ( KSFilterPinPropertyIdentifiersInclude( deviceHandle, pinId,
|
||||
KSPROPERTY_PIN_INTERFACES, &pa_KSINTERFACESETID_Standard, KSINTERFACE_STANDARD_STREAMING )
|
||||
|| KSFilterPinPropertyIdentifiersInclude( deviceHandle, pinId,
|
||||
KSPROPERTY_PIN_INTERFACES, &pa_KSINTERFACESETID_Standard, KSINTERFACE_STANDARD_LOOPED_STREAMING ) )
|
||||
&& KSFilterPinPropertyIdentifiersInclude( deviceHandle, pinId,
|
||||
KSPROPERTY_PIN_MEDIUMS, &pa_KSMEDIUMSETID_Standard, KSMEDIUM_STANDARD_DEVIO ) )
|
||||
{
|
||||
KSMULTIPLE_ITEM* item = NULL;
|
||||
if( WdmGetPinPropertyMulti( deviceHandle, pinId, KSPROPERTY_PIN_DATARANGES, &item ) == paNoError )
|
||||
{
|
||||
KSDATARANGE *dataRange = (KSDATARANGE*)(item+1);
|
||||
|
||||
for( i=0; i < item->Count; ++i ){
|
||||
|
||||
if( pa_IS_VALID_WAVEFORMATEX_GUID(&dataRange->SubFormat)
|
||||
|| memcmp( (void*)&dataRange->SubFormat, (void*)&pa_KSDATAFORMAT_SUBTYPE_PCM, sizeof(GUID) ) == 0
|
||||
|| memcmp( (void*)&dataRange->SubFormat, (void*)&pa_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT, sizeof(GUID) ) == 0
|
||||
|| ( ( memcmp( (void*)&dataRange->MajorFormat, (void*)&pa_KSDATAFORMAT_TYPE_AUDIO, sizeof(GUID) ) == 0 )
|
||||
&& ( memcmp( (void*)&dataRange->SubFormat, (void*)&KSDATAFORMAT_SUBTYPE_WILDCARD, sizeof(GUID) ) == 0 ) ) )
|
||||
{
|
||||
KSDATARANGE_AUDIO *dataRangeAudio = (KSDATARANGE_AUDIO*)dataRange;
|
||||
|
||||
/*
|
||||
printf( ">>> %d %d %d %d %S\n", isInput, dataflow, communication, dataRangeAudio->MaximumChannels, devicePath );
|
||||
|
||||
if( memcmp((void*)&dataRange->Specifier, (void*)&KSDATAFORMAT_SPECIFIER_WAVEFORMATEX, sizeof(GUID) ) == 0 )
|
||||
printf( "\tspecifier: KSDATAFORMAT_SPECIFIER_WAVEFORMATEX\n" );
|
||||
else if( memcmp((void*)&dataRange->Specifier, (void*)&KSDATAFORMAT_SPECIFIER_DSOUND, sizeof(GUID) ) == 0 )
|
||||
printf( "\tspecifier: KSDATAFORMAT_SPECIFIER_DSOUND\n" );
|
||||
else if( memcmp((void*)&dataRange->Specifier, (void*)&KSDATAFORMAT_SPECIFIER_WILDCARD, sizeof(GUID) ) == 0 )
|
||||
printf( "\tspecifier: KSDATAFORMAT_SPECIFIER_WILDCARD\n" );
|
||||
else
|
||||
printf( "\tspecifier: ?\n" );
|
||||
*/
|
||||
|
||||
/*
|
||||
We assume that very high values for MaximumChannels are not useful and indicate
|
||||
that the driver isn't prepared to tell us the real number of channels which it supports.
|
||||
*/
|
||||
if( dataRangeAudio->MaximumChannels < 0xFFFFUL && (int)dataRangeAudio->MaximumChannels > result )
|
||||
result = (int)dataRangeAudio->MaximumChannels;
|
||||
}
|
||||
|
||||
dataRange = (KSDATARANGE*)( ((char*)dataRange) + dataRange->FormatSize);
|
||||
}
|
||||
|
||||
PaUtil_FreeMemory( item );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
CloseHandle( deviceHandle );
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,65 +1,65 @@
|
|||
#ifndef PA_WIN_WDMKS_UTILS_H
|
||||
#define PA_WIN_WDMKS_UTILS_H
|
||||
|
||||
/*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Windows WDM KS utilities
|
||||
*
|
||||
* Copyright (c) 1999 - 2007 Ross Bencina, Andrew Baldwin
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@brief Utilities for working with the Windows WDM KS API
|
||||
*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/**
|
||||
Query for the maximum number of channels supported by any pin of the
|
||||
specified device. Returns 0 if the query fails for any reason.
|
||||
|
||||
@param wcharDevicePath A system level PnP interface path, supplied as a WCHAR unicode string.
|
||||
Declard as void* to avoid introducing a dependency on wchar_t here.
|
||||
|
||||
@param isInput A flag specifying whether to query for input (non-zero) or output (zero) channels.
|
||||
*/
|
||||
int PaWin_WDMKS_QueryFilterMaximumChannelCount( void *wcharDevicePath, int isInput );
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#ifndef PA_WIN_WDMKS_UTILS_H
|
||||
#define PA_WIN_WDMKS_UTILS_H
|
||||
|
||||
/*
|
||||
* PortAudio Portable Real-Time Audio Library
|
||||
* Windows WDM KS utilities
|
||||
*
|
||||
* Copyright (c) 1999 - 2007 Ross Bencina, Andrew Baldwin
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining
|
||||
* a copy of this software and associated documentation files
|
||||
* (the "Software"), to deal in the Software without restriction,
|
||||
* including without limitation the rights to use, copy, modify, merge,
|
||||
* publish, distribute, sublicense, and/or sell copies of the Software,
|
||||
* and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be
|
||||
* included in all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
|
||||
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The text above constitutes the entire PortAudio license; however,
|
||||
* the PortAudio community also makes the following non-binding requests:
|
||||
*
|
||||
* Any person wishing to distribute modifications to the Software is
|
||||
* requested to send the modifications to the original developer so that
|
||||
* they can be incorporated into the canonical version. It is also
|
||||
* requested that these non-binding requests be included along with the
|
||||
* license above.
|
||||
*/
|
||||
|
||||
/** @file
|
||||
@brief Utilities for working with the Windows WDM KS API
|
||||
*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/**
|
||||
Query for the maximum number of channels supported by any pin of the
|
||||
specified device. Returns 0 if the query fails for any reason.
|
||||
|
||||
@param wcharDevicePath A system level PnP interface path, supplied as a WCHAR unicode string.
|
||||
Declard as void* to avoid introducing a dependency on wchar_t here.
|
||||
|
||||
@param isInput A flag specifying whether to query for input (non-zero) or output (zero) channels.
|
||||
*/
|
||||
int PaWin_WDMKS_QueryFilterMaximumChannelCount( void *wcharDevicePath, int isInput );
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif /* PA_WIN_WDMKS_UTILS_H */
|
||||
Loading…
Reference in a new issue