mirror of
https://github.com/alliedmodders/hl2sdk.git
synced 2025-09-19 20:16:10 +08:00
Updated IMemAlloc interface from tier0 and added note in icvar.h about freeing ICvarIteratorInternal.
This commit is contained in:
@ -120,6 +120,15 @@ public:
|
|||||||
virtual void QueueMaterialThreadSetValue( ConVar *, float ) = 0;
|
virtual void QueueMaterialThreadSetValue( ConVar *, float ) = 0;
|
||||||
virtual bool HasQueuedMaterialThreadConVarSets() const = 0;
|
virtual bool HasQueuedMaterialThreadConVarSets() const = 0;
|
||||||
virtual int ProcessQueuedMaterialThreadConVarSets() = 0;
|
virtual int ProcessQueuedMaterialThreadConVarSets() = 0;
|
||||||
|
|
||||||
|
// Returns a cvar iterator pointer.
|
||||||
|
//
|
||||||
|
// If memoverride is not used, use g_pMemAlloc->Free() to deallocate the memory
|
||||||
|
// used by these iterators.
|
||||||
|
//
|
||||||
|
// If memoverride is used, you can use the delete operator even though there
|
||||||
|
// is no virtual destructor. This can be done because memoverride overloads the
|
||||||
|
// delete operator so that it will call g_pMemAlloc-Free().
|
||||||
virtual ICvarIteratorInternal *FactoryInternalIterator() = 0;
|
virtual ICvarIteratorInternal *FactoryInternalIterator() = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -75,6 +75,8 @@ public:
|
|||||||
virtual void DumpStats() = 0;
|
virtual void DumpStats() = 0;
|
||||||
virtual void DumpStatsFileBase( char const *pchFileBase ) = 0;
|
virtual void DumpStatsFileBase( char const *pchFileBase ) = 0;
|
||||||
|
|
||||||
|
virtual size_t ComputeMemoryUsedBy( const char *pFileName ) = 0;
|
||||||
|
|
||||||
// FIXME: Remove when we have our own allocator
|
// FIXME: Remove when we have our own allocator
|
||||||
virtual void* CrtSetReportFile( int nRptType, void* hFile ) = 0;
|
virtual void* CrtSetReportFile( int nRptType, void* hFile ) = 0;
|
||||||
virtual void* CrtSetReportHook( void* pfnNewHook ) = 0;
|
virtual void* CrtSetReportHook( void* pfnNewHook ) = 0;
|
||||||
@ -104,6 +106,9 @@ public:
|
|||||||
|
|
||||||
// Returns 0 if no failure, otherwise the size_t of the last requested chunk
|
// Returns 0 if no failure, otherwise the size_t of the last requested chunk
|
||||||
virtual size_t MemoryAllocFailed() = 0;
|
virtual size_t MemoryAllocFailed() = 0;
|
||||||
|
|
||||||
|
virtual void CompactIncremental() = 0;
|
||||||
|
virtual void OutOfMemory( size_t ) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
Reference in New Issue
Block a user