Created by @r_channels
Wave function collapse to generate goblin villages
https://redd.it/1jfgunm
@proceduralgeneration
I've already posted my procedural city's sculptures and paintings in this sub, but now I made a video explaining how I made them.
https://www.youtube.com/watch?v=fR1EmmCI2Cw
https://redd.it/1jev68o
@proceduralgeneration
Random Text Generator: Special Ability Powers
https://reactorcore.itch.io/random-text-special-ability-powers
https://redd.it/1jegqk9
@proceduralgeneration
Best noise transformations?
I've been working with some terrain generation with noise, particularly Simplex and Worley noise, with DLA mountains too. There are obvs many ways to mathematically shift, change and combine these techniques, but finding the best and most interesting ones is undeniably difficult.
I have managed to create a few interesting terrain types (images below) with the following:
\- Sinusoidal rolling hills with z += 1-cos(x+sin(y)) (with different scaling ofc)
\- Volcanoes with sinusoidal transformed worley
\- Shield walls: (1-abs(noise))\^p
\- Ravines: 1-normalize((1-abs(x))\^3)
\- River cliffs: abs(normalize((worley + noise), -0.5, 0.5))
\- Grass flatlands: low octave noise\^p
\- Flat top cliffs: sigmoid(normalize(x, -1, 1))
\- Terraces = normalize(x\^s1 * [round(x) + 0.5*(2*(x - round(x))\^s2\])
\- Spikey winter mountains = normalize(((1-worley(x))\^p +1)*(noise(x)))
These are really fun results, so it makes me crave some more combinations. In particular I've recently implemented domain warping and it looks like it has some really good potential for improving and shaping terrain, so using that would be cool.
I hope to hear some of the best terrain gen techniques !!
https://redd.it/1j052sv
@proceduralgeneration
(((6.0 * num) - 15.0) * num + 10.0) * num * num * num;
}
vec3 getVector3D(int i) {
i = i & 7;
if (i == 0) return vec3(1.0, 1.0, 1.0);
if (i == 1) return vec3(-1.0, 1.0, 1.0);
if (i == 2) return vec3(1.0, -1.0, 1.0);
if (i == 3) return vec3(-1.0, -1.0, 1.0);
if (i == 4) return vec3(1.0, 1.0, -1.0);
if (i == 5) return vec3(-1.0, 1.0, -1.0);
if (i == 6) return vec3(1.0, -1.0, -1.0);
return vec3(-1.0, -1.0, -1.0);
}
float perlin3D(vec3 coords, float frequency, float amplitude) {
coords = coords * frequency;
vec3 coordsf = vec3(coords.x - floor(coords.x), coords.y - floor(coords.y), coords.z - floor(coords.z));
/*
Input values are said to be on an integer grid. Decimal values lie inside a square in that grid.
For each of the corners where the input lies, a value is generated.
This value is the dot product of 2 vectors.
The first vector comes from a grid point to the input value.
*/
vec3 lowerSouthWest = vec3(coordsf.x - 1.0, coordsf.y - 1.0, coordsf.z - 1.0);
vec3 lowerSouthEast = vec3(coordsf.x, coordsf.y - 1.0, coordsf.z - 1.0);
vec3 lowerNorthWest = vec3(coordsf.x - 1.0, coordsf.y, coordsf.z - 1.0);
vec3 lowerNorthEast = vec3(coordsf.x, coordsf.y, coordsf.z - 1.0);
vec3 upperSouthWest = vec3(coordsf.x - 1.0, coordsf.y - 1.0, coordsf.z);
vec3 upperSouthEast = vec3(coordsf.x, coordsf.y - 1.0, coordsf.z);
vec3 upperNorthWest = vec3(coordsf.x - 1.0, coordsf.y, coordsf.z);
vec3 upperNorthEast = vec3(coordsf.x, coordsf.y, coordsf.z);
/*
The second vector should be "random", but consistent for each grid point.
We use the permutation table to obtain it (RNG could be used, but is more expensive).
First we use the bitwise & operator (in this case works like % 256) to obtain indexes for the permutation table.
Keep in mind we can also access permX + 1 and permY + 1 due to the fact that we duplicated the table.
*/
int permX = (int(floor(coords.x))) % PERMS.length();
int permX2 = (permX + 1) % PERMS.length();
int permY = (int(floor(coords.y))) % PERMS.length();
int permY2 = (permY + 1) % PERMS.length();
int permZ = (int(floor(coords.z))) % PERMS.length();
int permZ2 = (permZ + 1) % PERMS.length();
int valueLowerSouthWest = PERMS[PERMS[PERMS[permX2] + permY2] + permZ2];
int valueLowerSouthEast = PERMS[PERMS[PERMS[permX] + permY2] + permZ2];
int valueLowerNorthWest = PERMS[PERMS[PERMS[permX2] + permY] + permZ2];
int valueLowerNorthEast = PERMS[PERMS[PERMS[permX] + permY] + permZ2];
int valueUpperSouthWest = PERMS[PERMS[PERMS[permX2] + permY2] + permZ];
int valueUpperSouthEast = PERMS[PERMS[PERMS[permX] + permY2] + permZ];
int valueUpperNorthWest = PERMS[PERMS[PERMS[permX2] + permY] + permZ];
int valueUpperNorthEast = PERMS[PERMS[PERMS[permX] + permY] + permZ];
/*
Calculate the dot products. We finally have the special values for each grid corner.
*/
float dotLowerSouthWest = dot(lowerSouthWest, getVector3D(valueLowerSouthWest));
float dotLowerSouthEast = dot(lowerSouthEast, getVector3D(valueLowerSouthEast));
float dotLowerNorthWest = dot(lowerNorthWest, getVector3D(valueLowerNorthWest));
float dotLowerNorthEast = dot(lowerNorthEast, getVector3D(valueLowerNorthEast));
float dotUpperSouthWest = dot(upperSouthWest, getVector3D(valueUpperSouthWest));
float dotUpperSouthEast = dot(upperSouthEast, getVector3D(valueUpperSouthEast));
float dotUpperNorthWest = dot(upperNorthWest, getVector3D(valueUpperNorthWest));
float dotUpperNorthEast = dot(upperNorthEast, getVector3D(valueUpperNorthEast));
/*
Finally, we begin interpolating these values.
Since we can only interpolate two numbers
Help fixing 3D perlin noise shader
Hello. I'm trying to expand a 2D perlin noise shader into 3D. For some reason, though, the shader seems to be turning into several disjointed cells as seen in the pic. Could somebody help me find what's wrong with the code? Thank you!
https://preview.redd.it/yzps9k8i8rle1.png?width=800&format=png&auto=webp&s=1fc329d430b9f42be5b8e7a197bfe0c040da608d
// a permutation table of the numbers 0-255 in a random order. Looped 3 times for multidimensional sampling
const int PERMS = int(128, 111, 168, 210, 233, 58, 199, 93, 160, 17, 6, 60, 36, 135, 100, 185, 42, 211, 134, 222, 8, 53, 4, 131, 182, 89, 241, 90, 252, 86, 205, 200, 59, 238, 145, 188, 196, 183, 189, 242, 226, 76, 190, 12, 208, 251, 149, 79, 108, 177, 44, 218, 159, 29, 126, 98, 151, 101, 27, 99, 178, 154, 221, 232, 231, 245, 150, 176, 41, 95, 64, 206, 153, 120, 34, 181, 198, 5, 47, 192, 35, 3, 43, 167, 216, 229, 227, 119, 180, 236, 139, 117, 28, 164, 237, 96, 255, 31, 94, 74, 9, 249, 143, 38, 40, 201, 103, 124, 138, 118, 105, 57, 67, 207, 72, 88, 1, 110, 16, 52, 51, 56, 220, 224, 114, 215, 0, 37, 92, 162, 169, 141, 61, 125, 225, 113, 91, 102, 123, 202, 13, 244, 121, 104, 136, 45, 10, 116, 223, 246, 137, 7, 213, 50, 115, 165, 142, 187, 81, 83, 70, 230, 78, 77, 75, 132, 66, 194, 54, 19, 20, 109, 155, 146, 39, 186, 144, 234, 22, 62, 235, 30, 147, 18, 21, 122, 195, 148, 33, 2, 82, 85, 152, 203, 174, 212, 97, 73, 172, 170, 69, 87, 219, 250, 254, 204, 55, 48, 107, 112, 209, 239, 140, 166, 175, 49, 243, 161, 157, 65, 247, 127, 129, 191, 156, 173, 14, 23, 106, 197, 84, 15, 133, 228, 179, 63, 253, 163, 26, 193, 11, 240, 130, 80, 25, 32, 214, 71, 248, 46, 217, 68, 184, 171, 24, 158, 128, 111, 168, 210, 233, 58, 199, 93, 160, 17, 6, 60, 36, 135, 100, 185, 42, 211, 134, 222, 8, 53, 4, 131, 182, 89, 241, 90, 252, 86, 205, 200, 59, 238, 145, 188, 196, 183, 189, 242, 226, 76, 190, 12, 208, 251, 149, 79, 108, 177, 44, 218, 159, 29, 126, 98, 151, 101, 27, 99, 178, 154, 221, 232, 231, 245, 150, 176, 41, 95, 64, 206, 153, 120, 34, 181, 198, 5, 47, 192, 35, 3, 43, 167, 216, 229, 227, 119, 180, 236, 139, 117, 28, 164, 237, 96, 255, 31, 94, 74, 9, 249, 143, 38, 40, 201, 103, 124, 138, 118, 105, 57, 67, 207, 72, 88, 1, 110, 16, 52, 51, 56, 220, 224, 114, 215, 0, 37, 92, 162, 169, 141, 61, 125, 225, 113, 91, 102, 123, 202, 13, 244, 121, 104, 136, 45, 10, 116, 223, 246, 137, 7, 213, 50, 115, 165, 142, 187, 81, 83, 70, 230, 78, 77, 75, 132, 66, 194, 54, 19, 20, 109, 155, 146, 39, 186, 144, 234, 22, 62, 235, 30, 147, 18, 21, 122, 195, 148, 33, 2, 82, 85, 152, 203, 174, 212, 97, 73, 172, 170, 69, 87, 219, 250, 254, 204, 55, 48, 107, 112, 209, 239, 140, 166, 175, 49, 243, 161, 157, 65, 247, 127, 129, 191, 156, 173, 14, 23, 106, 197, 84, 15, 133, 228, 179, 63, 253, 163, 26, 193, 11, 240, 130, 80, 25, 32, 214, 71, 248, 46, 217, 68, 184, 171, 24, 158, 128, 111, 168, 210, 233, 58, 199, 93, 160, 17, 6, 60, 36, 135, 100, 185, 42, 211, 134, 222, 8, 53, 4, 131, 182, 89, 241, 90, 252, 86, 205, 200, 59, 238, 145, 188, 196, 183, 189, 242, 226, 76, 190, 12, 208, 251, 149, 79, 108, 177, 44, 218, 159, 29, 126, 98, 151, 101, 27, 99, 178, 154, 221, 232, 231, 245, 150, 176, 41, 95, 64, 206, 153, 120, 34, 181, 198, 5, 47, 192, 35, 3, 43, 167, 216, 229, 227, 119, 180, 236, 139, 117, 28, 164, 237, 96, 255, 31, 94, 74, 9, 249, 143, 38, 40, 201, 103, 124, 138, 118, 105, 57, 67, 207, 72, 88, 1, 110, 16, 52, 51, 56, 220, 224, 114, 215, 0, 37, 92, 162, 169, 141, 61, 125, 225, 113, 91, 102, 123, 202, 13, 244, 121, 104, 136, 45, 10, 116, 223, 246, 137, 7, 213, 50, 115, 165, 142, 187, 81, 83, 70, 230, 78, 77, 75, 132, 66, 194, 54, 19, 20, 109, 155, 146, 39, 186, 144, 234, 22, 62, 235, 30, 147, 18, 21, 122, 195, 148, 33, 2, 82, 85, 152, 203, 174, 212, 97, 73, 172, 170, 69, 87, 219, 250, 254, 204, 55, 48, 107, 112, 209, 239, 140, 166, 175, 49, 243, 161, 157, 65, 247, 127, 129, 191, 156, 173, 14, 23, 106, 197, 84, 15, 133, 228, 179, 63, 253, 163, 26, 193, 11, 240, 130, 80, 25, 32, 214, 71, 248, 46, 217, 68, 184, 171, 24, 158);
float ease(float num) {
return
Atmosphere Volumetric Shadows - Structures and Atmosphere Procedurally Generated and Path Traced in Avoyd Voxel Editor
https://redd.it/1izh5ep
@proceduralgeneration
Rainge. Animation for new music release.
https://youtu.be/rUsqaCoVzl0
https://redd.it/1iyyld1
@proceduralgeneration
Procedural Surface Texture - Groups - Break
https://redd.it/1iypbhd
@proceduralgeneration
Trying to run my procgen game / engine on SteamDeck at 60 FPS (C++/OpenGL/GLSL)
https://youtu.be/tEe6-zMo4G0?si=q394v-kChFEpZqHJ
https://redd.it/1iyibpq
@proceduralgeneration
enclosed
https://redd.it/1iycx7e
@proceduralgeneration
Visualization of generating a planet from Icosahedron for my game.
https://redd.it/1iy1311
@proceduralgeneration
City block generator - Some first pictures of my asset creator (procedural generation).
https://redd.it/1ixwpxi
@proceduralgeneration
i want to create a procedural line system in houdini (image 1), but I keep ending up with sth much simpler (image 2). can anyone point me in the right direction?
https://redd.it/1iwkl1b
@proceduralgeneration
Procedural dungeon generation. Different shape rooms update
https://redd.it/1iwklqi
@proceduralgeneration
Discuss: generating curlicue within a rectangle
I'm thinking outside the border, trying to generate picture frames. Most of them have interesting curlicue in the corners. Because it's for a plotter it has to be some kind of vector. I've looked at Euler spirals and simulating two bar linkages, as well as walk accel + jerk with occasional jerk sign flips.
I imagine a top-down view of a skateboarder in an empty pool, always approaching but never leaving the edges. Maybe that's something?
So, dearest hive mind, what do you suggest?
https://redd.it/1jf3ugz
@proceduralgeneration
Procedurally-generated music using the famous American Gothic painting
https://redd.it/1jejqiz
@proceduralgeneration
Geometric shapes with shading 23((_u6
https://redd.it/1jedy8z
@proceduralgeneration
at a time, we interpolate 2 pairs and then interpolate their results.
Also, using linear interpolation will produce sharp edges.
We use the ease function to improve our inputs to the interpolation function.
*/
float u = ease(coordsf.x);
float v = ease(coordsf.y);
float w = ease(coordsf.z);
float lowerWest = mix(dotLowerSouthWest, dotLowerNorthWest, v);
float lowerEast = mix(dotLowerSouthEast, dotLowerNorthEast, v);
float upperWest = mix(dotUpperSouthWest, dotUpperNorthWest, v);
float upperEast = mix(dotUpperSouthEast, dotUpperNorthEast, v);
float lower = mix(lowerWest, lowerEast, u);
float upper = mix(upperWest, upperEast, u);
float point = mix(lower, upper, w); // result
return point * amplitude;
}
https://redd.it/1izrwx1
@proceduralgeneration
Help fixing 3D perlin noise shader
Hello. I'm trying to expand a 2D perlin noise shader into 3D. For some reason, though, the shader seems to be turning into several disjointed cells as seen in the pic. Could somebody help me find what's wrong with the code? Thank you!
https://preview.redd.it/yzps9k8i8rle1.png?width=800&format=png&auto=webp&s=1fc329d430b9f42be5b8e7a197bfe0c040da608d
// a permutation table of the numbers 0-255 in a random order. Looped 3 times for multidimensional sampling
const int[] PERMS = int[](128, 111, 168, 210, 233, 58, 199, 93, 160, 17, 6, 60, 36, 135, 100, 185, 42, 211, 134, 222, 8, 53, 4, 131, 182, 89, 241, 90, 252, 86, 205, 200, 59, 238, 145, 188, 196, 183, 189, 242, 226, 76, 190, 12, 208, 251, 149, 79, 108, 177, 44, 218, 159, 29, 126, 98, 151, 101, 27, 99, 178, 154, 221, 232, 231, 245, 150, 176, 41, 95, 64, 206, 153, 120, 34, 181, 198, 5, 47, 192, 35, 3, 43, 167, 216, 229, 227, 119, 180, 236, 139, 117, 28, 164, 237, 96, 255, 31, 94, 74, 9, 249, 143, 38, 40, 201, 103, 124, 138, 118, 105, 57, 67, 207, 72, 88, 1, 110, 16, 52, 51, 56, 220, 224, 114, 215, 0, 37, 92, 162, 169, 141, 61, 125, 225, 113, 91, 102, 123, 202, 13, 244, 121, 104, 136, 45, 10, 116, 223, 246, 137, 7, 213, 50, 115, 165, 142, 187, 81, 83, 70, 230, 78, 77, 75, 132, 66, 194, 54, 19, 20, 109, 155, 146, 39, 186, 144, 234, 22, 62, 235, 30, 147, 18, 21, 122, 195, 148, 33, 2, 82, 85, 152, 203, 174, 212, 97, 73, 172, 170, 69, 87, 219, 250, 254, 204, 55, 48, 107, 112, 209, 239, 140, 166, 175, 49, 243, 161, 157, 65, 247, 127, 129, 191, 156, 173, 14, 23, 106, 197, 84, 15, 133, 228, 179, 63, 253, 163, 26, 193, 11, 240, 130, 80, 25, 32, 214, 71, 248, 46, 217, 68, 184, 171, 24, 158, 128, 111, 168, 210, 233, 58, 199, 93, 160, 17, 6, 60, 36, 135, 100, 185, 42, 211, 134, 222, 8, 53, 4, 131, 182, 89, 241, 90, 252, 86, 205, 200, 59, 238, 145, 188, 196, 183, 189, 242, 226, 76, 190, 12, 208, 251, 149, 79, 108, 177, 44, 218, 159, 29, 126, 98, 151, 101, 27, 99, 178, 154, 221, 232, 231, 245, 150, 176, 41, 95, 64, 206, 153, 120, 34, 181, 198, 5, 47, 192, 35, 3, 43, 167, 216, 229, 227, 119, 180, 236, 139, 117, 28, 164, 237, 96, 255, 31, 94, 74, 9, 249, 143, 38, 40, 201, 103, 124, 138, 118, 105, 57, 67, 207, 72, 88, 1, 110, 16, 52, 51, 56, 220, 224, 114, 215, 0, 37, 92, 162, 169, 141, 61, 125, 225, 113, 91, 102, 123, 202, 13, 244, 121, 104, 136, 45, 10, 116, 223, 246, 137, 7, 213, 50, 115, 165, 142, 187, 81, 83, 70, 230, 78, 77, 75, 132, 66, 194, 54, 19, 20, 109, 155, 146, 39, 186, 144, 234, 22, 62, 235, 30, 147, 18, 21, 122, 195, 148, 33, 2, 82, 85, 152, 203, 174, 212, 97, 73, 172, 170, 69, 87, 219, 250, 254, 204, 55, 48, 107, 112, 209, 239, 140, 166, 175, 49, 243, 161, 157, 65, 247, 127, 129, 191, 156, 173, 14, 23, 106, 197, 84, 15, 133, 228, 179, 63, 253, 163, 26, 193, 11, 240, 130, 80, 25, 32, 214, 71, 248, 46, 217, 68, 184, 171, 24, 158, 128, 111, 168, 210, 233, 58, 199, 93, 160, 17, 6, 60, 36, 135, 100, 185, 42, 211, 134, 222, 8, 53, 4, 131, 182, 89, 241, 90, 252, 86, 205, 200, 59, 238, 145, 188, 196, 183, 189, 242, 226, 76, 190, 12, 208, 251, 149, 79, 108, 177, 44, 218, 159, 29, 126, 98, 151, 101, 27, 99, 178, 154, 221, 232, 231, 245, 150, 176, 41, 95, 64, 206, 153, 120, 34, 181, 198, 5, 47, 192, 35, 3, 43, 167, 216, 229, 227, 119, 180, 236, 139, 117, 28, 164, 237, 96, 255, 31, 94, 74, 9, 249, 143, 38, 40, 201, 103, 124, 138, 118, 105, 57, 67, 207, 72, 88, 1, 110, 16, 52, 51, 56, 220, 224, 114, 215, 0, 37, 92, 162, 169, 141, 61, 125, 225, 113, 91, 102, 123, 202, 13, 244, 121, 104, 136, 45, 10, 116, 223, 246, 137, 7, 213, 50, 115, 165, 142, 187, 81, 83, 70, 230, 78, 77, 75, 132, 66, 194, 54, 19, 20, 109, 155, 146, 39, 186, 144, 234, 22, 62, 235, 30, 147, 18, 21, 122, 195, 148, 33, 2, 82, 85, 152, 203, 174, 212, 97, 73, 172, 170, 69, 87, 219, 250, 254, 204, 55, 48, 107, 112, 209, 239, 140, 166, 175, 49, 243, 161, 157, 65, 247, 127, 129, 191, 156, 173, 14, 23, 106, 197, 84, 15, 133, 228, 179, 63, 253, 163, 26, 193, 11, 240, 130, 80, 25, 32, 214, 71, 248, 46, 217, 68, 184, 171, 24, 158);
float ease(float num) {
return
Claude 3.7 procedural generation
Have any of you tried to create videogames with claude 3.7? What help can it give?
https://redd.it/1izgo7w
@proceduralgeneration
Procedural Generation In My Games First Post
https://old.reddit.com/r/OTDev/
https://redd.it/1iz6iso
@proceduralgeneration
Abstract geometric visuals 4:xf-gy778
https://redd.it/1iyxc51
@proceduralgeneration
procedural planet
https://redd.it/1iyooyz
@proceduralgeneration
OpenGL - procedural terrain and procedural trees experiments
https://youtu.be/QMRF2ZfRAQU
https://redd.it/1iyi6x5
@proceduralgeneration
emanations - python
https://redd.it/1iy455f
@proceduralgeneration
Procedural Surface Texture - Groups
https://redd.it/1ixxdn2
@proceduralgeneration
Made a freeriding skiing game with infinite procedurally generated mountains to carve down
https://redd.it/1ix63gq
@proceduralgeneration
Trouble with Perlin noise
So, Perlin noise as I think of it looks like this:
https://preview.redd.it/jhfufstpryke1.png?width=492&format=png&auto=webp&s=694ad8b9bdec0770667e48c2ae55d3c02d0f16e7
And if you set some threshold and convert it to black and white, it looks like this:
https://preview.redd.it/85kbcoxrryke1.png?width=496&format=png&auto=webp&s=bd6d4f5da6a133d7d16860b3e392cb1f54e725c2
Those images were made in python with the perlin_noise library. The problem is, every point has to be computed individually, which is very slow. So I found vnoise, a vectorized Perlin noise library that takes numpy arrays as arguments, and here's what it looks like:
https://preview.redd.it/lxukwjqtryke1.png?width=494&format=png&auto=webp&s=4db8c8b55951e7cbe99018b0f85f2eef9cc26ab2
Looks fine, until you convert to black and white:
https://preview.redd.it/me1p5l9wryke1.png?width=495&format=png&auto=webp&s=df2d1a2361ef79000e92ee605ab60804749df946
For some reason, this Perlin noise has a bunch of straight vertical and horizontal edges, which is no good for what I'm doing. My questions are:
1) Is that a valid Perlin noise implementation, or is it a bug that I should report on the project's git page?
2) Does anyone know of any other vectorized noise libraries in python? I'd greatly appreciate it if I didn't have to make my own noise.
https://redd.it/1iwmi9k
@proceduralgeneration
3d procedual generation
Hello, can you please take a moment to answer this form? It will only take 2 to 3 minutes and it's very important for my thesis. Thank you once again https://docs.google.com/forms/d/1ERVGJGlEZNxh0WrhUbkgrjRdwi\_mf6zSM8Uu3PvcS1s/edit#responses
https://redd.it/1iwf02y
@proceduralgeneration