Hey guys,
So assembled some basic elements of my scene in UDK, and thought I'd try using a simple point light (with default parameters) in my scene to get a more accurate idea of the base diffuse textures, and I'm getting a pretty funky result - or at least not what I was expecting.
Right now, the material consists of just the diffuse and normal maps - is the lack of a specular map causing this? Should I be using a different light for previewing textures? Or is it something else? I'm still very new to the UDK, and as such I'm keen to iron out the (presumably) simple kinks so I can get a better idea of what my textures look like before making any serious adjustments in Photoshop.
Any suggestions?
As always, thanks in advance.
Replies
I went into the Static Mesh editor, and selected Mesh > Generate Unique UV's. Now, it's entirely feasible that I inadvertently changed the settings of the UV channel dropdown menus, as that's the only way I can think of I somehow ended up with four UV channels on a single mesh?
So, despite the number of channels weirdness (and the very low lightmap resolution setting, which I upped to 256 for tests with the same result), I tried creating basic lightmap UV's for a similarly simple mesh (resulting in just two UV channels this time, not four), and the lighting still looks funky using a single point light.
So actually generating UV's for the lightmap seems to have been a step in the right direction, but this is how it looks with a point light set to a radius of 512, with a brightness of FIVE:
At least the majority of the surface is visible, but I've got some serious shadowing happening (indicated in red) towards either end of the mesh (outlined in blue). Surely the light should be much more intense with those settings?
Any suggestions as to what I'm doing wrong would be awesome.
Well, I re-exported the mesh to test this solution, and indeed the materials option was checked in the .ase export dialogue. However, this doesn't solve the problem, and in addition, I'm getting this error on import:
Since I used a simple planar map to create the UV's for the wall section, I even tried scaling the UV shell down a little in case this was creating the problem shown above, but that doesn't help, either. Suggestions?
As ever, thanks in advance.
Hopefully youll solve this so you can get on with Captain nemos office, wich looks sweet by the way.
Well, re-exporting the mesh did fix the weird lightmap UV error message, but the lighting problem itself is still happening. Guess I've got some serious documentation to read today.
And thanks for the kind words about the scene in general, but it's pretty frustrating to hit this kind of a roadblock over something so (presumably) simple. I didn't want to do much in the way of texturing without being able to see it in UDK, so I guess I'll have to use a viewport shader until I can figure this out.
Thanks again for your help.
If you're exporting from Max, first try fixing the smoothing groups. A quick test, but by no means the best solution, select all faces, then in the edit poly panel, under 'Polygon Smoothing Groups', set your smoothing angle to 45 degrees and press 'Auto Smooth'.
Re-import the mesh now via .ase and you see nice hard edges, not big soft bubble like surfaces which seem to be adding to your shading issues in UDK.
Post some images after you've done this.
Cheers,
Tyler
To fix this without having to re-group things you had grouped together before, go to your editable poly and click "Select by SG". Then check off every number that shows up. Your selection will be every surface that currently has a smoothing group assigned. Invert that selection and apply an autosmooth with a very small threshold (like 5 deg) and you should be good to go.
As for the UVs issue, check how many UV channels it displays when you first import. UE3 expects (but does not require) you to use the second UV layer for your lightmaps, which must be in the 0-1 range which is why it gives that error. Chances are you have garbage information stored in your second and third UV layers. Use the UV Mapping Clear modifier in max to clear out this garbage info.
Since you are still in the process of doing your initial import of the mesh you would probably be better off making your lightmap UVs in MAX rather than using the UE3 auto generator. It's very easy to do if you aren't concerned with optimization, just copy over your primary UV layer to the second layer, flip back any inverted faces, and run an auto unpack.
Thanks again.
Well, I had originally baked a high-res to low normal map for this particular section - probably a little much, given the simplicity of the model but I intended to do this to capture the bolt details, and then overlay an image-based normal map of the diffuse to capture the surface scratches etc in Photoshop. I used a planar map for ease and simplicity, and I figured that any texture stretching would be almost negligible and would likely go unnoticed.
I tried the quick test as you suggested, and it seems to have solved the lighting errors inside UDK:
You say that this isn't the preferable option - why is that, and what would be the best approach?
So if I use Clear All to clear the smoothing groups completely, selected all the faces of the mesh and used Auto Smooth with a setting of 5 degrees, would this work? Or do you mean using this in addition to the manually-assigned smoothing groups?
How would I do this? Inside the UV editor window? Incidentally, using the UVW Mapping Clear modifier worked at clearing the garbage information from the third and fourth(?) channels, never come across that modifier before, thanks.
Thanks for everyone's patience and suggestions.