Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
JoseETeixeira committed Dec 12, 2021
1 parent 7bf3741 commit 7d0f42b
Showing 1 changed file with 0 additions and 28 deletions.
28 changes: 0 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,31 +43,3 @@ cd third_party/boost

https://github.com/bobbahbrown/DMISharp/blob/master/DMISharp/DMIFile.cs


# OPEN CV
https://docs.opencv.org/4.x/d7/d9f/tutorial_linux_install.html


const float verts[] = {
posX, posY,
posX + spriteWidth, posY,
posX + spriteWidth, posY + spriteHeight,
posX, posY + spriteHeight
};
const float tw = float(spriteWidth) / texWidth;
const float th = float(spriteHeight) / texHeight;
const int numPerRow = texWidth / spriteWidth;
const float tx = (frameIndex % numPerRow) * tw;
const float ty = (frameIndex / numPerRow + 1) * th;
const float texVerts[] = {
tx, ty,
tx + tw, ty,
tx + tw, ty + th,
tx, ty + th
};

// ... Bind the texture, enable the proper arrays

glVertexPointer(2, GL_FLOAT, verts);
glTexCoordPointer(2, GL_FLOAT, texVerts);
glDrawArrays(GL_TRI_STRIP, 0, 4);

0 comments on commit 7d0f42b

Please sign in to comment.