mirror of
https://github.com/nillerusr/source-engine.git
synced 2026-08-12 03:39:10 +00:00
macOS build support
This commit is contained in:
@@ -5326,7 +5326,7 @@ HRESULT IDirect3DDevice9::DrawPrimitiveUP(D3DPRIMITIVETYPE PrimitiveType,UINT Pr
|
||||
// [in] Number of primitives to render. The number of vertices used is a function of the primitive count and the primitive type. The maximum number of primitives allowed is determined by checking the MaxPrimitiveCount member of the D3DCAPS9 structure.
|
||||
|
||||
// BE VERY CAREFUL what you do in this function. It's extremely hot, and calling the wrong GL API's in here will crush perf. on NVidia threaded drivers.
|
||||
#ifndef OSX
|
||||
#if 1 //ifndef OSX
|
||||
|
||||
HRESULT IDirect3DDevice9::DrawIndexedPrimitive( D3DPRIMITIVETYPE Type, INT BaseVertexIndex, UINT MinVertexIndex, UINT NumVertices, UINT startIndex, UINT primCount )
|
||||
{
|
||||
|
||||
@@ -2692,6 +2692,7 @@ GLMContext::GLMContext( IDirect3DDevice9 *pDevice, GLMDisplayParams *params )
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
if ( m_caps.m_badDriver108Intel )
|
||||
{
|
||||
// this way we have something to look for in terminal spew if users report issues related to this in the future.
|
||||
@@ -2701,6 +2702,7 @@ GLMContext::GLMContext( IDirect3DDevice9 *pDevice, GLMDisplayParams *params )
|
||||
Warning( "Unable to enable OSX 10.8 / Intel HD4000 workaround, there might be crashes.\n" );
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
#endif
|
||||
// also, set the remote convar "gl_can_query_fast" to 1 if perf package present, else 0.
|
||||
@@ -4899,7 +4901,7 @@ static inline uint GetDataTypeSizeInBytes( GLenum dataType )
|
||||
return 0;
|
||||
}
|
||||
|
||||
#ifndef OSX
|
||||
#if 1 //ifndef OSX
|
||||
|
||||
void GLMContext::DrawRangeElementsNonInline( GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, uint baseVertex, CGLMBuffer *pIndexBuf )
|
||||
{
|
||||
|
||||
+6
-1
@@ -23,7 +23,6 @@ def build(bld):
|
||||
'linuxwin/glentrypoints.cpp',
|
||||
'linuxwin/glmgr.cpp',
|
||||
'linuxwin/glmgrbasics.cpp',
|
||||
#'linuxwin/glmgrcocoa.mm', [$OSXALL]
|
||||
#'linuxwin/intelglmallocworkaround.cpp', [$OSXALL]
|
||||
#'linuxwin/mach_override.c', [$OSXALL]
|
||||
'linuxwin/cglmtex.cpp',
|
||||
@@ -35,6 +34,9 @@ def build(bld):
|
||||
'linuxwin/decompress.c'
|
||||
]
|
||||
|
||||
if bld.env.DEST_OS == "darwin":
|
||||
source += ['linuxwin/glmgrcocoa.mm']
|
||||
|
||||
includes = [
|
||||
'.',
|
||||
'../public',
|
||||
@@ -46,6 +48,9 @@ def build(bld):
|
||||
|
||||
libs = ['tier0','tier1','tier2','vstdlib','mathlib']
|
||||
|
||||
if bld.env.DEST_OS == "darwin":
|
||||
libs += ["OPENGL", "CARBON"]
|
||||
|
||||
install_path = bld.env.LIBDIR
|
||||
|
||||
bld.shlib(
|
||||
|
||||
Reference in New Issue
Block a user