Skip to content

Commit fe4ada1

Browse files
committed
Merge branch 'release/0.4'
2 parents b2a107d + 6c95186 commit fe4ada1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+3054
-999
lines changed

LICENSE

Lines changed: 47 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,50 @@
1-
BSD 3-Clause License
1+
"I'm So Tired" Software License 1.0 (No-Resale ver.)
22

33
Copyright (c) 2024, EepyBerry
44

5-
Redistribution and use in source and binary forms, with or without
6-
modification, are permitted provided that the following conditions are met:
7-
8-
1. Redistributions of source code must retain the above copyright notice, this
9-
list of conditions and the following disclaimer.
10-
11-
2. Redistributions in binary form must reproduce the above copyright notice,
12-
this list of conditions and the following disclaimer in the documentation
13-
and/or other materials provided with the distribution.
14-
15-
3. Neither the name of the copyright holder nor the names of its
16-
contributors may be used to endorse or promote products derived from
17-
this software without specific prior written permission.
18-
19-
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20-
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21-
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22-
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23-
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24-
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25-
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26-
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27-
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28-
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
5+
This is anti-capitalist, anti-bigotry software, made by people who are tired of
6+
ill-intended organisations and individuals, and would rather not have those
7+
around their creations.
8+
9+
Permission is granted, free of charge, to any user (be they a person or an
10+
organisation) obtaining a copy of this software, to use it for personal,
11+
commercial, or educational purposes, subject to the following conditions:
12+
13+
1. The above copyright notice and this permission notice shall be included in
14+
all copies or modified versions of this software.
15+
16+
2. The user is one of the following:
17+
a. an individual person, labouring for themselves
18+
b. a non-profit organisation
19+
c. an educational institution
20+
d. an organization that seeks shared profit for all of its members, and
21+
allows non-members to set the cost of their labor
22+
23+
3. If the user is an organization with owners, then all owners are workers and
24+
all workers are owners with equal equity and/or equal vote.
25+
26+
4. If the user is an organization, then the user is not law enforcement or
27+
military, or working for or under either.
28+
29+
5. The user does not use the software for ill-intentioned reasons, as
30+
determined by the authors of the software. said reasons include but are not
31+
limited to:
32+
a. bigotry, including but not limited to racism, xenophobia, homophobia,
33+
transphobia, ableism, sexism, antisemitism, religious intolerance
34+
b. pedophilia, zoophilia, and/or incest
35+
c. support for law enforcement and/or the military
36+
d. any blockchain-related technology, including but not limited to
37+
cryptocurrencies and non-fungible tokens
38+
39+
6. The user does not promote or engage with any of the activities listed in the
40+
previous item, and is not affiliated with any group that promotes or engages
41+
with any of such activities.
42+
43+
7. The user does not resell the software or any parts of it.
44+
45+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT EXPRESS OR IMPLIED WARRANTY OF ANY
46+
KIND, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
47+
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS BE
48+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
49+
CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
50+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

README.md

Lines changed: 34 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
1-
21
<div align="center">
3-
<img alt="update-logo" src="https://github.com/user-attachments/assets/948848d9-f173-4e61-a6c2-6a9f98af11c5">
2+
<img alt="update-logo" src="https://github.com/user-attachments/assets/d2a172d2-3b3f-45dc-9e38-4315536aa57e">
43
</div>
54

6-
75
# Lagrange - Procedural Planet Builder 🪐
86

97
<p>
10-
<img src="https://img.shields.io/badge/VueJS-3.4-%2342B883?logo=vuedotjs&labelColor=%2335495E&logoColor=white">
11-
<img src="https://img.shields.io/badge/Vite-5.2-%23BD34FE?logo=vite&labelColor=%2335495E&logoColor=white">
12-
<img src="https://img.shields.io/badge/ThreeJS-r166-%23049EF4?logo=threedotjs&labelColor=%2335495E&logoColor=white">
8+
<img src="https://img.shields.io/badge/VueJS-3.5-%2342B883?logo=vuedotjs&labelColor=%2335495E&logoColor=white">
9+
<img src="https://img.shields.io/badge/Vite-5.4-%23BD34FE?logo=vite&labelColor=%2335495E&logoColor=white">
10+
<img src="https://img.shields.io/badge/ThreeJS-r169-%23049EF4?logo=threedotjs&labelColor=%2335495E&logoColor=white">
1311
</p>
1412

1513
A WebGL project using VueJS and ThreeJS! <br>
@@ -19,24 +17,25 @@ Lagrange is a browser application to help you create your own planets, using pro
1917

2018
_(**note:** this is something I am working on during my free time, which means that update frequency will vary!)_
2119

22-
## 🚀 Latest version: "Ecosystems"!
20+
## 🚀 Latest version: "Jovian Expansion"!
2321

2422
<ul>
25-
<li>⭐ Introduces a fully fledged <strong>biome system</strong>, using temperature- & humidity-based positioning!</li>
26-
<li>⭐ Surface noise now works properly in Linux-based browsers!</li>
27-
<li>⭐ Smaller performance fixes all around, including fewer GLSL uniforms & varyings!</li>
23+
<li>⭐ Adds <strong>new parameters</strong> for your worlds: XYZ warping, displacement and ring systems!</li>
24+
<li>⭐ New dialog box when trying to leave the Editor without saving first, along with many touch-ups & improvements!</li>
25+
<li>⭐ Adds fr-FR translation, and changes project license to ISTSL-NR 1.0!</li>
2826
</ul>
2927

3028
## 🖼️ Showcase
3129

3230
<div align="center">
3331
<img width="30%" src="https://github.com/user-attachments/assets/937ec6c2-6969-49fa-a32c-856a759524f0" title="Kormeg" alt="planet:Kormeg">
34-
<img width="30%" src="https://github.com/user-attachments/assets/73345f0a-43d9-4055-9366-3150f499502f" title="Meriana" alt="planet:Meriana">
35-
<img width="30%" src="https://github.com/user-attachments/assets/7f20e7d1-a390-4050-8df6-3e8b5f1a6145" title="Hoven" alt="planet:Hoven">
32+
<img width="30%" src="https://github.com/user-attachments/assets/27988862-2186-4704-97e3-5c1b579a1a8d" title="Meriana" alt="planet:Meriana">
33+
<img width="30%" src="https://github.com/user-attachments/assets/b448e96c-f80d-4e39-b2ca-578db53095df" title="Hoven" alt="planet:Hoven">
34+
3635
</div>
3736
<div align="center">
3837
<img width="30%" src="https://github.com/user-attachments/assets/94951339-dc6f-4f68-9ef2-259cc7b585eb" title="Rakken IV" alt="planet:Rakken IV">
39-
<img width="30%" src="https://github.com/user-attachments/assets/9309ad14-6de0-4dc8-a37b-5b617395baf4" title="Rilgar" alt="planet:Rilgar">
38+
<img width="30%" src="https://github.com/user-attachments/assets/6535c328-5765-4e19-8fb0-b50e547dc54e" title="Hermeus Major" alt="planet:Hermeus Major">
4039
<img width="30%" src="https://github.com/user-attachments/assets/476c8706-88a7-49c2-a6d2-2cd152207496" title="Xu'Alatl" alt="planet:Xu'Alatl">
4140
</div>
4241

@@ -77,41 +76,51 @@ Vite copies the output to the `dist` folder, creating it first if need be.
7776

7877
### Editor
7978

80-
- ☀️ **Lighting parameters!** (sunlight, ambient light)
79+
- ☀️ **Lighting parameters!** (sunlight, ambient light, color)
8180
- 🌍 **Planet & Rendering parameters!** (transform, water level, PBR settings)
82-
- 🗺️ **Surface parameters!** (bump mapping, noise settings, color ramp)
81+
- 🗺️ **Surface parameters!** (bump mapping, warping, displacement, noise settings, color ramp)
8382
- ⛰️ **Biome parameters!** (temperature/humidity mapping, per-biome min/max values & color)
84-
- ☁️ **Clouds parameters!** (transform, color, opacity ramp)
83+
- ☁️ **Clouds parameters!** (transform, warping, noise settings, color, opacity ramp)
8584
- 🌈 **Atmosphere parameters!** (density, color mixing modes)
85+
- 🪐 **Ring System parameters!** (radii, color ramp)
8686

8787
## ⏰ Planned features
8888

8989
- Dark side "night lights"!
9090
- Cracks & Craters!
91-
- Gas Giants!
92-
- Rings & Asteroid belts!
91+
- Asteroid belts!
92+
- Planet animations!
9393
- _Galactic Map_, to organize them around stars!
9494

95-
## ✨ Inspirations
95+
## ✨ Inspirations & credits
9696

9797
This project is heavily inspired by the awesome projects below:
9898

9999
- [PlanetMaker Chrome Experiment](https://planetmaker.apoapsys.com) (2013, Kevin M. Gill)
100100
- [NASA's Eye on Exoplanets](https://eyes.nasa.gov/apps/exo/#/) (Unknown date, NASA)
101101

102+
**Special thanks** to the awesome people below, without whom this project would likely not exist:
103+
104+
<ul>
105+
<li>Main GLSL code snippets: <a href=\"https://iquilezles.org/\" target=\"_blank\"><b>Iñigo Quilez</b></a> (Voronoi + fBm), <a href=\"https://www.shadertoy.com/user/gltracy\" target=\"_blank\"><b>GLtracy</b></a> (atmosphere), <a href=\"https://andersonmancini.dev/\" target=\"_blank\"><b>Anderson Mancini</b></a> (lens flare)</li>
106+
<li>Miscellaneous GLSL code: <a href=\"https://www.dangreenheck.com/\"><b>Daniel Greenheck</b></a> (bump-mapping)</li>
107+
</ul>
108+
102109
## 📓 Licensing
103110

104-
Original assets and source code from this project are provided under a BSD 3-Clause "New" or "Revised" License.<br>
111+
The "Lagrange" logo, including _every_ update variant, is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International license ([CC BY-NC-SA 4.0 International](https://creativecommons.org/licenses/by-nc-sa/4.0/))
112+
113+
Original assets and source code from this project are provided under the "I'm So Tired" Software License 1.0 - No-Resale version.<br>
105114
Please consult the [license file](LICENSE) for full information.
106115

107116
Content from other parties is provided under their respective license, and attribution is given at the top of the aforementioned content.
108117

109118
## 🤝 Contributing
110119

111-
If you want to contribute code, feel free to submit your PRs!
120+
If you'd like to contribute code, feel free to submit your PRs!
112121

113-
Please make sure to respect the following:
122+
This project makes heavy use of the "Gitflow" branching model. To ensure proper branching, please make sure to respect the following steps:
114123

115-
1. [fork the project](https://docs.github.com/en/get-started/exploring-projects-on-github/contributing-to-a-project)
116-
2. create a branch from `develop`
117-
3. request your branch to be merged into `develop`
124+
1. [Fork the project](https://docs.github.com/en/get-started/exploring-projects-on-github/contributing-to-a-project)
125+
2. Create a branch from `develop`
126+
3. Request your branch to be merged into `develop`

package-lock.json

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

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "lagrange",
3-
"version": "0.3.1",
3+
"version": "0.4.0",
44
"private": true,
55
"type": "module",
66
"scripts": {
@@ -24,7 +24,7 @@
2424
"threejs"
2525
],
2626
"author": "EepyBerry",
27-
"license": "BSD-3-Clause",
27+
"license": "ISTSL-NR 1.0",
2828
"dependencies": {
2929
"@floating-ui/vue": "^1.1.5",
3030
"@unhead/vue": "^1.11.10",

src/App.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import AppInitDialog from '@components/dialogs/AppInitDialog.vue'
2121
import { useI18n } from 'vue-i18n'
2222
import { mapLocale } from './utils/utils'
2323
import { useHead } from '@unhead/vue'
24-
import { A11Y_ANIMATE } from './core/globals'
24+
import { A11Y_ANIMATE, EXTRAS_HOLOGRAM_MODE } from './core/globals'
2525
import AppToastBar from './components/main/AppToastBar.vue'
2626
import { EventBus } from './core/event-bus'
2727
@@ -56,6 +56,7 @@ onMounted(async () => {
5656
5757
// Set initial global values
5858
A11Y_ANIMATE.value = settings.value?.enableAnimations!
59+
EXTRAS_HOLOGRAM_MODE.value = settings.value?.extrasHologramMode!
5960
6061
// Open init dialog if necessary
6162
if (settings.value?.showInitDialog) {

src/assets/glsl/clouds.frag.glsl

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,14 @@ struct NoiseParameters {
88
float amp;
99
float lac;
1010
int oct;
11+
12+
float xwarp;
13+
float ywarp;
14+
float zwarp;
1115
};
1216

1317
// Main uniforms
18+
uniform bool u_warp;
1419
uniform NoiseParameters u_noise;
1520
uniform vec3 u_color;
1621
uniform sampler2D u_opacity_tex;
@@ -25,16 +30,24 @@ const vec3 DVEC_A = vec3(0.1, 0.1, 0.0);
2530
const vec3 DVEC_B = vec3(0.2, 0.2, 0.0);
2631

2732
void main() {
33+
// Warping
34+
vec3 wPos = vec3(
35+
vPos.x * mix(1.0, u_noise.xwarp, float(u_warp)),
36+
vPos.y * mix(1.0, u_noise.ywarp, float(u_warp)),
37+
vPos.z * mix(1.0, u_noise.zwarp, float(u_warp))
38+
);
39+
40+
// Clouds
2841
vec3 opacity = vec3(0.0);
2942
vec3 wOpacity = vec3(
30-
fbm3(vPos, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct),
31-
fbm3(vPos + DVEC_A, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct),
32-
fbm3(vPos + DVEC_B, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct)
43+
fbm3(wPos, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct),
44+
fbm3(wPos + DVEC_A, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct),
45+
fbm3(wPos + DVEC_B, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct)
3346
);
3447
if (wOpacity.x < 0.1) {
3548
discard;
3649
}
37-
opacity += fbm3(vPos + wOpacity, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct);
50+
opacity += fbm3(wPos + wOpacity, u_noise.freq, u_noise.amp, u_noise.lac, u_noise.oct);
3851
opacity = texture2D(u_opacity_tex, vec2(opacity.x, 0.5)).xyz;
3952

4053
csm_Metalness = 0.5;

src/assets/glsl/functions/atmosphere_utils.func.glsl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
// Sourced from Brian Jackson (@jaxzin), using code from GLtracy:
22
// https://glitch.com/~polite-playful-wool
3-
// https://www.shadertoy.com/view/lslXDr
43
// ------------------------------------------------------------------------------------------------
54

65
// Written by GLtracy
76
// Credit: https://www.shadertoy.com/view/lslXDr
7+
// Note: original code licensed under CC BY-NC-SA 3.0 Unported license (see: atmosphere_utils.func.glsl_LICENSE)
88

99
// math const
1010
const float PI = 3.14159265359;

0 commit comments

Comments
 (0)