cool3a2s optimized hungarian leaderheads

I have returned to the fur shader making some strange experiences. I'll have some brainstorming here to share my thoughts so you can tell me if you see something that I might have missed or can give me new ideas. Or maybe I get an idea while writing this. I hope this won't become a monologe. Let's make a summarize about what I have at first...

What I have...
I have several leaderheads by hand that were all made by nitram initially, that use the fur part from Genghis and that I try to improve on. I was partially successful to some extend, but there remain issues. So we have the following leaderheads:

- Koppány (working, based on shaka)
- Ruga (based on Ghengis)
- Álmos (based on Saladin)
- Rákóczi (based on the Spanish King from Colonization)
- István Báthori (based on Stuyvesant)

And of course there are Shaka and Genghis that, too, use the fur parts with the TTorusFur shader.


First steps

Initially, I had problems with the direction from were the light strikes the fur. To have an easy example: the light should have come from the left, while the the other side of the fur (that should have been in the shadow) was brighter then the rest. Sometimes the fur even remained entirely black. I have successfully solved this by being careful with roation and translation (moving) operations, not using SkinInsatnces and using TriStrips instead of TriShapes. Basically, the light now falls in from the correct angle, but the dark parts are overly dark. The onl exception is Koppány, who is working fine on this point.


Ideas to solve the issue

The naive idea is to work on the lights and material properties. Unfortunately, only the 3 diffuse lights have influence on the fur, at least if the TTorusFur shader is on, and no additional lights can be added as those don't seem to take effect at all. Similarily, the material properties have no influence. With only 3 lights available, it is pretty hard to get a proper light setting, especially if there is a certain light effect that should be created like a strong shadow. Basically, I have given up this idea as the light effects created looked 'weird' and artifical.

Instead, I was trying to find out why exactly the fur doesn't work as expected and then to solve the actual problem. Fur curiousity, I swapped in Álmos' the fur to Ghenghis and noticed that it then worked just fine. I again swapped in all of Genghis lights into Álmos to make sure all the settings are identical. No change to the fur problem. I then recognized that the Bloom-lights are different from the others in that they have several nodes as children. These nodes resemble the leaderheads skeleton nodes. To be more specific, normally, these nodes are no copy, but the same nodes as in the skeleton (check the indices). Now, if anyone nifswaps the Bloom-lights from another leader into a user-made leaderhead, the nodes underneath the bloom-lights get copied. In this case, the indices of the blooms children will differ from those of the skeleton. Not enough, not only are there plain nodes underneath the blooms, but also meshes (that would be copied as well in this case, without showing up in the 3d view). This technique will blow up the nifs size significantly, while I am not sure whether these lights then have any effect. When working on a leaderhead that I got from an experienced leaderhead modder recently, I noticed that there were also hidden meshs that blew up the nif. Back then, I had no idea where these meshes came from. I'm almost sure that I didn't cause that, not sure if this was an accident by the experienced modder or whether he just didn't know about this. Or whether I caused this long ago so that I don't remember (but the meshs I found let me think that I am not responsible). Anyways, when swapping in the fur part to Genghis, I recognized that the fur was not only added to the skeleton, but also to the blooms. So I thought that messed up blooms could be the cause of the problem. To exclude the blooms as an error source or to even solve the problem, I wapped all the meshes and all the lights, except of the blooms, back to saladin and then keyed in the blooms settings manually. Besides of that the file size dropped from 3225kB to 873kB, the fur issue persisted. This ways, the following things are not responsible for this problem:
- the lights (have been copied from / adjusted according to Genghis carefully)
- the mesh (works in Ghengis' nif)
- the texture (also works in Genghis nif)
Nevertheless, there seems to be some unknow environmental setting for Genghis and Shaka that have influence on the fur. This would explain why there is no problem with Koppány (based on shaka) and why my fur parts work with Genghis. Nitrams Ruga does not work properly, I think, although it is based on Ghengis. Maybe it works nevertheless and only the light setting is 'misleading'. In any case, in order to create a night scene with fire effect, nitram worked on the lights which put the whole nif in unorder. So even if the fur doesn't work, I think I could make it working here by nifswapping with Genghis, I'm just not sure whether I could recreate the light effect, so I didn't give it a shot yet.

Unfortunately, I didn't get any new ideas by my own yet. Hope you guys can think of something.

EDIT: There is something else I read about recetnly and accidently that is related to the TTorusFur shader. I'm just not sure how and if it fits to my problems. IgorS made a Casimir LH also using the fur part (nitram used that as base for Báthori, so Báthori is not a direct derivative of Stuyvesant) and in the filedbs entry for that LH, someone mentions that the fur is invisible for him. IgorS said that the shader causes that sort of trouble. Although I think that this issue has to do with the shader, I don't think it is a general problem as the user didn't mention trouble with Genghis or Shaka. I think there is something screwed up. I swapped that part with another one that I was sure about would work with Genghis. Maybe this issue is gone this ways. Also, I had similar effects when playing around with the blooms. If I corrected the indices of the fur there, the fur disappeared in sceneviewer, while it was there in nifskoe. Civ4 normally behaves like SceneViewer, so I think I wouldn't have seen it in the game either. Lastly, it can not be excluded that the user had an older machine not supporting shaders while IgorS didn't provide a noshader version of his LH. All in all, I couldn't build up a handy theory how this fits to my issue, just mention it to have it complete.
 
Okay, here is a quick fix of the Imre Nagy face. With new normal map and adjusted lighting. I didn't put too much effort into this, because i think you will probably change it again.




And you shouldn't care that much about the diffrent shaders. Textures (all maps, including normals, environment, etc.) and a good light are 99% more important. And you are able to get the effect you want with this anyway.
 

Attachments

  • nagy.jpg
    nagy.jpg
    115.2 KB · Views: 216
  • nagy_melcher_fix.7z
    1.3 MB · Views: 92
Ah, that looks pretty good already! Don't think I will have big work with this anymore. I'll try to make the eyebrows more even and close the gaps, but that's just modelling. Anyways, let me do that first and then I'll provide a frewsh update. Finally, whoever feels atracted to, may give the forehead a second shot to give it a bit more details. That would be great, although it is already pretty good.

Regarding the shader issue, I think that you are right with your point normally, but the TTorusFur shader is special in that it doesn't use any shader maps. You only have switch it on, that's all, no further settings. And as I already said, it shows reactions to only the 3 diffuse lights, that's not much I can deal with. The mipmap setting seems to have some influence, but I already got the maximum out of it, I think. At least, the maximum that I can serve with.
 
So I've worked on the eyebrows and think I got them right. The gaps are also closed. There's just a decend glimmer as the hair is from fdr, while the head is from Bismarck and thus they don't fit together 100% showing the background a bit sometimes. You guys don't know accidentely how to get this solved easily? By moving around the vertices, this is the best I could get.
Basically, I changed my mind about the texture. As Nagy was a bit fatty, there don't need to be more details on the forehead. Near the gaps, there are some dark areas. They aren't visible from the cameras point of view, so they are probably not a serious problem. Will have to check other animations though. If anyone still wants to give the texture a shot, I'll upload the LH soon. Also, feel free to make suggestions. For now, I will take some time to think about further changes myself.

Besides of this, I'd like to hear your opinion about a problem I have. It's a problem of the first version of Nagy that I wanted to get glitch-free at least. I'm basically done with it, but there is an issue involving the glasses and the eyes. Version 1 used Alexanders animation and at the moment the leader turns towards the viewer during the greeting animation, there are temporarily two pairs of eyes. The actual eyes work well, but it seems that the glasses create the imagination of a second pair. The is definately no second pair, that's fur sure. I rather think it is a problem of the material and the alpha property. I have compared the glasses and the eyes with gandhis and fdrs, but couldn't find anything. While it is true that I moved the eyeball bones and then realigned the eyeballs to them to get them working, I don't think this is the reason. Ideas? Of course, I won't put much energy in this, since there is version 2, but I have the feeling that this would be easy to solve if one knows what has to be done. It's been quite long since I worked on this LH last time, but I think that I had these problems back then, too. Not sure if I could fix it or just tweak it. In any case, the leaderhead was farer away from the camera before, so that the glitch might not have been visible. In any case, I couldn't remember any fix for that.
 
Besides of this, I'd like to hear your opinion about a problem I have. It's a problem of the first version of Nagy that I wanted to get glitch-free at least. I'm basically done with it, but there is an issue involving the glasses and the eyes. Version 1 used Alexanders animation and at the moment the leader turns towards the viewer during the greeting animation, there are temporarily two pairs of eyes. The actual eyes work well, but it seems that the glasses create the imagination of a second pair. The is definately no second pair, that's fur sure. I rather think it is a problem of the material and the alpha property. I have compared the glasses and the eyes with gandhis and fdrs, but couldn't find anything. While it is true that I moved the eyeball bones and then realigned the eyeballs to them to get them working, I don't think this is the reason. Ideas? Of course, I won't put much energy in this, since there is version 2, but I have the feeling that this would be easy to solve if one knows what has to be done. It's been quite long since I worked on this LH last time, but I think that I had these problems back then, too. Not sure if I could fix it or just tweak it. In any case, the leaderhead was farer away from the camera before, so that the glitch might not have been visible. In any case, I couldn't remember any fix for that.
Are you sure that there is really a second pair of eyes? I had a similar effect with my leaderheads when I created a dummy node for the eyes in order to shift them into the right position. They look right if the leader looks directly to the viewer, but pop out of or into the head when they look away from him. It helps to use a minimal value in Translation and do most of the adjusting via Rotation.
 
Are you sure that there is really a second pair of eyes? I had a similar effect with my leaderheads when I created a dummy node for the eyes in order to shift them into the right position. They look right if the leader looks directly to the viewer, but pop out of or into the head when they look away from him. It helps to use a minimal value in Translation and do most of the adjusting via Rotation.
Thanks for sharing your opinion, Saibot. I'm pretty confident with that there is no physical second pair of eyes, no second eye mesh in other words. I rather think it is a meterial related thing. Also, I'm aware of that problems that you mentioned, I also tried to fix the eyes using a dummy node when working on this the first time and got similar issues. This time, however, I didn't use a dummy bone, but altered the original eyeball bone, then lined up the eyes with those bones again. This was a pretty simple technique that didn't cause any trouble. In nifskope everything is fine, there is no second pair of eyes nor a reflection. Nifskope handles animation slightly different then the game does. I think that nifskope uses the bones position etc. from the nif as base, while the game looks these up in the animation files (kfs). This ways, I had to alter the values of the eyeballs within the kfs so that they match those in the nif. As I forogt this when I ran the LH in the game the first time, I know how it looks like if the values are incorrect and they looked different then they do now. Also, I have checked the greeting kf just to be sure and everything seems to be fine. Another reason for why things are okay in nifskope, but aren't in the game, is, that nifskope doesn't seem to use shaders. The leader then behaves like a nonshadered nif, which would support my point of view that this is something material related or something that blows up the depth calculation (zbuffering and stuff like that), while the actual meshes are fine. Hmmm... maybe I should try to nifswap the glasses into the original alex to see if they mess up the original alex and his eyes, too.

Alexander the Great with glasses works properly, so it's not a material problem...
 
I provide my files for Nagy version 1 so you can have a better impression. I'd say that there are two pairs of eyes visible the same time, don't think broken animations could cause this sort of trouble.

EDIT: Things are even more weird. If I remove the lenses, everything is okay which indicates that the animation and the bones are fine. I compared Nagys and Alex' eyes and they just seem to match... I also moved the eyes to a child of the Scene Root were the original eyes were, but no luck. Don't know what's going on here. It's just another mysterious case like the TTorusFur shader...
 
I toyed a bit with the leaderhead, it's in fact a strange problem. I think the glitch happens at the time one of the glasses passes before the other one from the point of the viewer, which seems to cause some unwanted feedback. I managed to damper the effect a little by dividing the glasses_glas mesh into a glasses_r_glas and a glasses_l_glas mesh, but there is still some left because the sides of the lens passes before each another at some time, too. I've attached the modified nif at this post if you want to take a look at it.

Why this problem does not occure when you give Alexander the glasses I don't know. :dunno: But I haven't done much modding with the NiAlphaProperty and the NiMaterialProperty so far.
 

Attachments

  • mod_nagy.zip
    414.8 KB · Views: 80
I think the glitch happens at the time one of the glasses passes before the other one from the point of the viewer, which seems to cause some unwanted feedback.
Yeah, that could be related to the problem in-deed. That's roughly what I was think about when saying that some depth calculations get broken (on a somewhat mathematical level). But I also have no clue why Alex is fine with the glasses then... Anyways, I'll take a look at your files when I'll have some time. Could take me a while though as I won't be at home tomorrow.
 
I take a look at your files and find the problem easily. You can't just put 2 diffrent transparent meshes behind each other. Therefore other settings in the NiAlphaProperty are required. But in your case the needed flags won't work, because you have no texture. The only solution is to remove the NiAlphaProperty property from the two meshes behind. In your case the head and the eyes. They don't need them anyway.
I wouldn't recommend to use NiAlphaProperty at non-transparent meshes at all.

Fix is attached.

greetings melcher
 

Attachments

  • nagy_v1_fix.7z
    321.4 KB · Views: 82
melcher kürzer;10525887 said:
I take a look at your files and find the problem easily. You can't just put 2 diffrent transparent meshes behind each other. Therefore other settings in the NiAlphaProperty are required. But in your case the needed flags won't work, because you have no texture. The only solution is to remove the NiAlphaProperty property from the two meshes behind. In your case the head and the eyes. They don't need them anyway.
I wouldn't recommend to use NiAlphaProperty at non-transparent meshes at all.

Fix is attached.

greetings melcher
Hm, interesting, in fact that should also be the reason why the glasses worked with Alexander, since his body and eyes have no NiAlphaProperty either.

Do you know why this glitch makes only the head mesh of the original Nagy leaderhead invisible, while the eyes are still visible? Both have a NiAlphaProperty after all.
 
Hm, interesting, in fact that should also be the reason why the glasses worked with Alexander, since his body and eyes have no NiAlphaProperty either.

Do you know why this glitch makes only the head mesh of the original Nagy leaderhead invisible, while the eyes are still visible? Both have a NiAlphaProperty after all.

I think the glitch makes only the first mesh behind invisible, in this case the head. But only parts that are covered by the first transparent mesh get invisible. Also these glitches only occur in some poses. Not sure why. I have seen this problem in some cutstom LHs by the way. I think most people don't know how to handle transparency correctly.
 
Thanks guys, that did it! The reason for why the eyes had an AlphaProperty was that I added it to solve this whole issue as I saw that either Gandhis or FDRs eyes had one, too. But that eyes were still connected with the rest of the body, so no two meshes both with Alpha. From where the body got its alpha, I don't know. Not from me.

I think the glitch makes only the first mesh behind invisible, in this case the head. But only parts that are covered by the first transparent mesh get invisible. Also these glitches only occur in some poses. Not sure why. I have seen this problem in some cutstom LHs by the way. I think most people don't know how to handle transparency correctly.
Well, I think that this is, because this behaviour is nothing one would expect from two meshes with alpha, so noone would get the connection between the glitch and the Alphas. Also, I'd guess that this is actually a bug of the engine. Maybe a term to calculate visibility that under certain circumstances delivers wrong values. Not sure if ekmek covers this in his guide, if not, you should write in his guide so that he adds the information.

If we could find a solution to the fur shader issue, I'd be really happy... Wouldn't wonder if it is a similar stupid thing.
 
Thanks, The Capo! I think I'll try to reduce the saturation on the suit a little and maybe make the eyes a bit more narrow. Besides of that, I'm satisfied with it.
 
As it actually was available already, I decided to release Nagy v1 with fixed glasses and so it's up now:

For download link, see post #1.

Since v2 is on the way, I don't think it makes nay sence to work on v1 anymore. Attached is a preview of the current look of v2. As I said, I worked on the suits colour and on the eyes shape. Besides of this, I worked a little on the eyes texture and sculpted the mouth a bit. The essential prominence (That made Nagy look like he looked and which is something related to the eyes, I think) is still missing, but I still don't know what exactly that is and so I can't do anything. Anyways, I would be satisfied with this already, only the mouth annoys me. The issue is, that the upper lip is moved a bit to one side, while the lower lips is moved to just the other side creating some strange distortion which is somewhat obvious at certain points. As v1 also had a problem with the mouth, I'm not fine with keeping the mouth like this. From what I can tell, the problem is caused by the animation. For fdr, it is not that obvious I think, and I might tweak on this if I try to line up the head with the lips bones. Nevertheless, I don't want to do so, as this could screw up other things and appears to be a less clean solution. Working on the animation would be better, I just don't know what exactly I should do to get this specific problem done. The values given in the kf don't tell me anything...

EDIT: For v2, I also added a copy of the hair part that has flipped normals to solve the glimmer at the hairline. An unclean solution, too, but but I couldn't think of anything better.
 
So I will be away for a week soon, tomorrow will be the last day I'll be around. For those that can't wait I provide a beta of Nagy v2:

http://www.mediafire.com/file/s735x226774ccyd/Nagy2beta.7z

If anyone feels attracted to give this a shot, just feel free to do so. There is nothing specific I have in mind. I personally would work on the light and shader, but I really wouldn't mind if someone else would give it a go (;)).Also, a more 'rosy' (not sure if that's the right word) teint might be better, but I'm not sure. There is just one coloured picture around that I am aware of, and that one was not really valuable, so I'd need to see the leaderhead with a different teint. The whole thing would be a matter of texture though... I am not angry about if someone tries something I haven't thought about either.
 
Hey cool!
I think your leaderhead is already awesome, you may even release him soon :)
 
Top Bottom