xNormal - MASTER THREAD

13456796
  • Offline / Send Message
  • Joined
  • 81 Topics
  • 1.4K Replies
just saw this on opengl.org, might be worth a try, specially with the seemingly not so well working melody

didnt have time to test it, but a well known modeller has helped development

http://www.xnormal.net

Replies

  • Valandar
    • Offline / Send Message
    • Joined
    • 43 Topics
    • 1.1K Replies
    Eeenteresting... Definitely gonna try it out, see how it goes...
  • Ruz
    • Offline / Send Message
    • Joined
    • 303 Topics
    • 4.6K Replies
    hmm, doesn't support quads, it forgets the paths you have just used and it seems to have no exit button. i gave up after that
  • Eric Chadwick
    • Offline / Send Message
    • Joined
    • 279 Topics
    • 9.6K Replies
    I find some tools are only worthwhile after I've given the coder some feedback, so they can improve it. Send him your thoughts Ruz, it might turn into something good.
    [Email]jogshy [at] mixmail.com[/Email]

    That strategery worked great for me with Kaldera, I got a great tool out of it.
  • Ruz
    • Offline / Send Message
    • Joined
    • 303 Topics
    • 4.6K Replies
    yeah sure. I think the tri thing is s bit annoying, but the interface was quite nice and i think i got a previous version from this guy working ok, so it should be fine after the bug fixes
  • jec1183
    • Offline / Send Message
    • Joined
    • 8 Topics
    • 122 Replies
    The exit button is the button that says close on the lower left. I already told him about the quad issue. It still does a really good job of creating normal maps. Unfortunetly it doesn't support high poly floating geometry so if you want your high poly stuff to be transfered over it has to be modeled in seamless which could get annoying with bigger projects.
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    Hi laugh.gif

    I'm taking good note about all your feedback. Atm I am finishing the quad support implementation as well as solving some other bugs.

    About the close button... There is! Is that ugly small blue button in the bottom-left! I know my UI art sux badly but... LOL...

    I dont know what is the floating geometry thing... Can anybody explain to me pls?

    I really wanna thank you all the feedback these days I am getting to improve the program. Please if you have suggestions, bugs or whatever, you can contact me at [Email]jogshy [at] mixmail.com[/Email] as usually or in my web page.
  • Valandar
    • Offline / Send Message
    • Joined
    • 43 Topics
    • 1.1K Replies
    As was explained to me:

    http://www.iddevnet.com/quake4/ArtReference_CreatingModels

    Scroll down until you see the picture of the hi-res knee with the triangular indent.
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    Ok, just uploaded the new xNormal v3.1.0 with quad support, floating geometry support, new LWO importer, new fine detail / 3D viewer format supports, directory restoration, multipart load as well as some minor bug corrections.

    Hope you like it. thx for all the feedback.
  • MoP
    • Offline / Send Message
    • Joined
    • 135 Topics
    • 11.5K Replies
    It's great that you are responding to feedback and coming here to help us all out with programs like this, jogshy! I'm going to give the new version a try and see if I can think of any suggestions for you smile.gif
    Thanks again!
  • pior
    • Offline / Send Message
    • Joined
    • 118 Topics
    • 6.8K Replies
    Ha cool, glad to see it working! Sorry for not responding faster to your earlier requests man.

    Gonna test it asap!
  • MoP
    • Offline / Send Message
    • Joined
    • 135 Topics
    • 11.5K Replies
    OK I just gave it a try with a couple of OBJ files, highpoly around 75,000 triangles, lowpoly about 275 triangles.
    The normal-map renderer works fine, very fast and quite a good normal map output after tweaking the ray cast distance. However when I tried to turn on the Ambient Occlusion render too, the program would crash every time (usually halfway through the "mipmap 0 level generation" process).
    Is this a known bug? My highpoly had floating geometry and was all quads, the lowpoly was all triangles. I was generating a 512x512 texture.
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    Are you using the last 3.1.1 version? Corrected an ambient occlusion in this version... Not sure if is the bug is affecting you though.
  • MoP
    • Offline / Send Message
    • Joined
    • 135 Topics
    • 11.5K Replies
    Ah, I had 3.1.0, i'll get the newest version and see if it works smile.gif

    Edit: Hmm, no, the program crashes at the same point (calculating normals, [mip level 0], just after halfway on the progress bar) with version 3.1.1.

    However you were right about the dual monitor thing I emailed you about, I had 2 -> 1 instead of 1 -> 2
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    damm ok, none of the examples the people with that bug sent me crashed on my Duron/Athlon64 ... I will investigate more but I suspect is a Pentium 4 floating point thing .... Anybody with AMD CPUs getting crashes on ambient occlusion generation?

    Well, expect a new version in a few days once I locate the problem.
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    Okie! New version v3.1.2 is out!
    Btw, I added in my web a small .txt with the changes, so you no longer need to download the 11Mb to see them hehe...

    Basically, solved the ambient occlusion crash ( was a problem with Pentium4 dual-cores and hyperthreading ), added camera orbit mode, added Stanford PLY mesh format ( because it appears is very popular in 3d-scanners ), now the 3d viewer supports floating point textures for improved normal map appereance as well as FSAA and anisotropic filtering.

    You can download it as usually in http://www.santyesprogramadorynografista.net/projects.aspx

    Hope you like it!
  • Daz
    • Offline / Send Message
    • Joined
    • 125 Topics
    • 3.4K Replies
    Firstly jogshy, I just want to say thanks and how awesome this is that youre getting the community involved in improving what has the potential to be an absolutely killer little app. I'm actually particularly excited about the ambient occlusion map output, since there's currently no way for me to do this in Maya unless I UV map my high poly.

    So I just installed your new version and Im still getting a crash at the obj reading stage the same as the prior version. Im wondering If you have a limit either hardcoded or memory based on polycount? My hi poly is humungous ( approx 750,000 tris ) and I'm wondering If this is related to the crash? Any thoughts appreciated. Btw, this is without the AO pass ticked. I have 1.5 gig of Ram If that info helps any. I'd send you the obj but its 75 meg ;-p
  • MoP
    • Offline / Send Message
    • Joined
    • 135 Topics
    • 11.5K Replies
    jogshy: Excellent, v3.1.2 fixed the bug I was getting, I can now generate ambient occlusion maps as well as normals! smile.gif

    Also I think the 3d viewer is an awesome tool, since some programs don't have a previewer for this sort of thing, and often I've seen people asking where they can get a free program to view lowpoly meshes with normal maps applied - in future I will tell them to go and use your program smile.gif

    I took a screenshot of one of my models in it, with diffuse, normal, emissive, spec. power, colour and glossiness maps, and it works very well! You can see a reduced size screengrab here: http://ldaustinart.com/paul/xnormal.jpg
    I noticed that my specular/glossiness maps look different in this viewer than in 3dsmax, do you know why that might be? The size of the highlight seems much smaller than the glossiness map should make it seem... any idea why this might be? Is it something I'm doing wrong, or a difference in the program?

    The new Camera Orbit tool is very useful, also the mouse control seems to be improved over previous versions? Anyway it works well. I think it would be a good idea to add some colour sliders (like those for the light colour) on the left to change the background colour of the viewer - often models don't look best on a black background, and I'm sure a lot of people would like to be able to use a different coloured background.

    As for Daz's problem, I'm gonna try exporting a really big .OBJ file and seeing if I get the same crash, if so it might be a problem with loading very dense highpoly meshes. I'll post results later.

    Thanks again, good work! smile.gif
  • MoP
    • Offline / Send Message
    • Joined
    • 135 Topics
    • 11.5K Replies
    OK after some testing, I'm gonna have to conclude that it's not the size of the OBJ file or amount of polygons the highpoly has - I just successfully used a 1.5 million triangle highpoly mesh (141mb .OBJ file) to generate a normal map.

    Daz: OBJ's actually zip up pretty nicely, you could probably get that 75mb OBJ down to about 15mb, which isn't too bad... if you want to get that to me somehow, I could give it a test on my computer to see if it's the OBJ file that's the problem, or some sort of different, hard/software related issue?

    jogshy: I tried some more stuff and I think I found another bug - the "Blur pixels" amount will go up, but not down. I can type in any value, and that works fine, but using the arrows to the right, the value only goes up and the "down" arrow doesn't have any effect.

    Also I was thinking of something else, in 3dsmax there's an option to use "Supersampling" when rendering a normal map, it's like antialiasing the normal map but I guess it casts more rays and uses an average to determine the pixel colour.
    Here is an example of the difference between an xNormal map (which is still very good!), and a 3dsmax "supersampled" map... the smoothness just makes it look a bit more believable.

    norm-compare.jpg

    Is it possible for you to do something like this? I'm sure it's probably not easy to do, but it'd be a great feature and I'm sure would get more people using your program for all their normal-mapping smile.gif

    Oh, I just thought of something else that would be very useful for the 3d viewer, too! At the moment when you hold CTRL and right-click, the camera orbits ... would it be easy to add something so that CTRL and left-click would make the light orbit? Or maybe CTRL and left-click could rotate the object itself? I think that'd be a useful feature.

    Thanks again, keep up the great work! wink.gif
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    To MoP:
    Impressive artwork, MoP! I love your screenshots! cool.gif

    I think your spec/glow highlight looks different because I use a default specular power exponent of 32 and 3dsmax 16. You can control it using a specular power map in the 3D viewer ( white pure = 255 exponent = supershiny; black=0 exponent=no shiny ). Notice there is a specular map ( specular color and intensity modulation ) and a specular power map ( specular exponent ) in the 3D viewer texture browser. For more info about Phong specular exponents see these links:

    http://mrl.nyu.edu/~perlin/courses/fall2005ugrad/phong.html ->See more exponent means more shiny

    http://en.wikipedia.org/wiki/Specular
    http://en.wikipedia.org/wiki/Phong_shading

    3dsmax uses a fixed shiny exponent of 16 for the Direct3D shading viewport(i think). I use 32 by default for the full mesh unless you specify a "per-pixel-specular-power-texture" ( this is called "variable specular power", if you wanna google it, and notice is NOT the same than specular color modulation, is a different concept )

    Also, I'm working to put the "HDR fullscreen glow" in the 3d previewer for the next version.

    Atm, I am finishing too the "orbit light" feature ( and a chaos-animated one too ) and the change background color I think is a good suggestion, yep.

    Yes, the blur thing is a bug. Ouch! Will correct it asap.

    Will include the "supersampling" option as you suggest.

    To Daz:
    I love your 007 art!

    The version 3.1.2 solved a really weird crash-critical-bug in the ambient occlusion generation. Please sure you have the 3.1.2. Ok, if you have the 3.1.2 and still crashes... Have your high poly model UVs and normals? If so, try to re-export it with ONLY positions, then use it with xNormal. Sure too you have only one mesh in your highpoly OBJ. Collapse ALL the meshes into one. Erase any materials, sure all the faces in the highpoly mesh uses only one material(the default material because you erased all the materials previously). Try to triangulate it ( perhaps is a problem with quad faces? ).
    Other question... are you using xNormal in Windows and not with Wine or other Linux emulator, right?

    If still crashes... Can you send me an email to [Email]jogshy [at] mixmail.com[/Email] with your operating system name and service packs, machine CPU/RAM/hardware, your xNormal XML settings, copy/paste of the exception or error from xNormal and xN_debugLog.txt log file? If you want to send me a thing with +10Mb then please use admin@santyesprogramadorynografista.net

    There are no hard-coded limits. The only limit is which your machine supports. Each highpoly triangle occupies 12bytes. Each vertex 12bytes too. The normalmap width*height*20. See the xN_debugLog.txt to know the memory consumed. If you don't have enough RAM installed then expect a nice crash.. In theory Windows should enable virtual memory when physical system RAM is not enough but well... Other posibility is that xNormal goes outta "stack memory" ( 1Mb at the moment ) for the acceleration structures I use ( bsp, octrees, blah blah ). In the next version I will add a visual UI indicator to see how much memory are you using.

    If you can enable me a FTP or a download link I will test your 75Mbs models and treat them confidentially. Will erase them once I solve the possible bug, I promise.

    To all:
    I am working too in a new install method that allows you all not to download 11Mb each time a new version comes, because is a pain, I know confused.gif

    And wanna thank you all for all the feedback I'm getting wink.gif
  • cochtl
    • Offline / Send Message
    • Joined
    • 28 Topics
    • 388 Replies
    You may already know this jogshy, but supersampling doubles (or any multiple the user may want to input for that matter) the current output image resolution and then sizes it back down to the original size so that the output image has finer, crisper detail. I hope that can help in some way wink.gif

    This is a really awesome app btw
  • Daz
    • Offline / Send Message
    • Joined
    • 125 Topics
    • 3.4K Replies
    Triangulating did the trick many thanks jogshy!
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    I am thinking perhaps quad faces is not enough... What happens if a program uses 8-vertices polygonal faces? If you are using these kind of faces I am pretty sure my OBJ importer will do a nice BOOOOOOOOOOOM!

    I am thinking about just triangulate n-verts-polygons too... Save that OBJ Daz, I will put the next version ( omg with tons of new features! ) in a few and probably will need it to test please.
  • Daz
    • Offline / Send Message
    • Joined
    • 125 Topics
    • 3.4K Replies
    no problem. Shall I send it to where you referred to above?
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    Nah, first I need to implement here a bunch of things hehe
    Just conserve that OBJ and test it with the next version I am preparing If you want.

    thx Daz.
  • pior
    • Offline / Send Message
    • Joined
    • 118 Topics
    • 6.8K Replies
    Hey Jog!

    I've been trying out the app and like the many options I am seeing!

    However... I got that error when I try to load the demonhead example file, and got the same when loading one of my own objs with nmap on :

    xnormal_crashonexample.jpg

    Any idea? I'm on a GF4Ti4200, XP, no service pack, 1Ghz AMD. (don't laugh!)

    As for suggestions, I would love to see .ase import and sleek castshadows wink.gif

    Can't wait to see where that viewer is going.
  • Mongrelman
    • Offline / Send Message
    • Joined
    • 69 Topics
    • 2.1K Replies
    Hi, I just downloaded version 3.1.2 to give it a try (haven't used previous versions). I installed and it all seemed to go fine, but when I try to run the program I get an error message:

    "Attempted to read or write protected memory. This is often an indication that other memory is corrupt."

    My computer is an athlon xp 3200 , 1 gig PC3200 ram , Ati Radion 9800 pro , running Windows XP.

    Been looking for a program like this for quite awhile now, glad to see you are making one and updating it so fast smile.gif
  • CrazyButcher
    • Offline / Send Message
    • Joined
    • 81 Topics
    • 1.4K Replies
    pior, geforce4 doesnt support glsl, so the app wont work for you, only if you are really lucky and jogshy plans to add a non glsl, but Cg codepath...
  • jogshy
    • Offline / Send Message
    • Joined
    • 6 Topics
    • 1K Replies
    To Pior:

    Pior you need a Radeon9xxx or GeForce FX or better to run the viewer ( or any card supporting HLSL or GLSL ). In old cards like yours the programmers must use a type of "graphics assembler" ( yes, asm, mov eax, 10 lea [eax+10] thingy! ) which is simply weird. In fact, if you see some DirectX 10 preview and the graphics cards coming, you will find that they are dropping non-HLSL shaders. Shaders are more and more complicated with the time so "assembly" paradigm is bad. We need high level shader languages (HLSL and GLSL). So I don't plan to support these old cards because I don't wanna implement a 800 lines crazy-assembly shader, sorry 8( On the other hand, I don't like the Cg approach because the Mac version I'm preparing doesn't support it and Cg+ATI=bad. GLSL is more portable I think and the way to go.

    Also, to run Windows Vista(Avalon WPF) or the new Gnome 3D desktop, you will need a card with ps2.0+ or above. Even SM 3.0 won't be enough due to geometry shaders explosion ( yes we have now vertex shaders, pixel/fragment shader and geometry/topology shaders! ).

    To Lupus:

    Hey nice Gargantua!
    What kind of mesh you use? What options you enabled? Do you have troubles running the examples or only with your own geometry? The program crashes just at start or when you try to generate a normal/displace/occlusion map? What says the xNormal_debuglog.txt?
  • CrazyButcher
    • Offline / Send Message
    • Joined
    • 81 Topics
    • 1.4K Replies
    the main problem is that OpenGL has no "pixelshader 1.x" but started with the "2.x" stuff. Functionality similar to 1.x can be reached with Nvidia or Ati specific codepaths... however simple normal mapping could still be done in multipassing with regular texture combiners and vertexprograms in GL. Since our engine is for older hardware, I have that type of stuff done for it.

    so if you are interested in a "old hardware" path jogshy, I could support you (code it). aiming at GL 1.3, I think it would still run somewhat well on that hardware, since we are just viewing a single model... the thing that will be really tricky however is nice specular
  • Mongrelman
    • Offline / Send Message
    • Joined
    • 69 Topics
    • 2.1K Replies
    @Jogshy: Cheers smile.gif

    The error happens when I try to run the program. I double click the icon and then an error window appears with that message.
13456796

Leave a Comment