Project

General

Profile

« Previous | Next » 

Revision e8c81a8e

Added by Leszek Koltunski almost 8 years ago

Cleanup, consistent variable names, minor details.

View differences:

src/main/java/org/distorted/library/EffectQueueFragment.java
80 80
          EffectMessageSender.newMessage( mListeners.elementAt(j),
81 81
                                          EffectMessage.EFFECT_FINISHED,
82 82
                                          (mID[i]<<EffectTypes.LENGTH)+EffectTypes.FRAGMENT.type,
83
                                          mType[i], 
83
                                          mName[i],
84 84
                                          mBitmapID,
85 85
                                          null);
86 86
      
87
        if( EffectNames.isUnity(mType[i], mUniforms, NUM_UNIFORMS*i) )
87
        if( EffectNames.isUnity(mName[i], mUniforms, NUM_UNIFORMS*i) )
88 88
          {
89 89
          remove(i);
90 90
          i--;
91 91
          continue;
92 92
          }
93
        else mInter[0][i] = null;
93 94
        }
94 95

  
95 96
      if( mInter[1][i]!=null ) mInter[1][i].interpolateMain(     mBuf,            4*i  , mCurrentDuration[i]);
......
125 126
      
126 127
    if( mNumEffects>0 )
127 128
      {     
128
      GLES20.glUniform1iv( mTypeH    ,  mNumEffects, mType    ,0);
129
      GLES20.glUniform1iv( mTypeH    ,  mNumEffects, mName,0);
129 130
      GLES20.glUniform4fv( mUniformsH,2*mNumEffects, mUniforms,0);
130 131
      }  
131 132
    }
......
160 161
        mUniforms[NUM_UNIFORMS*i+6] = w*mBuf[4*i+2];                                  // in fragment shader rx and ry radii are the last two values of the second vec4
161 162
        mUniforms[NUM_UNIFORMS*i+7] = h*mBuf[4*i+3];                                  //
162 163

  
163
        if( mType[i]==EffectNames.MACROBLOCK.ordinal() ) // fill up the .y and .z components of the Interpolated values already to avoid having to compute this in the fragment shader
164
        if( mName[i]==EffectNames.MACROBLOCK.ordinal() ) // fill up the .y and .z components of the Interpolated values already to avoid having to compute this in the fragment shader
164 165
          {
165 166
          mUniforms[NUM_UNIFORMS*i+1] = 2.0f*mObjHalfX/mUniforms[NUM_UNIFORMS*i];
166 167
          mUniforms[NUM_UNIFORMS*i+2] = 2.0f*mObjHalfY/mUniforms[NUM_UNIFORMS*i];

Also available in: Unified diff