[Effect] Normal Map Extended 1.01 (Updated -13 Jul)

Share your Construct 2 effect files

Post » Tue Jul 21, 2015 7:58 am

I don't know how to invert Y but all the programs i use have the option to invert Y or X before export. Check your program, what you use?

Also have you tried only this:
Every tick:
set effect "NormalMapExtended" Parameter 0 to mouse.x/WindowWidth
set effect "NormalMapExtended" Parameter 1 to mouse.y/WindowHeight

Also, have you the last version of Firefox?

Have you tried this live demo on firefox?:
https://dl.dropboxusercontent.com/u/659 ... index.html

The light is down the mouse? Is using the .capx demo provided, so if this live demo work on your firefox i not understand why when you compile not. In the case neither works, check if you have tha last version of firefox.

But well, maybe in your code have something that modify any parameter that affect to the normalmaps i don't know. But also is weird that in Chrome/Nw.js works and not in Firefox.
B
23
S
10
G
3
Posts: 538
Reputation: 4,426

Post » Tue Jul 21, 2015 11:49 am

Hi

look at this capture.
https://www.dropbox.com/s/l9qy7btzskjs6by/Capture%20d%27%C3%A9cran%202015-07-21%2013.12.03.png?dl=0
I freshly reinstall C2 Beta r210, install your last files version, and compile your last capx, in Firefox (last release) and in Chrome.

See what happen !
I check the zoom in the two browser, it is at 100%. But as you see, it seems bigger in firefox than in chrome. So i wander if Firefox makes an "automatic scale" of the canvas or something, that may distrub the shader. It's not "mouse" dependant as you see, it's buged on the animated yellow square light.
But I have the same problem with the "mouse" light (i just can't capture the mouse cursor to show you...)

so i dunno.. really weird...
I will just work on chrome for now.

For the normalmap Y axis, no more problem. I made a mistake :roll:

Thx again for your work, this shader is impressive.
Do you think, in a future version, you can add specular (using a specular texture ?)
Actually, I have a lots of 3D meshes with diff, spec and normal. So i can render from 3DSMax sprites in 3 versions : textured, normalmaped and speculared, and mix them in C2 with your shader.
I made some test and it's work great with texture and normal. Just wander if I can use Specaular too.

another question, not relative to normalmap, but do you know how I can make "selfilluminated" textures (I got many meshes using selfillum too 8-) )

But once again, great job !!!
B
6
Posts: 25
Reputation: 300

Post » Tue Jul 21, 2015 1:08 pm

The specular light is a thing will be great to add in the future, but actually i not have the enough skill on C2/Shader to do that sorry. There is a .FX made by other user that have normalmap+specular without need another texture, get from the actual image.

The bad thing is that seems to have some issues but i have in my queue invest some time to get the specular part and add to the normalmap .fx or made another different, will see, actually busy with my own project and working on a shaders editor.

But you can test, use my normalmap effect adding their effect too, maybe looks a bit weird, maybe works great together, test it. Is called "Normal Mapping by GamesWarp".

-

About "selfilluminated" textures what is exactly the effect? only be lighted in some zones? Well they already can do that using alpha, so if you want a texture or something that only want to add ight in some zones erase them and add a sprite with alpha with only the zones that you want to have light. If i understand well from here: http://docs.unity3d.com/Manual/shader-S ... amily.html
B
23
S
10
G
3
Posts: 538
Reputation: 4,426

Post » Tue Jul 21, 2015 7:18 pm

Ok.

selfilluminated maybe not the term i was looking for. It's more like Emissive. Ex a texture with some yellow points that emit light on the rest of the texture.
B
6
Posts: 25
Reputation: 300

Post » Tue Jul 21, 2015 8:17 pm

Ah i see, well, for that you can create a texture with alpha with the colors of the point and set glow or something, this will give the effect you want i guess.

You mean this?:
Image
Image

In this case you no need a "emissive texture", in 3D yes, but for 2D you can do using glow, adding an image as light or how you want to recreate the effect are you looking.

