-
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.
Merge pull request #1 from geoblocks/GEORD-605_building_illumination
Building illumination
- Loading branch information
Showing
18 changed files
with
381 additions
and
8 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"recommendations": ["redhat.vscode-yaml", "runem.lit-plugin"] | ||
} |
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 |
---|---|---|
@@ -1,3 +1,6 @@ | ||
{ | ||
"files.associations": {"*.json": "jsonc"} | ||
"files.associations": { | ||
"*.json": "jsonc" | ||
}, | ||
"lit-plugin.strict": true | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../node_modules/@cesium/engine/Source/Assets/ |
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 @@ | ||
../node_modules/@cesium/engine/Build/Workers/ |
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,10 @@ | ||
# Digital twins: illumination / solar | ||
|
||
Municipalities: a common use-case for digital twins is to see how shadows are cast by buildings, relief and vegetation. | ||
|
||
- Display a base 3D tileset with buildings | ||
- Position the sun according to some date | ||
- Be able to easily change day / time | ||
- Color roofs / walls? depending on angle with the sun. | ||
- does it make sense? (instantaneous and does not take into account the shades) | ||
- require the information to be part of the 3d-tiles? |
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,32 @@ | ||
{ | ||
"header": { | ||
"languages": ["de", "fr", "en", "it"], | ||
"title": { | ||
"fr": "Ma super app", | ||
"en": "My super app", | ||
"de": "Meine supper app", | ||
"it": "Mia super app" | ||
} | ||
}, | ||
"footer": { | ||
"contact": "[email protected]", | ||
"impressum": { | ||
"fr": "Bla bla FR impressim", | ||
"en": "Bla bla EN impressim", | ||
"de": "Bla bla DE impressim", | ||
"it": "Bla bla IT impressim" | ||
} | ||
}, | ||
"app": { | ||
"terrain": "https://3d.geo.admin.ch/ch.swisstopo.terrain.3d/v1/", | ||
"buildings": "https://vectortiles0.geo.admin.ch/3d-tiles/ch.swisstopo.swisstlm3d.3d/20201020/tileset.json", | ||
"vegetation": "https://vectortiles.geo.admin.ch/3d-tiles/ch.swisstopo.vegetation.3d/20190313/tileset.json", | ||
"initialView": { | ||
"destination": [6.628484, 46.5, 1000], | ||
"orientation": { | ||
"heading": 0, | ||
"pitch": -30.0 | ||
} | ||
} | ||
} | ||
} |
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,15 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" type="image/svg+xml" href="/logo.svg" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Revolutionary illumination / solar app</title> | ||
<!-- <link rel="stylesheet" href="./src/index.css" /> --> | ||
<script type="module" src="./index.ts"></script> | ||
</head> | ||
<body> | ||
<noscript>Enable JS!</noscript> | ||
<ngv-app-illumination></ngv-app-illumination> | ||
</body> | ||
</html> |
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,37 @@ | ||
import {html} from 'lit'; | ||
import {customElement} from 'lit/decorators.js'; | ||
|
||
import '../../structure/ngv-structure-app.js'; | ||
|
||
// // @ts-expect-error ?url parameter is a viteJS specificity | ||
// import logoUrl from "../../logo.svg?url"; | ||
import {localized} from '@lit/localize'; | ||
import {ABaseApp} from '../../structure/BaseApp.js'; | ||
|
||
// @ts-expect-error viteJS specific import | ||
import configUrl from './defaultConfig.json?url'; | ||
|
||
import './ngv-main-illumination.js'; | ||
import {IIlluminationConfig} from './ingv-config-illumination.js'; | ||
|
||
@customElement('ngv-app-illumination') | ||
@localized() | ||
export class NgvAppIllumination extends ABaseApp<IIlluminationConfig> { | ||
constructor() { | ||
super(configUrl as string); | ||
} | ||
|
||
render() { | ||
const r = super.render(); | ||
if (r) { | ||
return r; | ||
} | ||
return html` | ||
<ngv-structure-app .config=${this.config}> | ||
<ngv-main-illumination | ||
.config=${this.config.app} | ||
></ngv-main-illumination> | ||
</ngv-structure-app> | ||
`; | ||
} | ||
} |
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,16 @@ | ||
import {INgvStructureApp} from '../../structure/ngv-structure-app.js'; | ||
|
||
export interface IIlluminationConfig extends INgvStructureApp { | ||
app: { | ||
terrain: string; | ||
buildings: string; | ||
vegetation: string; | ||
initialView: { | ||
destination: [number, number, number]; | ||
orientation: { | ||
heading: number; | ||
pitch: number; | ||
}; | ||
}; | ||
}; | ||
} |
Oops, something went wrong.