Commit e4a96cd5 authored by Raphael Junqueira's avatar Raphael Junqueira Committed by Alexandre Julliard

Don't try to create HW Vertex Shaders when code is NULL (ie use

default rendering code using VertexShaderDeclaration for datas) as GL drivers don't like empty programs.
parent b42da1c5
...@@ -919,9 +919,10 @@ inline static VOID IDirect3DVertexShaderImpl_ParseProgram(IDirect3DVertexShaderI ...@@ -919,9 +919,10 @@ inline static VOID IDirect3DVertexShaderImpl_ParseProgram(IDirect3DVertexShaderI
} }
/* Generate HW shader in needed */ /* Generate HW shader in needed */
if (useHW) if (useHW && NULL != pFunction) {
IDirect3DVertexShaderImpl_GenerateProgramArbHW(vshader, pFunction); IDirect3DVertexShaderImpl_GenerateProgramArbHW(vshader, pFunction);
}
/* copy the function ... because it will certainly be released by application */ /* copy the function ... because it will certainly be released by application */
if (NULL != pFunction) { if (NULL != pFunction) {
vshader->function = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, vshader->functionLength); vshader->function = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, vshader->functionLength);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment