feat: proper csr
This commit is contained in:
parent
26b393a719
commit
62a301a4ef
4 changed files with 21 additions and 14 deletions
23
.idea/workspace.xml
generated
23
.idea/workspace.xml
generated
|
@ -7,13 +7,11 @@
|
|||
<cargoProject FILE="$PROJECT_DIR$/Cargo.toml" />
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="2d855648-9644-469a-afa2-59beb52bb1d6" name="Changes" comment="csr rendering v2">
|
||||
<change afterPath="$PROJECT_DIR$/client/src/lib/map/default_palettes.ts" afterDir="false" />
|
||||
<list default="true" id="2d855648-9644-469a-afa2-59beb52bb1d6" name="Changes" comment="feat: client-side rendering">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/client/package.json" beforeDir="false" afterPath="$PROJECT_DIR$/client/package.json" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/client/src/lib/Map.svelte" beforeDir="false" afterPath="$PROJECT_DIR$/client/src/lib/Map.svelte" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/client/src/lib/ToolbarProductSelector.svelte" beforeDir="false" afterPath="$PROJECT_DIR$/client/src/lib/ToolbarProductSelector.svelte" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/client/src/lib/map/fragment.glsl" beforeDir="false" afterPath="$PROJECT_DIR$/client/src/lib/map/fragment.glsl" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/crates/pal/src/lib.rs" beforeDir="false" afterPath="$PROJECT_DIR$/crates/pal/src/lib.rs" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
|
@ -21,7 +19,7 @@
|
|||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="DarkyenusTimeTracker">
|
||||
<option name="totalTimeSeconds" value="14770" />
|
||||
<option name="totalTimeSeconds" value="15293" />
|
||||
</component>
|
||||
<component name="FileTemplateManagerImpl">
|
||||
<option name="RECENT_TEMPLATES">
|
||||
|
@ -63,7 +61,7 @@
|
|||
"vue.rearranger.settings.migration": "true"
|
||||
}
|
||||
}</component>
|
||||
<component name="RunManager" selected="Cargo.Run wxbox-ar2">
|
||||
<component name="RunManager">
|
||||
<configuration name="Run wxbox-ar2" type="CargoCommandRunConfiguration" factoryName="Cargo Command">
|
||||
<option name="command" value="run --package wxbox-ar2 --bin wxbox-ar2" />
|
||||
<option name="workingDirectory" value="file://$PROJECT_DIR$" />
|
||||
|
@ -173,7 +171,15 @@
|
|||
<option name="project" value="LOCAL" />
|
||||
<updated>1748704540785</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="5" />
|
||||
<task id="LOCAL-00005" summary="feat: client-side rendering">
|
||||
<option name="closed" value="true" />
|
||||
<created>1748709699337</created>
|
||||
<option name="number" value="00005" />
|
||||
<option name="presentableId" value="LOCAL-00005" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1748709699337</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="6" />
|
||||
<servers />
|
||||
</component>
|
||||
<component name="TypeScriptGeneratedFilesManager">
|
||||
|
@ -185,6 +191,7 @@
|
|||
<MESSAGE value="debugging" />
|
||||
<MESSAGE value="mostly functional v2 rendering" />
|
||||
<MESSAGE value="csr rendering v2" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="csr rendering v2" />
|
||||
<MESSAGE value="feat: client-side rendering" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="feat: client-side rendering" />
|
||||
</component>
|
||||
</project>
|
|
@ -127,6 +127,7 @@
|
|||
}
|
||||
});
|
||||
};
|
||||
map.setMaxZoom(13);
|
||||
map.on('click', 'alerts', (e) => {
|
||||
createPopup(e, true);
|
||||
});
|
||||
|
@ -174,6 +175,7 @@
|
|||
const dataLayer = {
|
||||
id: 'dataGl',
|
||||
type: 'custom',
|
||||
maxZoom: 13,
|
||||
onAdd(map, gl) {
|
||||
const vertexShader = gl.createShader(gl.VERTEX_SHADER);
|
||||
gl.shaderSource(vertexShader, vertexSource);
|
||||
|
@ -337,6 +339,9 @@
|
|||
gl.uniform1i(gl.getUniformLocation(this.program, 'color2Data'), 13);
|
||||
},
|
||||
render(gl, args) {
|
||||
gl.enable(gl.SAMPLE_COVERAGE);
|
||||
gl.sampleCoverage(1.0, false);
|
||||
|
||||
gl.activeTexture(gl.TEXTURE0 + 10);
|
||||
gl.bindTexture(gl.TEXTURE_2D, this.texture);
|
||||
gl.activeTexture(gl.TEXTURE0 + 11);
|
||||
|
|
|
@ -175,11 +175,6 @@
|
|||
currentlySelectingFor = item.id;
|
||||
map.on('click', `select-${item.id}`, (e) => {
|
||||
if (e && e.features) {
|
||||
map.flyTo({
|
||||
// @ts-expect-error it's fine, shhhh
|
||||
center: e.features[0].geometry.coordinates,
|
||||
zoom: 5
|
||||
});
|
||||
// did we already have a site set?
|
||||
let alreadyHadSite = selectedSite != null;
|
||||
pickingSiteForCategory = false;
|
||||
|
|
|
@ -61,7 +61,6 @@ void main() {
|
|||
}
|
||||
|
||||
int gate_number = int(floor((distance_meters - 2125.0) / 250.0));
|
||||
|
||||
float rawValue = texelFetch(data, ivec2(gate_number, azimuthNumber), 0).r;
|
||||
|
||||
// colorize!
|
||||
|
@ -83,6 +82,7 @@ void main() {
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
fragColor = vec4(0,0,0,0);
|
||||
return;
|
||||
}
|
Loading…
Add table
Reference in a new issue