opengl 2.0 - openGL2.0: How to disable vertex shaders? -


i trying capture traces game glinterceptor use doesn't support vertex shaders. research suggests disable vertex shaders , use default vertex shader no information how it. so, how can disable vertex shaders? here code:

pp.fx

#define disable_fog #define disable_lighting  technique default {   pass p0   {     vertexshader = vertexshaders/diff-tex.vs;     pixelshader = pixelshaders/pp.ps;      #ifdef enable_twosided         enableculling = false;     #endif      #ifdef disable_depth_test         enabledepthtest = false;     #endif      #ifdef enable_additive         enabledepthmask = false;         enableblending = true;         blendfuncsrc = one;         blendfuncdst = one;     #endif      #ifdef enable_multiplicative         enabledepthmask = false;         enableblending = true;         blendfuncsrc = dst_color;         blendfuncdst = zero;     #endif      #ifdef enable_alpha_blending         enabledepthmask = false;         enableblending = true;         blendfuncsrc = src_alpha;         blendfuncdst = one_minus_src_alpha;     #endif      #ifdef enable_premult_alpha_blending         enabledepthmask = false;         enableblending = true;         blendfuncsrc = one;         blendfuncdst = one_minus_src_alpha;     #endif   } } 

diff-tex.vs

#include "../commons/defines.sh" #include "../commons/attributes.sh" #include "../commons/uniforms.sh" #include "../commons/functions.sh" #include "../commons/varyings.sh"  void main() {   #ifdef enable_skinning     // bone 1 influence     int = int(dt_boneindices.x);     float w = dt_boneweights.x;     mat4 bonetm = boneworldtm[i];     vec3 worldpos = transform(bonetm, dt_position) * w;      #ifndef disable_lighting     v_normal = rotate( converttomat3(bonetm), dt_normal ) * w;     #endif      #ifdef enable_normalmap     vec3 worldtangent = rotate( converttomat3(bonetm), dt_tangent ) * w;     #endif      // bone 2 influence     = int(dt_boneindices.y);     w = dt_boneweights.y;     bonetm = boneworldtm[i];     worldpos += transform(bonetm, dt_position) * w;      #ifndef disable_lighting     v_normal += rotate( converttomat3(bonetm), dt_normal ) * w;     #endif      #ifdef enable_normalmap     worldtangent += rotate( converttomat3(bonetm), dt_tangent ) * w;     #endif      // bone 3 influence     = int(dt_boneindices.z);     w = (1.0 - dt_boneweights.y - dt_boneweights.x);     bonetm = boneworldtm[i];     worldpos += transform(bonetm, dt_position) * w;      // can omitted optimization, effect quite small     #ifndef disable_lighting     v_normal += rotate( converttomat3(bonetm), dt_normal ) * w;     v_normal = normalize(v_normal);     #endif      #ifdef enable_normalmap     worldtangent += rotate( converttomat3(bonetm), dt_tangent ) * w;     worldtangent = normalize(worldtangent);      vec3 worldbinormal = cross( v_normal, worldtangent );     #endif      gl_position = viewprojtm * vec4(worldpos, 1); #else      #if defined(disable_transform_except_orientation)     // vertices in screen space coordinates     gl_position = projtm * vec4(dt_position, 1);     #elif defined(disable_transform)     gl_position = vec4(dt_position, 1);     #else     // transform coordinates screen space     gl_position = totaltm * vec4(dt_position, 1);     vec3 worldpos = vec3(worldtm * vec4(dt_position, 1));     #endif #endif } 


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

thorough guide for profiling racket code -