aboutsummaryrefslogtreecommitdiff
path: root/mp/src/public/steam/isteamclient.h
diff options
context:
space:
mode:
authorJoe Ludwig <[email protected]>2014-05-15 13:59:18 -0700
committerJoe Ludwig <[email protected]>2014-05-15 13:59:18 -0700
commit53e78c503e6e9c7d15e2eefc480755fe37dd7077 (patch)
treec8cc106eb4c0a2b2b5d79f534f2facb0514f5f55 /mp/src/public/steam/isteamclient.h
parentAdded many shader source files (diff)
downloadsource-sdk-2013-53e78c503e6e9c7d15e2eefc480755fe37dd7077.tar.xz
source-sdk-2013-53e78c503e6e9c7d15e2eefc480755fe37dd7077.zip
General:
* Upgraded Steamworks SDK to v1.29 * Fixed mod compatibility problem with Multiplayer Base that was introduced in September. * In Hammer, while using the Vertex Tool, pressing CTRL+B will snap selected vertices to the grid. Virtual Reality: * Mods that support virtual reality now need to have a line in gameinfo.txt that says “supportsvr 1”. This indicates to gameui and engine that certain UI should be enabled. * VR-enabled mods will now start up in VR mode when launched from Steam’s VR mode. Windows: * Upgraded to Visual Studio 2013. If you need to build projects for VS 2010, add /2010 to your VPC command line. OSX: * Upgraded to XCode 5.
Diffstat (limited to 'mp/src/public/steam/isteamclient.h')
-rw-r--r--mp/src/public/steam/isteamclient.h136
1 files changed, 91 insertions, 45 deletions
diff --git a/mp/src/public/steam/isteamclient.h b/mp/src/public/steam/isteamclient.h
index 43a2076e..b54ad3dc 100644
--- a/mp/src/public/steam/isteamclient.h
+++ b/mp/src/public/steam/isteamclient.h
@@ -1,4 +1,4 @@
-//========= Copyright Valve Corporation, All rights reserved. ============//
+//====== Copyright � 1996-2008, Valve Corporation, All rights reserved. =======
//
// Purpose: Main interface for loading and accessing Steamworks API's from the
// Steam client.
@@ -17,6 +17,10 @@
// Define compile time assert macros to let us validate the structure sizes.
#define VALVE_COMPILE_TIME_ASSERT( pred ) typedef char compile_time_assert_type[(pred) ? 1 : -1];
+#ifndef REFERENCE
+#define REFERENCE(arg) ((void)arg)
+#endif
+
#if defined(__linux__) || defined(__APPLE__)
// The 32-bit version of gcc has the alignment requirement for uint64 and double set to
// 4 meaning that even with #pragma pack(8) these types will only be four-byte aligned.
@@ -83,10 +87,14 @@ class ISteamApps;
class ISteamNetworking;
class ISteamRemoteStorage;
class ISteamScreenshots;
+class ISteamMusic;
class ISteamGameServerStats;
class ISteamPS3OverlayRender;
class ISteamHTTP;
class ISteamUnifiedMessages;
+class ISteamController;
+class ISteamUGC;
+class ISteamAppList;
//-----------------------------------------------------------------------------
// Purpose: Interface to creating a new steam instance, or to
@@ -189,9 +197,20 @@ public:
// Exposes the ISteamUnifiedMessages interface
virtual ISteamUnifiedMessages *GetISteamUnifiedMessages( HSteamUser hSteamuser, HSteamPipe hSteamPipe, const char *pchVersion ) = 0;
+ // Exposes the ISteamController interface
+ virtual ISteamController *GetISteamController( HSteamUser hSteamUser, HSteamPipe hSteamPipe, const char *pchVersion ) = 0;
+
+ // Exposes the ISteamUGC interface
+ virtual ISteamUGC *GetISteamUGC( HSteamUser hSteamUser, HSteamPipe hSteamPipe, const char *pchVersion ) = 0;
+
+ // returns app list interface, only available on specially registered apps
+ virtual ISteamAppList *GetISteamAppList( HSteamUser hSteamUser, HSteamPipe hSteamPipe, const char *pchVersion ) = 0;
+
+ // Music Player
+ virtual ISteamMusic *GetISteamMusic( HSteamUser hSteamuser, HSteamPipe hSteamPipe, const char *pchVersion ) = 0;
};
-#define STEAMCLIENT_INTERFACE_VERSION "SteamClient012"
+#define STEAMCLIENT_INTERFACE_VERSION "SteamClient014"
//-----------------------------------------------------------------------------
// Purpose: Base values for callback identifiers, each callback must
@@ -228,6 +247,15 @@ enum { k_iSteamControllerCallbacks = 2800 };
enum { k_iClientParentalSettingsCallbacks = 2900 };
enum { k_iClientDeviceAuthCallbacks = 3000 };
enum { k_iClientNetworkDeviceManagerCallbacks = 3100 };
+enum { k_iClientMusicCallbacks = 3200 };
+enum { k_iClientRemoteClientManagerCallbacks = 3300 };
+enum { k_iClientUGCCallbacks = 3400 };
+enum { k_iSteamStreamClientCallbacks = 3500 };
+enum { k_IClientProductBuilderCallbacks = 3600 };
+enum { k_iClientShortcutsCallbacks = 3700 };
+enum { k_iClientRemoteControlManagerCallbacks = 3800 };
+enum { k_iSteamAppListCallbacks = 3900 };
+enum { k_iSteamMusicCallbacks = 4000 };
//-----------------------------------------------------------------------------
@@ -236,21 +264,18 @@ enum { k_iClientNetworkDeviceManagerCallbacks = 3100 };
// Do not change any of these.
//-----------------------------------------------------------------------------
-class CSteamCallback
+struct SteamCallback_t
{
public:
- virtual const char *GetCallbackName() const = 0;
- virtual uint32 GetCallbackID() const = 0;
- virtual uint8 *GetFixedData() const = 0;
- virtual uint32 GetFixedSize() const = 0;
- virtual uint32 GetNumMemberVariables() const = 0;
- virtual bool GetMemberVariable( uint32 index, uint32 &varOffset, uint32 &varSize, uint32 &varCount, const char **pszName, const char **pszType ) const = 0;
+ SteamCallback_t() {}
};
#define DEFINE_CALLBACK( callbackname, callbackid ) \
-struct callbackname##_t { \
+struct callbackname : SteamCallback_t { \
enum { k_iCallback = callbackid }; \
- static callbackname##_t *GetNullPointer() { return 0; }
+ static callbackname *GetNullPointer() { return 0; } \
+ static const char *GetCallbackName() { return #callbackname; } \
+ static uint32 GetCallbackID() { return callbackname::k_iCallback; }
#define CALLBACK_MEMBER( varidx, vartype, varname ) \
public: vartype varname ; \
@@ -269,74 +294,93 @@ struct callbackname##_t { \
*pszName = #varname; *pszType = #vartype; }
-#define END_CALLBACK_INTERNAL_BEGIN( callbackname, numvars ) }; \
-class C##callbackname : public CSteamCallback { \
-public: callbackname##_t m_Data; \
- C##callbackname () { memset( &m_Data, 0, sizeof(m_Data) ); } \
- virtual const char *GetCallbackName() const { return #callbackname; } \
- virtual uint32 GetCallbackID() const { return callbackname##_t::k_iCallback; } \
- virtual uint32 GetFixedSize() const { return sizeof( m_Data ); } \
- virtual uint8 *GetFixedData() const { return (uint8*)&m_Data; } \
- virtual uint32 GetNumMemberVariables() const { return numvars; } \
- virtual bool GetMemberVariable( uint32 index, uint32 &varOffset, uint32 &varSize, uint32 &varCount, const char **pszName, const char **pszType ) const { \
+#define END_CALLBACK_INTERNAL_BEGIN( numvars ) \
+ static uint32 GetNumMemberVariables() { return numvars; } \
+ static bool GetMemberVariable( uint32 index, uint32 &varOffset, uint32 &varSize, uint32 &varCount, const char **pszName, const char **pszType ) { \
switch ( index ) { default : return false;
-#define END_CALLBACK_INTERNAL_SWITCH( varidx ) case varidx : m_Data.GetMemberVar_##varidx( varOffset, varSize, varCount, pszName, pszType ); return true;
+#define END_CALLBACK_INTERNAL_SWITCH( varidx ) case varidx : GetMemberVar_##varidx( varOffset, varSize, varCount, pszName, pszType ); return true;
-#define END_CALLBACK_INTERNAL_END() }; }; };
+#define END_CALLBACK_INTERNAL_END() }; } };
-#define END_DEFINE_CALLBACK_0( callbackname ) }; \
-class C##callbackname : public CSteamCallback { \
-public: callbackname##_t m_Data; \
- virtual const char *GetCallbackName() const { return #callbackname; } \
- virtual uint32 GetCallbackID() const { return callbackname##_t::k_iCallback; } \
- virtual uint32 GetFixedSize() const { return sizeof( m_Data ); } \
- virtual uint8 *GetFixedData() const { return (uint8*)&m_Data; } \
- virtual uint32 GetNumMemberVariables() const { return 0; } \
- virtual bool GetMemberVariable( uint32 index, uint32 &varOffset, uint32 &varSize, uint32 &varCount, const char **pszName, const char **pszType ) const { return false; } \
- }; \
+#define END_DEFINE_CALLBACK_0() \
+ static uint32 GetNumMemberVariables() { return 0; } \
+ static bool GetMemberVariable( uint32 index, uint32 &varOffset, uint32 &varSize, uint32 &varCount, const char **pszName, const char **pszType ) { REFERENCE( pszType ); REFERENCE( pszName ); REFERENCE( varCount ); REFERENCE( varSize ); REFERENCE( varOffset ); REFERENCE( index ); return false; } \
+ };
-#define END_DEFINE_CALLBACK_1( callbackname ) \
- END_CALLBACK_INTERNAL_BEGIN( callbackname, 1 ) \
+#define END_DEFINE_CALLBACK_1() \
+ END_CALLBACK_INTERNAL_BEGIN( 1 ) \
END_CALLBACK_INTERNAL_SWITCH( 0 ) \
END_CALLBACK_INTERNAL_END()
-#define END_DEFINE_CALLBACK_2( callbackname ) \
- END_CALLBACK_INTERNAL_BEGIN( callbackname, 2 ) \
+#define END_DEFINE_CALLBACK_2() \
+ END_CALLBACK_INTERNAL_BEGIN( 2 ) \
END_CALLBACK_INTERNAL_SWITCH( 0 ) \
END_CALLBACK_INTERNAL_SWITCH( 1 ) \
END_CALLBACK_INTERNAL_END()
-#define END_DEFINE_CALLBACK_3( callbackname ) \
- END_CALLBACK_INTERNAL_BEGIN( callbackname, 3 ) \
+#define END_DEFINE_CALLBACK_3() \
+ END_CALLBACK_INTERNAL_BEGIN( 3 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 0 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 1 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 2 ) \
+ END_CALLBACK_INTERNAL_END()
+
+#define END_DEFINE_CALLBACK_4() \
+ END_CALLBACK_INTERNAL_BEGIN( 4 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 0 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 1 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 2 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 3 ) \
+ END_CALLBACK_INTERNAL_END()
+
+#define END_DEFINE_CALLBACK_5() \
+ END_CALLBACK_INTERNAL_BEGIN( 4 ) \
END_CALLBACK_INTERNAL_SWITCH( 0 ) \
END_CALLBACK_INTERNAL_SWITCH( 1 ) \
END_CALLBACK_INTERNAL_SWITCH( 2 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 3 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 4 ) \
END_CALLBACK_INTERNAL_END()
-#define END_DEFINE_CALLBACK_4( callbackname ) \
- END_CALLBACK_INTERNAL_BEGIN( callbackname, 4 ) \
+
+#define END_DEFINE_CALLBACK_6() \
+ END_CALLBACK_INTERNAL_BEGIN( 6 ) \
END_CALLBACK_INTERNAL_SWITCH( 0 ) \
END_CALLBACK_INTERNAL_SWITCH( 1 ) \
END_CALLBACK_INTERNAL_SWITCH( 2 ) \
END_CALLBACK_INTERNAL_SWITCH( 3 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 4 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 5 ) \
END_CALLBACK_INTERNAL_END()
+#define END_DEFINE_CALLBACK_7() \
+ END_CALLBACK_INTERNAL_BEGIN( 7 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 0 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 1 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 2 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 3 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 4 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 5 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 6 ) \
+ END_CALLBACK_INTERNAL_END()
-#define END_DEFINE_CALLBACK_6( callbackname ) \
- END_CALLBACK_INTERNAL_BEGIN( callbackname, 6 ) \
+#define END_DEFINE_CALLBACK_8() \
+ END_CALLBACK_INTERNAL_BEGIN( 7 ) \
END_CALLBACK_INTERNAL_SWITCH( 0 ) \
END_CALLBACK_INTERNAL_SWITCH( 1 ) \
END_CALLBACK_INTERNAL_SWITCH( 2 ) \
END_CALLBACK_INTERNAL_SWITCH( 3 ) \
END_CALLBACK_INTERNAL_SWITCH( 4 ) \
END_CALLBACK_INTERNAL_SWITCH( 5 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 6 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 7 ) \
END_CALLBACK_INTERNAL_END()
-#define END_DEFINE_CALLBACK_7( callbackname ) \
- END_CALLBACK_INTERNAL_BEGIN( callbackname, 7 ) \
+#define END_DEFINE_CALLBACK_9() \
+ END_CALLBACK_INTERNAL_BEGIN( 7 ) \
END_CALLBACK_INTERNAL_SWITCH( 0 ) \
END_CALLBACK_INTERNAL_SWITCH( 1 ) \
END_CALLBACK_INTERNAL_SWITCH( 2 ) \
@@ -344,6 +388,8 @@ public: callbackname##_t m_Data; \
END_CALLBACK_INTERNAL_SWITCH( 4 ) \
END_CALLBACK_INTERNAL_SWITCH( 5 ) \
END_CALLBACK_INTERNAL_SWITCH( 6 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 7 ) \
+ END_CALLBACK_INTERNAL_SWITCH( 8 ) \
END_CALLBACK_INTERNAL_END()
#endif // ISTEAMCLIENT_H