@@ -1465,9 +1471,14 @@ struct IWineD3DDeviceImpl const struct fragment_pipeline *frag_pipe; const struct blit_shader *blitter;
- struct ps_signature *pshader_signatures;
- unsigned int num_pshader_signatures;
- unsigned int pshader_signatures_size;
- DWORD ps_sig_number;
- unsigned int max_ffp_textures, max_ffp_texture_stages; DWORD d3d_vshader_constantF, d3d_pshader_constantF; /* Advertised d3d caps, not GL ones */
- DWORD vs_clipping;
DWORD vs_clipping, need_ps_signatures;
WORD view_ident : 1; /* true iff view matrix is identity */ WORD untransformed : 1;
@@ -2730,6 +2741,7 @@ typedef struct IWineD3DPixelShaderImpl { BOOL color0_mov; DWORD color0_reg;
- DWORD input_signature_idx;
Please keep this private to the ARB backend. (I.e., store these in struct shader_arb_priv.) Also, it looks like you're trying to write a binary search tree. Would you like to use wine_rb_tree instead?
Am Wednesday 17 June 2009 20:24:10 schrieb Henri Verbeet:
Please keep this private to the ARB backend. (I.e., store these in struct shader_arb_priv.)
That would need a shader_create callback function for the shader backend. I can sure add it, but I think it would defeat the purpose.
The other thing is that if we want to, we can use this functionality in GLSL and get rid of the shader link program and make Mesa happy.
Also, it looks like you're trying to write a binary search tree. Would you like to use wine_rb_tree instead?
Ohh, I forgot about this shiny new thing. I'll go use it.
2009/6/17 Stefan Dösinger stefan@codeweavers.com:
That would need a shader_create callback function for the shader backend. I can sure add it, but I think it would defeat the purpose.
Why does the lookup need to happen on shader creation? I think doing it from shader_arb_select() would work just as well.
The other thing is that if we want to, we can use this functionality in GLSL and get rid of the shader link program and make Mesa happy.
Mesa 7.5 should already support proper GLSL linking.
Am Wednesday 17 June 2009 20:51:43 schrieb Henri Verbeet:
2009/6/17 Stefan Dösinger stefan@codeweavers.com:
That would need a shader_create callback function for the shader backend. I can sure add it, but I think it would defeat the purpose.
Why does the lookup need to happen on shader creation? I think doing it from shader_arb_select() would work just as well.
I don't want to check the pixel shader each draw if it already has a input signature idx assigned when I can just take care of it at creation and be done with it. That also spends the time on the search when the game is showing the loading dialog vs when the game is actually running.
The other thing is that if we want to, we can use this functionality in GLSL and get rid of the shader link program and make Mesa happy.
Mesa 7.5 should already support proper GLSL linking.
Ok, that obsoletes the use for GLSL
2009/6/17 Stefan Dösinger stefan@codeweavers.com:
Am Wednesday 17 June 2009 20:51:43 schrieb Henri Verbeet:
2009/6/17 Stefan Dösinger stefan@codeweavers.com:
That would need a shader_create callback function for the shader backend. I can sure add it, but I think it would defeat the purpose.
Why does the lookup need to happen on shader creation? I think doing it from shader_arb_select() would work just as well.
I don't want to check the pixel shader each draw if it already has a input signature idx assigned when I can just take care of it at creation and be done with it. That also spends the time on the search when the game is showing the loading dialog vs when the game is actually running.
Compared to generating the actual shader, I'd say that's negligible. You're also already checking if the pixel shader has an input signature assigned in init_ps_input().