wont use lua lol

This commit is contained in:
kin fuyuki 2026-02-22 22:15:45 -03:00
commit 1c27658641
No known key found for this signature in database
GPG key ID: 0E4E8E519FB71401
15 changed files with 101 additions and 26 deletions

View file

@ -2,6 +2,8 @@
#include <cstddef>
Image* noise::gen(short w, short h, int x, int y) {
switch (this->type) {
case CLOUD:

View file

@ -1,5 +1,10 @@
#pragma once
#include "window.h"
struct buffer {
char**pixel;//rgba format
};
enum NOISETYPE {
CLOUD,
RANDOM,
@ -16,8 +21,11 @@ class noise {
int amp;
NOISETYPE type;
DIMENSION dims;
noise(int freq,int octave, int amp, NOISETYPE type, DIMENSION dims):
freq(freq), octave(octave), amp(amp), type(type),dims(dims) {}
freq(freq), octave(octave), amp(amp), type(type),dims(dims) {
}
/// to explain the image generator
/// \param x int
/// \param y int
@ -25,8 +33,8 @@ class noise {
/// \param w
/// \param h
/// these are the image width and height. PLEASE DO NOT GET CONFUSED
Image* gen(short w, short h,int x, int y);
buffer* gen(short w, short h,int x, int y);
};
Image* cloud(noise* noise,short w, short h,int x, int y);
Image* random(noise* noise, short w, short h,int x, int y);
buffer* cloud(noise* noise,short w, short h,int x, int y);
buffer* random(noise* noise, short w, short h,int x, int y);