-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Need to quit reinventing the wheel here. I think a back port of the renderscript Matrix?f classes may be more suitable.
- Loading branch information
Showing
14 changed files
with
139 additions
and
18 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
precision highp float; | ||
varying vec2 v_texcoord; | ||
|
||
uniform sampler2D n_sampler; | ||
|
||
void main() { | ||
vec4 v_tex = texture2D(n_sampler, v_texcoord); | ||
if(v_tex.x > .5 && v_tex.y > .5 && v_tex.z > .5) | ||
discard; | ||
gl_FragColor = v_tex; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
precision highp float; | ||
|
||
attribute vec3 v_pos; | ||
attribute vec2 v_tex; | ||
|
||
varying vec2 v_texcoord; | ||
|
||
uniform mat4 t_modelview_projection; | ||
|
||
uniform vec3 v_up, v_right; | ||
|
||
void main() { | ||
vec3 v_corner = v_pos + (v_tex.x * 2.0 - 1.0) * v_right + (1.0 - v_tex.y * 2.0) * v_up; | ||
gl_Position = t_modelview_projection * vec4(v_corner, 1.0); | ||
|
||
v_texcoord = v_tex; | ||
} |
File renamed without changes.
File renamed without changes.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters