Aller au contenu

Photo

Shadow Fix.


  • Veuillez vous connecter pour répondre
22 réponses à ce sujet

#1
Jedijax

Jedijax
  • Members
  • 395 messages
I've been thinking about this for some time, since most of my creatures are already custom, overriding models, and I think there is a tool in the Vault specificaly named and designed for such, but I decided it would be best to post here before I tried it.

Many of my creatures' shadows are off, showing straight lines out of their heads, or definitely coming out entirely wrong, as a bunch of lines strayed towards the infinite. Since Estelindis was able to fix such issues  in an update of her KOTOR Heads pack, I was wondering, how can I fix the shadows of my very own creature and weapon models?

I appreciate any insight you may share on the matter! :D

Modifié par Jedijax, 05 décembre 2010 - 11:38 .


#2
Pstemarie

Pstemarie
  • Members
  • 2 745 messages
Straight line shadows from the head is definitely a poly problem - that is to say that your poly count is too high for the engine to actually render a shadow properly. What you need to do is make a shadow-box that is roughly the same shape as the head, but has less faces (and thus less verts).

The easiest way is to copy one of the Bioware heads, position it so it overlays the head_g node, set it to Render 0, then parent it to the head_g node. Be sure to change the name of your shadow-box to something different than "head_g" - I typically use something like "shadbox_g".


I'm sure if you look at Este's heads (or many of the models that LoW has done), you'll see that she used this method to fix the shadow issues with the KotR heads.

Modifié par Pstemarie, 07 décembre 2010 - 09:42 .


#3
Jedijax

Jedijax
  • Members
  • 395 messages
Oooh!! So basically, we would be interposing another model's shadow... cle-ver. Can the same be done with other body parts? Some of my creatures' shadows are all lines, from head to toe...

#4
Pstemarie

Pstemarie
  • Members
  • 2 745 messages
You can do this little "trick" with any object. Just make sure that you turn the shadow OFF for the object you are having issues with.

#5
CalSailX

CalSailX
  • Members
  • 56 messages
Didn't see it mentioned, but one thing to check is if you have verts that need welding. Doesn't always fix issues with shadows, but generally the first place I start and depending on the model may square away the shadow problem, before resorting to the above "trick". No guarantee, but checking for verts that need to be welded has fixed the shadows of at least 40% - 50% of the shadows that were driving me buggy. Most of these were old models and the sanity check of the model would give me the list of verts that might need attention.

#6
Jedijax

Jedijax
  • Members
  • 395 messages
...err... you lost me at welding, friend! I barely know how to save models after modification! HAAHAHAHAHHAAHAHA!! Thank you nonetheless!

#7
CalSailX

CalSailX
  • Members
  • 56 messages
I stink at explaining this stuff, welding might well be the wrong term. The situation I try to address is when you have two ajoining poly's in your model that should share a vert, but instead you find two verts almost side by side leaving a gap that you might not even see in the surface of the model. That gap in the surface of the model makes for wacky things happening when the engine trys to render a shadow for the object.



Selecting the two ajoining verts in your modeling program and collapsing them so they become a single vert shared by both polys closes the gap in the model surface and may fix a shadow issue. IE: welding/collapsing the two verts together to make a single vert.




#8
Jez_fr

Jez_fr
  • Members
  • 302 messages
CalsailX you don't suck at explaining. It's just Jedijax doesn't have the modeller's knowledge to know what a vert is, or what welding means in that context :P

That said, I agree with you on the welding. I've also used this holy trinity on a number of placeables with success:

- "remove isolated vertices"

- Center the pivot to the object (everytime you move or alter the model)

- Reset Xform (everytime you center the pivot)


#9
Jedijax

Jedijax
  • Members
  • 395 messages
