Revision 50642a86
Added by Leszek Koltunski about 7 years ago
src/main/java/org/distorted/library/DistortedNode.java | ||
---|---|---|
54 | 54 |
{ |
55 | 55 |
long ID; |
56 | 56 |
int numPointingNodes; |
57 |
int numRender;
|
|
57 |
long currTime;
|
|
58 | 58 |
ArrayList<Long> key; |
59 | 59 |
DistortedFramebuffer mFBO; |
60 | 60 |
|
... | ... | |
63 | 63 |
ID = id; |
64 | 64 |
key = k; |
65 | 65 |
numPointingNodes= 1; |
66 |
numRender =-1;
|
|
66 |
currTime =-1;
|
|
67 | 67 |
mFBO = null; |
68 | 68 |
} |
69 | 69 |
} |
... | ... | |
197 | 197 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
198 | 198 |
// return the total number of render calls issued |
199 | 199 |
|
200 |
int drawRecursive(int renderNum, long currTime, DistortedOutputSurface surface)
|
|
200 |
int drawRecursive(long currTime, DistortedOutputSurface surface) |
|
201 | 201 |
{ |
202 | 202 |
int ret = 0; |
203 | 203 |
|
204 |
if( mNumChildren[0]>0 && mData.numRender!=renderNum )
|
|
204 |
if( mNumChildren[0]>0 && mData.currTime!=currTime )
|
|
205 | 205 |
{ |
206 |
mData.numRender = renderNum;
|
|
206 |
mData.currTime = currTime;
|
|
207 | 207 |
mData.mFBO.setAsOutput(); |
208 | 208 |
|
209 | 209 |
GLES30.glClearColor(0.0f, 0.0f, 0.0f, 0.0f); |
... | ... | |
217 | 217 |
|
218 | 218 |
for(int i=0; i<mNumChildren[0]; i++) |
219 | 219 |
{ |
220 |
ret += mChildren.get(i).drawRecursive(renderNum, currTime, mData.mFBO);
|
|
220 |
ret += mChildren.get(i).drawRecursive(currTime, mData.mFBO); |
|
221 | 221 |
} |
222 | 222 |
} |
223 | 223 |
|
Also available in: Unified diff
Simplify drawRecursive