Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
angle
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
angle
Commits
313e3924
Commit
313e3924
authored
Oct 31, 2012
by
daniel@transgaming.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move Sharehandle support query to renderer
Trac #21727 git-svn-id:
https://angleproject.googlecode.com/svn/branches/dx11proto@1330
736b8ea6-26fd-11df-bfd4-992fa37f6226
parent
621ce053
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
11 additions
and
11 deletions
+11
-11
Display.cpp
src/libEGL/Display.cpp
+3
-9
Display.h
src/libEGL/Display.h
+0
-1
Surface.cpp
src/libEGL/Surface.cpp
+1
-1
Renderer.cpp
src/libGLESv2/renderer/Renderer.cpp
+6
-0
Renderer.h
src/libGLESv2/renderer/Renderer.h
+1
-0
No files found.
src/libEGL/Display.cpp
View file @
313e3924
...
@@ -669,6 +669,7 @@ void Display::freeEventQuery(IDirect3DQuery9* query)
...
@@ -669,6 +669,7 @@ void Display::freeEventQuery(IDirect3DQuery9* query)
void
Display
::
initExtensionString
()
void
Display
::
initExtensionString
()
{
{
HMODULE
swiftShader
=
GetModuleHandle
(
TEXT
(
"swiftshader_d3d9.dll"
));
HMODULE
swiftShader
=
GetModuleHandle
(
TEXT
(
"swiftshader_d3d9.dll"
));
bool
shareHandleSupported
=
mRenderer
->
getShareHandleSupport
();
mExtensionString
=
""
;
mExtensionString
=
""
;
...
@@ -676,7 +677,7 @@ void Display::initExtensionString()
...
@@ -676,7 +677,7 @@ void Display::initExtensionString()
mExtensionString
+=
"EGL_EXT_create_context_robustness "
;
mExtensionString
+=
"EGL_EXT_create_context_robustness "
;
// ANGLE-specific extensions
// ANGLE-specific extensions
if
(
shareHandleSupported
()
)
if
(
shareHandleSupported
)
{
{
mExtensionString
+=
"EGL_ANGLE_d3d_share_handle_client_buffer "
;
mExtensionString
+=
"EGL_ANGLE_d3d_share_handle_client_buffer "
;
}
}
...
@@ -688,7 +689,7 @@ void Display::initExtensionString()
...
@@ -688,7 +689,7 @@ void Display::initExtensionString()
mExtensionString
+=
"EGL_ANGLE_software_display "
;
mExtensionString
+=
"EGL_ANGLE_software_display "
;
}
}
if
(
shareHandleSupported
()
)
if
(
shareHandleSupported
)
{
{
mExtensionString
+=
"EGL_ANGLE_surface_d3d_texture_2d_share_handle "
;
mExtensionString
+=
"EGL_ANGLE_surface_d3d_texture_2d_share_handle "
;
}
}
...
@@ -707,13 +708,6 @@ const char *Display::getExtensionString() const
...
@@ -707,13 +708,6 @@ const char *Display::getExtensionString() const
return
mExtensionString
.
c_str
();
return
mExtensionString
.
c_str
();
}
}
bool
Display
::
shareHandleSupported
()
const
{
// PIX doesn't seem to support using share handles, so disable them.
// D3D9_REPLACE
return
mRenderer
->
isD3d9ExDevice
()
&&
!
gl
::
perfActive
();
}
IDirect3DVertexShader9
*
Display
::
createVertexShader
(
const
DWORD
*
function
,
size_t
length
)
IDirect3DVertexShader9
*
Display
::
createVertexShader
(
const
DWORD
*
function
,
size_t
length
)
{
{
return
mVertexShaderCache
.
create
(
function
,
length
);
return
mVertexShaderCache
.
create
(
function
,
length
);
...
...
src/libEGL/Display.h
View file @
313e3924
...
@@ -66,7 +66,6 @@ class Display
...
@@ -66,7 +66,6 @@ class Display
virtual
void
notifyDeviceLost
();
virtual
void
notifyDeviceLost
();
const
char
*
getExtensionString
()
const
;
const
char
*
getExtensionString
()
const
;
bool
shareHandleSupported
()
const
;
virtual
IDirect3DVertexShader9
*
createVertexShader
(
const
DWORD
*
function
,
size_t
length
);
virtual
IDirect3DVertexShader9
*
createVertexShader
(
const
DWORD
*
function
,
size_t
length
);
virtual
IDirect3DPixelShader9
*
createPixelShader
(
const
DWORD
*
function
,
size_t
length
);
virtual
IDirect3DPixelShader9
*
createPixelShader
(
const
DWORD
*
function
,
size_t
length
);
...
...
src/libEGL/Surface.cpp
View file @
313e3924
...
@@ -204,7 +204,7 @@ bool Surface::resetSwapChain(int backbufferWidth, int backbufferHeight)
...
@@ -204,7 +204,7 @@ bool Surface::resetSwapChain(int backbufferWidth, int backbufferHeight)
mShareHandle
=
NULL
;
mShareHandle
=
NULL
;
HANDLE
*
pShareHandle
=
NULL
;
HANDLE
*
pShareHandle
=
NULL
;
if
(
!
mWindow
&&
mDisplay
->
shareHandleSupported
())
if
(
!
mWindow
&&
renderer
->
getShareHandleSupport
())
{
{
pShareHandle
=
&
mShareHandle
;
pShareHandle
=
&
mShareHandle
;
}
}
...
...
src/libGLESv2/renderer/Renderer.cpp
View file @
313e3924
...
@@ -573,6 +573,12 @@ bool Renderer::getInstancingSupport() const
...
@@ -573,6 +573,12 @@ bool Renderer::getInstancingSupport() const
return
mDeviceCaps
.
PixelShaderVersion
>=
D3DPS_VERSION
(
3
,
0
);
return
mDeviceCaps
.
PixelShaderVersion
>=
D3DPS_VERSION
(
3
,
0
);
}
}
bool
Renderer
::
getShareHandleSupport
()
const
{
// PIX doesn't seem to support using share handles, so disable them.
// D3D9_REPLACE
return
isD3d9ExDevice
()
&&
!
gl
::
perfActive
();
}
D3DPOOL
Renderer
::
getBufferPool
(
DWORD
usage
)
const
D3DPOOL
Renderer
::
getBufferPool
(
DWORD
usage
)
const
{
{
...
...
src/libGLESv2/renderer/Renderer.h
View file @
313e3924
...
@@ -95,6 +95,7 @@ class Renderer
...
@@ -95,6 +95,7 @@ class Renderer
virtual
bool
getOcclusionQuerySupport
()
const
;
virtual
bool
getOcclusionQuerySupport
()
const
;
virtual
bool
getInstancingSupport
()
const
;
virtual
bool
getInstancingSupport
()
const
;
virtual
float
getTextureFilterAnisotropySupport
()
const
;
virtual
float
getTextureFilterAnisotropySupport
()
const
;
virtual
bool
getShareHandleSupport
()
const
;
virtual
D3DPOOL
getBufferPool
(
DWORD
usage
)
const
;
virtual
D3DPOOL
getBufferPool
(
DWORD
usage
)
const
;
virtual
D3DPOOL
getTexturePool
(
DWORD
usage
)
const
;
virtual
D3DPOOL
getTexturePool
(
DWORD
usage
)
const
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment