Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Goombert

2446
General ENIGMA / Re: Everything Is Good Now
« on: August 28, 2013, 08:59:55 am »
@polyfaggot
https://github.com/enigma-dev/enigma-dev/commit/06be021c447b430bf9e1723f45d10a40847596e4

CTRL+F for "glewInit()" you did fucking too broke it, but its fine Josh already merged and fixed it.

2447
General ENIGMA / Re: Everything Is Good Now
« on: August 28, 2013, 07:41:35 am »
Harri, what did you mean by you can't get shaders working? I thought they were working for you in the past?

2448
Tips, Tutorials, Examples / Example Shaders
« on: August 28, 2013, 05:36:08 am »
This topic is a collection of various shaders that can be used in your game. You are free to use them and can also post your own in this topic.

Cartoon Shader


Language: GLSL

Vertex Shader
Code: (glsl) [Select]
varying vec3 normal;

void main()
{
normal = gl_NormalMatrix * gl_Normal;
gl_Position = ftransform();
}

Fragment Shader
Code: (glsl) [Select]
varying vec3 normal;

void main()
{
float intensity;
vec4 color;
vec3 n = normalize(normal);
intensity = dot(vec3(gl_LightSource[0].position),n);

if (intensity > 0.95)
color = vec4(1.0,0.5,0.5,1.0);
else if (intensity > 0.5)
color = vec4(0.6,0.3,0.3,1.0);
else if (intensity > 0.25)
color = vec4(0.4,0.2,0.2,1.0);
else
color = vec4(0.2,0.1,0.1,1.0);
gl_FragColor = color;
}

Perpixel


Language: GLSL

Vertex Shader
Code: (glsl) [Select]
void main()
{
vec3 normal, lightDir;
vec4 diffuse, ambient, globalAmbient;
float NdotL;

normal = normalize(gl_NormalMatrix * gl_Normal);
lightDir = normalize(vec3(gl_LightSource[0].position));
NdotL = max(dot(normal, lightDir), 0.0);
diffuse = gl_FrontMaterial.diffuse * gl_LightSource[0].diffuse;

/* Compute the ambient and globalAmbient terms */
ambient = gl_FrontMaterial.ambient * gl_LightSource[0].ambient;
globalAmbient = gl_LightModel.ambient * gl_FrontMaterial.ambient;

gl_FrontColor =  NdotL * diffuse + globalAmbient + ambient;

gl_Position = ftransform();
}

Fragment Shader
Code: (glsl) [Select]
void main()
{
gl_FragColor = gl_Color;
}

2449
ALLCAPS BOARD / Once in a Lifetime
« on: August 28, 2013, 04:46:03 am »

2450
General ENIGMA / Everything Is Good Now
« on: August 28, 2013, 04:10:24 am »
I believe the issues with the executable have been resolved, it is now working for me again, Harri, polygonz, and frogg. So let's just not mess with the exe quite some time, the only thing it needs is automatic updates to download binaries, I will finish it myself at a later point in time.

Polygonz, please try not to do shit like remove glewInit() from OpenGL 1, like seriously, do you even think before you commit anything?

This is the kind of responses we end up getting on our Facebook as a result...
Quote
Yeah... Its crashed on first run for me... I will send bug report next weekend
Quote
Janko Knez I suggest you focus on the bugs first, then add features.

We need to at least try not to break EVERYTHING all at one time ;_;

2451
General ENIGMA / Re: Compiling from source
« on: August 28, 2013, 01:32:46 am »
Yes, of course I can? Look at the source code is halfway done I just need to fix up the bash script to download binaries, init script will just download the latest update. I am still tryna think about where to put the damn binaries at, I might just have josh throw it all in a git repository so it can just be a bash script and the commit log will be the update feed.

2452
Announcements / Re: Shader Resources
« on: August 27, 2013, 10:21:46 pm »
TKG, can you try again with the latest zip that I just uploaded? If the error persists please provide your output_log.txt

2453
General ENIGMA / Re: Windows Zip Discussion
« on: August 27, 2013, 08:32:16 pm »
MY FUCKING SYS

2454
General ENIGMA / Re: Windows Zip Discussion
« on: August 27, 2013, 07:20:23 pm »
I fixed it it was your fault you fag you preprended mingw/bin but not git/bin

2455
General ENIGMA / Cannot Setup from Portable ZIP
« on: August 27, 2013, 05:37:40 pm »
Now I can't compile because of something you guys did...

Code: [Select]
ar r ../Additional/Windows/lib/libalure32.a ../Additional/Windows/alure/ALURETMP/*.o
C:\Users\Owner\Desktop\ENIGMA\mingw32\bin\ar.exe: creating ../Additional/Windows/lib/libalure32.a
rm -rf ../Additional/Windows/alure/ALURETMP
process_begin: CreateProcess(NULL, rm -rf ../Additional/Windows/alure/ALURETMP, ...) failed.
make (e=2): The system cannot find the file specified.

mingw32-make.exe[1]: *** [../Additional/Windows/lib/libalure32.a] Error 2
mingw32-make.exe[1]: Leaving directory `C:/Users/Owner/Desktop/ENIGMA/enigma-dev/ENIGMAsystem/SHELL'
mingw32-make.exe: *** [Game] Error 2

2456
General ENIGMA / Re: Windows Zip Discussion
« on: August 27, 2013, 05:04:40 pm »
Right, because this is totally what we should all be wasting our time on....

Edit: All of you just stay away from it, I am going to make it automatically update, SO DONT FUCKIN TOUCH IT WHILE IM WORKING ON IT

2457
General ENIGMA / Re: Compiling from source
« on: August 27, 2013, 04:32:19 pm »
Quote
So it finally works again. Thank you all! Now we must make sure it doesn't break and update installation instructions.

Quote
I think more likely my .exe change fixed it. I think it will fix a lot of the problems people have been having.


Still needa fix why its not rebuilding compileEGMf

2458
Announcements / Re: Shader Resources
« on: August 27, 2013, 04:30:05 pm »
Quote
Shaders still not working. Will investigate later. I think it was something with shader compilation error.
Harri, all you have to do is make sure you have the very latest shit and just open that EGM and run it.

2459
Announcements / Shader Resources
« on: August 27, 2013, 04:31:04 am »
Shaders are now available as a resource and can be used. They are compatible with Game Maker's and can currently only be saved and loaded under EGM, GMK does not support them. GMX format will be finished soon enough I have a lot on my plate.



Youtube Video: https://youtu.be/cZixbLHaroI

WARNING! You have to update in order to use them, and you must update both LateralGM, the plugin, and ENIGMA using git in order to use them, if you update only one of these then the others will break. If you have installed using the Windows ENIGMA Portable you are advised to redownload as bug fixes have been applied to those of you with MinGW issues and it also now contains an ini settings file to control checking for java and other things. Automatic updating will be available at a later point in time.

The shader functions are all documented and available on the Wiki.
https://enigma-dev.org/docs/Wiki/Shader_Functions

Currently only GLSL shaders are supported, but the function API is tailored for glsl programming and can currently only be used in OpenGL. The Game Maker version of the functions are simply wrapped around each graphics systems implementation so that there can exist an API which caters to only one shading language. These shaders can greatly help improve the performance of your games by offloading strenuous work onto the GPU where they properly belong, unlike Game Maker we also provide you the option to dynamically compile and link shaders at runtime as shaders are properly intended and encouraged by hardware manufacturers to be used.

There is a nice website for scripting and seeing real time results of shaders as well, they also have many example shaders.
http://www.kickjs.org/example/shader_editor/shader_editor.html#

There is the GLSL sandbox as well which I thought was very cool.
https://www.shadertoy.com/

2460
Yes, I would like to state again in case anyone is not aware if you update from git or use the new LateralGM, the opposite will break, so if you get the new LGM the engine will break, if you update from git, LGM will break. If you update anything you must do a full update of the software, we are looking into providing an interface for auto updates.