Skip to content

Commit d9bae2c

Browse files
committed
Make the pit ashy, page center fix
Updated readme as well
1 parent 4afbe37 commit d9bae2c

22 files changed

+46
-48
lines changed

Build/pxlNav.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Build/pxlRooms/CampfireEnvironment/CampfireEnvironment.js

Lines changed: 10 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Public/style/gitPage_mainStyle.css

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,18 +140,17 @@ text-shadow: 1px 1.5px 4px #252525;
140140
/* -- -- -- */
141141

142142
.gitPageContentParentStyle {
143-
max-height: 0vh;
144143
overflow: hidden;
145144
position: fixed;
146-
left: 0px;
147-
width: 100vw;
145+
width: 85vw;
148146
max-width: 1600px;
149147
height: 100vh;
150148
pointer-events: none;
151149
display: grid;
152150
justify-items: center;
153151
}
154152

153+
155154
.gpcpVisibleStyle {
156155
max-height: 100vh;
157156
}

Public/style/gitPage_pxlNavStyle.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
max-width: calc(100vw - max(5vh,5vw));
1010
position: fixed;
1111
bottom: max(4vh,4vw);
12+
justify-self: center;
1213
z-index: 2;
1314
}
1415

Public/style/gitPage_reposStyle.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
text-shadow: 2px 2px 3px rgba(0, 0, 0, .75);
66
pointer-events: auto;
77
max-height: 65vh;
8-
max-width: calc(max(min(100vw - max(6vh, 6vw), 500px), min(100vw - max(6vh, 6vw), 40vw + ((1000px - 100vw)* 5))));
8+
max-width: calc(max(min(100vw - max(7vh, 7vw), 500px), min(100vw - max(7vh, 7vw), 40vw + ((1000px - 100vw)* 5))));
99
position: fixed;
1010
right: max(max(2vh,2vw), 50vw - 750px);
1111
bottom: max(4vh,4vw);

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ Kevin Edzenga's web dev & shader resume site
77
<br/>&nbsp;&nbsp;Made as a way to show off `pxlNav`
88
###
99

10+
<img src="_show/AntibodyClub_chatImplemented.jpg" alt="procstack.github.io pxlNav environment" style="margin-left:auto;margin-right:auto;"/>
11+
<div style="margin-left:auto;margin-right:auto;">[procstack.github.io](https://procstack.github.io/)</div>
12+
13+
1014
### The Good Bits -
1115
*Wanna see the template or example rooms using 3d fbx files?*
1216
<br/>&nbsp; `./Source/pxlRooms`
@@ -36,7 +40,7 @@ I decided to release the `pxlNav` framework for `three.js` I wrote for use in th
3640
<br/>&nbsp;&nbsp;&nbsp;&nbsp;With live video feeds of our house dj and event dj, switched dynamically durring events.
3741

3842

39-
<img src="_show/10_chatImplemented.png" alt="Antib0dy.club, using pxlNav with Three.js" style="margin-left:auto;margin-right:auto;"/>
43+
<img src="_show/AntibodyClub_chatImplemented.jpg" alt="Antib0dy.club, using pxlNav with Three.js" style="margin-left:auto;margin-right:auto;"/>
4044
<div style="margin-left:auto;margin-right:auto;">(Antib0dy.Club, networking has been removed though)</div>
4145

4246

Source/js/pxlNav.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//
22
// Core pxlNav Engine
3-
export const pxlNavVersion = "0.0.13";
3+
export const pxlNavVersion = "0.0.14";
44
// Written by Kevin Edzenga 2020;2024
55

66
// -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
90.5 KB
Loading

Source/pxlRooms/CampfireEnvironment/Shaders.js

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -356,23 +356,14 @@ export function envGroundFrag(){
356356
varying float vFarMask;
357357
varying float vPitMask;
358358
359-
#define PI 3.1415926535897932384626
360359
361-
/***********************************/
362-
/** Start of THREE Shader Includs **/
363-
/***********************************/
364-
365360
struct DirLight {
366361
vec3 color;
367362
vec3 direction;
368363
};
369364
370365
uniform DirLight directionalLights[NUM_DIR_LIGHTS];
371366
372-
/*********************************/
373-
/** End of THREE Shader Includs **/
374-
/*********************************/
375-
376367
377368
// Campfire ground glow colors
378369
const vec3 firePitColor = vec3( .80, .50, .30);
@@ -498,6 +489,12 @@ export function envGroundFrag(){
498489
// Add rocky hill sides, reduce region around campfire, remove pit itself
499490
Cd.rgb = mix( Cd.rgb, rockyHillCd, vRockyMask*(1.0-vPitMask)*campfireMaskInv);
500491
492+
// Darken the center pit
493+
// Gotta add that ash!
494+
float ashMask = max(0.0, dataCd.b*vPitMask-.53);
495+
ashMask = 1.0 - min( 1.0, ashMask*ashMask*3.5)*.95;
496+
Cd.rgb = mix( Cd.rrr*.4 + Cd.rgb*(.5+dirtNoise*.5), Cd.rgb, ashMask );
497+
501498
// -- -- --
502499
503500
// -- -- -- -- -- -- -- --
@@ -512,6 +509,7 @@ export function envGroundFrag(){
512509
}
513510
// Add a fake bump map to the lighting
514511
lights = lights*baseDirtNoise;
512+
//
515513
Cd.rgb += Cd.rgb*lights;
516514
517515
// -- -- --
@@ -523,10 +521,10 @@ export function envGroundFrag(){
523521
float animWarpFit = max( animWarpCd.r, max(animWarpCd.g,animWarpCd.b) )*.8 -.2;
524522
525523
// Main Pit
526-
Cd.rgb += (firePitColor + firePitColor*animWarpFit) * (campfireMask*1.1-.1) * .25;
524+
Cd.rgb += (firePitColor + firePitColor*animWarpFit) * (campfireMask*1.1-.1) * .25 * ashMask;
527525
528526
// Region around Pit and Druid Rabbit
529-
Cd.rgb += (fireGlowColor + fireGlowColor*animWarpFit) * vPitMask * vPitMask * .15;
527+
Cd.rgb += (fireGlowColor + fireGlowColor*animWarpFit) * vPitMask * vPitMask * .15 * ashMask;
530528
531529
// -- -- --
532530
@@ -540,6 +538,7 @@ export function envGroundFrag(){
540538
shade *= dataCd.r;
541539
Cd.rgb= mix( Cd.rgb*shade, fogColor, depth );
542540
541+
543542
gl_FragColor=Cd;
544543
}`;
545544
return ret;
@@ -626,7 +625,6 @@ export function campfireLogFrag(){
626625
627626
varying float vFlicker;
628627
629-
#define PI 3.14159265358979
630628
631629
void main(){
632630
float timer = time.x*0.05;

_show/10_chatImplemented.png

-3.93 MB
Binary file not shown.

0 commit comments

Comments
 (0)