Skip to content
This repository has been archived by the owner on Aug 30, 2023. It is now read-only.

Commit

Permalink
Merge pull request #7 from vanaf/master
Browse files Browse the repository at this point in the history
Avoid using floats due to issue on Exynos devices
  • Loading branch information
HalfdanJ committed Mar 26, 2018
2 parents b546cfb + 4434056 commit 0c42e94
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/src/main/res/raw/line_frag.glsl
Expand Up @@ -21,13 +21,13 @@ void main() {

if(drawMode > 0.0){
if(depth <= nearCutOff){
c.gb *= map(depth, nearCutOff, nearCutOff * 0.95f, 0.0, 1.0);
c.gb *= map(depth, nearCutOff, nearCutOff * 0.95, 0.0, 1.0);
}
if(depth > nearCutOff && depth < farCutOff){
c.gb *= 0.0f;
c.gb *= 0.0;
}
if(depth >= farCutOff){
c.gb *= map(depth, farCutOff, farCutOff * 1.05f, 0.0, 1.0);
c.gb *= map(depth, farCutOff, farCutOff * 1.05, 0.0, 1.0);
}
}

Expand Down

0 comments on commit 0c42e94

Please sign in to comment.