Gamestudio Links
Zorro Links
Newest Posts
Trading Journey
by 7th_zorro. 04/27/24 04:42
Help with plotting multiple ZigZag
by M_D. 04/26/24 20:03
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
M1 Oversampling
by jcl. 04/26/24 11:12
Why Zorro supports up to 72 cores?
by jcl. 04/26/24 11:09
Eigenwerbung
by jcl. 04/26/24 11:08
MT5 bridge not working on MT5 v. 5 build 4160
by EternallyCurious. 04/25/24 20:49
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (Akow, Quad, 7th_zorro, VoroneTZ), 800 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
wandaluciaia, Mega_Rod, EternallyCurious, howardR, 11honza11
19049 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: [FREE] Normalmap Generator [Re: mk_1] #313084
02/27/10 16:59
02/27/10 16:59
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
Quad Online
Senior Expert
Quad  Online
Senior Expert

Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
sorry for side-tracking the topic but, can any of you point me to an algorithm or explanation of normalmap generation? (from single 2D image)

i searched for a while only thing i could find is generating normalmaps from highpoly meshes.


3333333333
Re: [FREE] Normalmap Generator [Re: Quad] #313100
02/27/10 17:47
02/27/10 17:47
Joined: May 2005
Posts: 2,713
Lübeck
Slin Offline
Expert
Slin  Offline
Expert

Joined: May 2005
Posts: 2,713
Lübeck
I am probably wrong, but I think that one uses the brightness as heightmap, from which you can then calculate normals by taking always three pixels, calculating the direction of one to the other two and doing the cross product, which after dividing through the length gives you what you then just have to put into a texture, by multiplying with and adding 0.5.

Re: [FREE] Normalmap Generator [Re: Quad] #313167
02/27/10 23:52
02/27/10 23:52
Joined: Oct 2004
Posts: 900
Lgh
rojart Offline
User
rojart  Offline
User

Joined: Oct 2004
Posts: 900
Lgh
Originally Posted By: mk_1
I've been searching the internet for some time to find a simple normalmap generator and mostly found commercial stuff like CrazyBump or bloated programs that do a lot more than is needed for me. Another possibility is a free Photoshop or Fimp plugin. As I don't own Photoshop and am not much of a friend of Gimp I decided to write a generator myself.
Actually it's a rip from a bigger editor I'm working on so don't expect too much.

Thanks for the nice NM generator laugh
What I've noticed and imo should be changed, maybe:
-The whole window size is a bit to small.
-Preview can't be moved, like move around.
-Only bmp and jpg format can be saved.

But anyway very good tool for user that have not experiences with paint tools.

Originally Posted By: Quadraxas
...can any of you point me to an algorithm or explanation of normalmap generation? (from single 2D image)

Not the best solution for your question, but a small tip how to change a 2d image to normal map with lite-c:

Code:
///////////////////////////////
//#include <acknex.h>
#include <default.c>
#include <mtlFX.c>
///////////////////////////////
#define PRAGMA_PATH "%EXE_DIR%\templates\models";

function main()
{
	video_window(NULL,NULL,2,NULL);
	video_set(640,480,32,2);
	level_load("");
	vec_set(camera.x,vector(-200,0,60));
	vec_set(camera.pan,vector(0,-15,0));
	
	ENTITY* ent = ent_create ("dumper1.mdl", NULL, NULL); // don't forget to duplicate skin1 in MED, like Edit->Manage Skins->Duplicate Skin
	
	ent_setskin(ent, bmap_to_normals(ent_getskin(ent, 2), 20.0), 2);
	
	ent.material = mtl_specBump ;
	
	while(1){
		ent.pan += 3 * time_step;
		wait(1);
	}
}




Regards, Robert

Quote
Everything should be made as simple as possible, but not one bit simpler.
by Albert Einstein

PhysX Preview of Cloth, Fluid and Soft Body

A8.47.1P
Re: [FREE] Normalmap Generator [Re: rojart] #313169
02/28/10 00:16
02/28/10 00:16
Joined: Mar 2006
Posts: 2,252
Hummel Offline
Expert
Hummel  Offline
Expert

Joined: Mar 2006
Posts: 2,252
that is not an algorithm, that just shows how to use the cheap build-in normal function -.- slin already gave a correct answere

Re: [FREE] Normalmap Generator [Re: Slin] #313178
02/28/10 02:18
02/28/10 02:18
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
Quad Online
Senior Expert
Quad  Online
Senior Expert

Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
Originally Posted By: Slin
I am probably wrong, but I think that one uses the brightness as heightmap, from which you can then calculate normals by taking always three pixels, calculating the direction of one to the other two and doing the cross product, which after dividing through the length gives you what you then just have to put into a texture, by multiplying with and adding 0.5.


it will take some time for me to fully comprehend that but i guess i got the main idea.


3333333333
Re: [FREE] Normalmap Generator [Re: mk_1] #357419
02/07/11 03:54
02/07/11 03:54
Joined: Jul 2010
Posts: 974
United Arab Emirates, Dubai
TheShooter Offline
User
TheShooter  Offline
User

Joined: Jul 2010
Posts: 974
United Arab Emirates, Dubai
Down? I can't load it.


Staub ist das neue Prime!!

Programming is like sex:
One mistake and you have to support it for the rest of your life.

Aktuelles Projekt: http://thisiswargame.bplaced.net/index.html

A8 Commercial *freu*
Re: [FREE] Normalmap Generator [Re: TheShooter] #357448
02/07/11 09:48
02/07/11 09:48
Joined: Dec 2000
Posts: 4,608
mk_1 Offline OP

Expert
mk_1  Offline OP

Expert

Joined: Dec 2000
Posts: 4,608
Will fix it tomorrow


Follow me on twitter
Re: [FREE] Normalmap Generator [Re: mk_1] #357556
02/07/11 16:46
02/07/11 16:46
Joined: Jul 2009
Posts: 1,198
Berlin, Germany
L
Liamissimo Offline
Serious User
Liamissimo  Offline
Serious User
L

Joined: Jul 2009
Posts: 1,198
Berlin, Germany
http://www.smart-page.net/smartnormal/fl10.htm

Very nice too! Online generator without downloading sth.


"Ich weiss nicht genau, was Sie vorhaben, aber Sie können keine Triggerzonen durch Ihr Level kullern lassen."
-JCL, 2011
Page 2 of 2 1 2

Moderated by  adoado, checkbutton, mk_1, Perro 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1