For example i did this time ago:
https://instagram.com/p/ntZKgiAL4C/

Simple add an image with some glow like a shadow, add the "additive" blend and put over the graphic you want to have "emisive light" or whatever ;) .
B
23
S
10
G
3
Posts: 538
Reputation: 4,426

Post » Wed Jul 22, 2015 9:02 pm

matriax wrote:I don't know how to invert Y but all the programs i use have the option to invert Y or X before export. Check your program, what you use?

Also have you tried only this:
Every tick:
set effect "NormalMapExtended" Parameter 0 to mouse.x/WindowWidth
set effect "NormalMapExtended" Parameter 1 to mouse.y/WindowHeight

Also, have you the last version of Firefox?

Have you tried this live demo on firefox?:
https://dl.dropboxusercontent.com/u/659 ... index.html

The light is down the mouse? Is using the .capx demo provided, so if this live demo work on your firefox i not understand why when you compile not. In the case neither works, check if you have tha last version of firefox.

But well, maybe in your code have something that modify any parameter that affect to the normalmaps i don't know. But also is weird that in Chrome/Nw.js works and not in Firefox.

On firefox it doesnt work properly (using 39):
Image
B
33
S
6
G
4
Posts: 44
Reputation: 5,066

Post » Wed Jul 22, 2015 9:16 pm

@donan I'm using firefox 39.0 and works correct so i guess maybe is not for firefox, but if works on chrome i not understand. BTW, actually Chrome have the best capabilities of HTML5-WebGL.

I guess in NW.JS works correct? . Really i don't know, in my case works on everything except Opera Browser but because have the worst Html5-WebGL compatibilities. In the rest works the same.

The capture is from the Livedemo or from a compilation made with the .capx ? If you can please try the capx or create an entire new proyect with an image with normalmap and try if works.

I guess tomorrow i will create some .capx to see if is problem of the LayerToCanvas. Without them continue working in case you not use scrollTO. So when i release this live demos/capx will see if there is any change or simply is there something wrong in firefox that i don't know.
B
23
S
10
G
3
Posts: 538
Reputation: 4,426

Post » Wed Jul 22, 2015 10:14 pm

matriax wrote:@donan I'm using firefox 39.0 and works correct so i guess maybe is not for firefox, but if works on chrome i not understand. BTW, actually Chrome have the best capabilities of HTML5-WebGL.

I guess in NW.JS works correct? . Really i don't know, in my case works on everything except Opera Browser but because have the worst Html5-WebGL compatibilities. In the rest works the same.

The capture is from the Livedemo or from a compilation made with the .capx ? If you can please try the capx or create an entire new proyect with an image with normalmap and try if works.

I guess tomorrow i will create some .capx to see if is problem of the LayerToCanvas. Without them continue working in case you not use scrollTO. So when i release this live demos/capx will see if there is any change or simply is there something wrong in firefox that i don't know.

Tried both, live and capx and both give same issue.
Created a new file using custom normal map, and both seems to show the same, but not the examples
B
33
S
6
G
4
Posts: 44
Reputation: 5,066

Post » Thu Jul 23, 2015 6:32 am

@donan So the new files created works correctly in both?

So, i guess in the new files you are using the same events conditions for X/Y coordinates, right?

In the new files are you using families too? If not, can you use Families like the .capx to see if this is the problem?

Can you post the .capx file on that NormalMap Extended works on both FIrefox/Chrome to see the differences, please?

Maybe there is also an option on "Project properties" that i marked/add on the examples that when you create a new one they are disabled.

If none of this things changes i don't know what more can be :S .

@donan Will be great if you can try all that to see in what moment the NormalMap stop working on FireFox to avoid the problem.
B
23
S
10
G
3
Posts: 538
Reputation: 4,426

Post » Thu Jul 23, 2015 12:40 pm

Hi guys

just want to share my last wip with you, using normalmap shader.

https://dl.dropboxusercontent.com/u/48232504/test/index.html
B
6
Posts: 25
Reputation: 300

PreviousNext

Return to Effects

Who is online

Users browsing this forum: No registered users and 0 guests