:( excuse me while I go cry on my pillow...

#10
Lord Sullivan

Lord Sullivan
  • Members
  • 560 messages
This...

Jez_fr wrote...

That said, I agree with you on the welding. I've also used this holy trinity on a number of placeables with success:
- "remove isolated vertices"
- Center the pivot to the object (everytime you move or alter the model)
- Reset Xform (everytime you center the pivot)


AND check to make sure you don't have isolated or double or extra inverted polygons

Pstemarie wrote...

Straight line shadows from the head is
definitely a poly problem - that is to say that your poly count is too
high for the engine to actually render a shadow properly. What you need
to do is make a shadow-box that is roughly the same shape as the head,
but has less faces (and thus less verts).

The easiest way is to
copy one of the Bioware heads, position it so it overlays the head_g
node, set it to Render 0, then parent it to the head_g node.


Total misinformation, the engine can take whatever amount of polys you thtow at it and still render shadows properly...and that aspect is mostly limited by hardware performance i.e. (Processor power, amount of system memory and graphic card power+amount of memory)

The addition of a lower poly head model to act as the shadow map is a workaround for those with a lack of experience in modeling for NWN and possibly some other games aswell.

Modifié par Lord Sullivan, 11 décembre 2010 - 10:15 .


#11
Zwerkules

Zwerkules
  • Members
  • 1 322 messages

Lord Sullivan wrote...


The addition of a lower poly head model to act as the shadow map is a workaround for those with a lack of experience in modeling for NWN and possibly some other games aswell.




Really? I haven't worked with creatures, but I can see the benefit of having a low poly model with about 100 faces casting the shadow instead of 1000 faces. It is always a good idea to keep the poly count low and those 100 faces might be enough to cast the shadow and you might not even be able to tell the difference between the shadow of the low poly and the high poly version. Okay, the 100 faces are an additional 100 faces so the poly count goes up, but the number of polies that cast a shadow go down, that should speed things up, shouldn't it?

I don't see the point of what you said anyway. I thought these forums are here to encourage people to make more custom content, not to tell some of them that they lack the experience to model for NWN or even other games.
Experience is something you aren't born with. We live to learn.
A comment like that doesn't encourage people to learn, but to quit what they are doing because you told them they aren't good enough at it.

#12
Jedijax

Jedijax
  • Members
  • 395 messages
I... uh... don't mean to interrupt the flow of ideas, but... uhm... is there like, a tutorial or something I could follow, step by step?...

#13
Pstemarie

Pstemarie
  • Members
  • 2 745 messages

Lord Sullivan wrote...

Pstemarie wrote...

Straight line shadows from the head is
definitely a poly problem - that is to say that your poly count is too
high for the engine to actually render a shadow properly. What you need
to do is make a shadow-box that is roughly the same shape as the head,
but has less faces (and thus less verts).

The easiest way is to
copy one of the Bioware heads, position it so it overlays the head_g
node, set it to Render 0, then parent it to the head_g node.


Total misinformation, the engine can take whatever amount of polys you thtow at it and still render shadows properly...and that aspect is mostly limited by hardware performance i.e. (Processor power, amount of system memory and graphic card power+amount of memory)

The addition of a lower poly head model to act as the shadow map is a workaround for those with a lack of experience in modeling for NWN and possibly some other games aswell.




Thanks Sully for correcting me on that. You are right - compared to a lot of others I'm still a novice in many areas, especially shadows. I was just going by what I've read in other, older posts - which were obviously posted by people that know less than you do. :bandit:

Modifié par Pstemarie, 11 décembre 2010 - 11:11 .


#14
Pstemarie

Pstemarie
  • Members
  • 2 745 messages

Jez_fr wrote...

CalsailX you don't suck at explaining. It's just Jedijax doesn't have the modeller's knowledge to know what a vert is, or what welding means in that context :P
That said, I agree with you on the welding. I've also used this holy trinity on a number of placeables with success:
- "remove isolated vertices"
- Center the pivot to the object (everytime you move or alter the model)
- Reset Xform (everytime you center the pivot)


Jez, thanks for posting that. I've tried it out on a few models that were having shadow issues and have been able to repair those issues.

Very useful information, unlike some others *cough* Sully *cough* *cough*

Now back to the topic (without my brand of sarcasm):

Welding Verts in GMax
  • Select "verts" from the object rollout in the right hand pane (it'll be up at the top)
  • Click "Edit" in the File Menu then "Select All" - or you can drag your cursor over the object.
  • Hit < CRTL > + < W >
This will "weld" all the verts in the model that need to be - and can be - welded.

Modifié par Pstemarie, 11 décembre 2010 - 12:03 .


#15
Zwerkules

Zwerkules
  • Members
  • 1 322 messages
Jedijax, I found some information on shadows here: http://ccg.animecafe...p?title=Shadows

Pstemarie, is there a typo in your previous post? You wrote 'Select Now'. Did you mean 'Select All'?

Modifié par Zwerkules, 11 décembre 2010 - 11:42 .


#16
Lord Sullivan

Lord Sullivan
  • Members
  • 560 messages
So pointing out that there might be some folks that do lack experience and might choose to use
a workaround and a clever one at that is offensive to some?

Ok let me re-phrase, not everyone in this community that take up creation of custom 3D models are
as experienced as others, thus don't know all the proper practices in creating 3D Models properly
which as an effect may find alternatives to fixing some model problems.

Is that better?

As for how to, I did point out that Jez-fr was right on point minus the line I added in my post.
[sarcasm] Yeah you're probably right, I must be absolutely discouraging! [/sarcasm]

@PsteMarie

I only pointed out that "YOU" have been misinformed seeing you were passing along the misinformation.

Now I'm not going explain myself for every single post in the future... please grow a pair  :P

Modifié par Lord Sullivan, 11 décembre 2010 - 01:04 .


#17
Pstemarie

Pstemarie
  • Members
  • 2 745 messages

Lord Sullivan wrote...

@PsteMarie

I only pointed out that "YOU" have been misinformed seeing you were passing along the misinformation.

Now I'm not going explain myself for every single post in the future... please grow a pair  :P


Got a pair, thanks. :happy:

Just pointing out, through gest, that if you're going to make statements about proper ways to do something, at least point out what those ways are so that people that lack your knowledge of 3D models can learn something from the post.

I never intended my sarcastic gest to be taken as a stab at your considerable skills. Good God man, one need only look at your models to see the breadth of your knowledge and skills. Sorry if my funning around got your back up...

To all the Community members out there....SHARE what you know - or think you know (as was my case on this subject). A large portion of the Community has moved on, leaving a rather large gaping hole in the skill pool, and those of us left can learn a lot from each other.  Furthermore, if you find something offensive in the way its worded, try to remember that some aren't as eloquent as others with the keyboard. If the other party intended to flame, that  intention will become apparent very soon.

Modifié par Pstemarie, 11 décembre 2010 - 01:20 .


#18
Lord Sullivan

Lord Sullivan
  • Members
  • 560 messages

Zwerkules wrote...

Lord Sullivan wrote...


The addition of a lower poly head model to act as the shadow map is a workaround for those with a lack of experience in modeling for NWN and possibly some other games aswell.




Really? I haven't worked with creatures, but I can see the benefit of having a low poly model with about 100 faces casting the shadow instead of 1000 faces. It is always a good idea to keep the poly count low and those 100 faces might be enough to cast the shadow and you might not even be able to tell the difference between the shadow of the low poly and the high poly version. Okay, the 100 faces are an additional 100 faces so the poly count goes up, but the number of polies that cast a shadow go down, that should speed things up, shouldn't it?

I don't see the point of what you said anyway. I thought these forums are here to encourage people to make more custom content, not to tell some of them that they lack the experience to model for NWN or even other games.
Experience is something you aren't born with. We live to learn.
A comment like that doesn't encourage people to learn, but to quit what they are doing because you told them they aren't good enough at it.



Some of my reply is in the previous post.

You make a good point on the "100 faces vs 1000 faces' but the way the shadow system works is it will take
the backfaces according to the axis position withing a model(Object) and according to the angle(s) of the camera.
So you could say that at any given time, the shadows equate about 35 % of a oval shaped object such as a
head of a character model, so you're really looking at "30-45 faces vs 350-450" on the exemple data were using
here and that in real life performance is not really noticeable even going from "100 faces vs 3000" is hardly a hit
on performance by todays gaming hardware standards(performance)

#19
Lord Sullivan

Lord Sullivan
  • Members
  • 560 messages

Pstemarie wrote...

Lord Sullivan wrote...

@PsteMarie

I only pointed out that "YOU" have been misinformed seeing you were passing along the misinformation.

Now I'm not going explain myself for every single post in the future... please grow a pair  :P


Got a pair, thanks. :happy:

Just pointing out, through gest, that if you're going to make statements about proper ways to do something, at least point out what those ways are so that people that lack your knowledge of 3D models can learn something from the post.

I never intended my sarcastic gest to be taken as a stab at your considerable skills. Good God man, one need only look at your models to see the breadth of your knowledge and skills. Sorry if my funning around got your back up...


lol... Ok well I just wanted to clear up that what I said was not a stab at you. ;)

What do you mean share your knowledge, I thought I did, so did Jez_fr... urrgh, you're not expecting
a 10 mile long tutorial post now are you? :P

I jest, I'm almost sure there must be some tuts in the old forum archives somewhere or even on
some existing community websites.

But if I ever find the time, I'll make a few.

#20
Pstemarie

Pstemarie
  • Members
  • 2 745 messages
lol - that's the teacher in me coming out. I'm forever at the kids I work with to explain "why". My wife is always saying I forget the medium I'm in at the moment - guess this is the case here...

My God, my wife is actually right - I am turning into a crotchety old SOB :crying:

#21
Lord Sullivan

Lord Sullivan
  • Members
  • 560 messages
@Pstemarie: "In soviet Russia, you not have work, work has you"

@Jedijax
Here are some representation of 3D Lingo:

Image IPB

This way you'll now have an idea of what we're talking about

I hope that will help you understand us a little better.

#22
Jedijax

Jedijax
  • Members
  • 395 messages
I... err... thank you all, but it seems I will need to familiarize with 3ds max on a deeper level in order to say something remotely meaningful...



Nice weather, huh?...

#23
Renzatic

Renzatic
  • Members
  • 86 messages

Lord Sullivan wrote...

Here are some representation of 3D Lingo:

Picture


Hell, even I learned something new there. I always thought vertice was the singular, and vertex the plural. I guess that explains why everyone looks at me dumb whenever I'm explaining this stuff. :P