Home | Download | Discussion | Help | Site Map | New Posts | Sign in

Latest Site News

New Creator Theme: Elders! - posted on 1st Sep 2018 at 11:43 AM
Replies: 17 (Who?), Viewed: 851 times.
Theorist
Original Poster
#1 Old 13th Sep 2018 at 3:14 AM
Default Bump mapping on objects
Ok sooo... the only thing I saw bump maping on in Sims 3 is clothes, walls and floors and few other objects like curtains, a single bar and it's matching counters and the bot making station from ITTF. The rest is all flat textures with specular.

Sooo... I decided to dig a bit and I found that the resource that has normal map on those objects has "_n_" after the name of the global resource (object's resource name) and then a random (or maybe not, but for now to me it looks random) hexadecimal code. I tried adding imilar thing (normal map resource) to another mesh but it won't show up (I'm probably doing something wrong). However I managed to change current normal map of another object. It also seems that normal map is strictly tied to parts of the mesh and has a special UV in some cases. But the bot station does not have that and is using actual UV all the other textures use. So I'm really confused?



Why don't more than 90% objects in this game have normal maps while it's supported, and how can this be further investigated? I will probably investigate some more about this, but I hope some simmers also know more than I do.
Advertisement
Puffin McMuffin
staff: administrator
#2 Old 13th Sep 2018 at 8:30 AM
As far as my understanding regarding the why it doesn't work for all objects and/or a special UV map is needed, is actually possible due to the MATD, or well, shaders If you check the shaders of the bar you edited it might actually show a different shader probably than it's regular 'Phong' or 'phong alpha'. I also found though that some objects would totally glitch after adding a bump map.

Another suggested theory could be that the XML file that calls all textures basically as well as details simply don't seem to have an entry for normal maps, and thus, I guess, what I should have done when I did add a bump map, is using that of maybe clothing, if not, objects that do support it.

However, I think the only reason I can think of is just due to rendering. The sims 3 is a 32 bit game so it's more meant to be a laptop game than anything else. You can also clearly see that the game doesn't like high poly meshes due to it's nature.

But tbh I should probably look into a few things like the XML file or if it's shader related. I do know objects, as long as they have a different group, are capable of having entirely different UV maps so it might just be that.
Theorist
Original Poster
#3 Old 13th Sep 2018 at 8:41 AM Last edited by mixa97sr : 13th Sep 2018 at 9:26 AM.
Shader theory would be totally correct as, unlike the rest of the textures that load after the mesh is loaded/rendered, normal map loads WITH the mesh, in the same instance.

I'll look more into curtains today to see what separates those objects from normal ones. Plus, that base game shower also has a bump map on glass. That must be hard to pull off.

EDIT: and that about ts3 being a laptop game and having problems with high poly meshes. I'm having hard time believing that. It is true that ts3 is a 32 bit app and therefore has limited memory usage. But it is definitely NOT optimized for even some medium grade PCs and let alone laptops. Plus, most of the EA meshes are higher poly because absence of normal maps meant that they had to mesh the details...

But. I agree as to why normal maps would not fit most of the EA objects and thats... The way game loads textures. Which is really, really slow. If a normal map was included, and giving that the game would now have to render additional texture plus usage of additional shader, being limited on memory usage, Sims 3 would only run worse than it already does.
Which is sad, because as that, Sims 3 would have been the most graphically complete sims game ever. I never wanted ts3 64 bit till now.
Theorist
Original Poster
#4 Old 14th Sep 2018 at 11:23 AM Last edited by mixa97sr : 14th Sep 2018 at 12:21 PM.
Ok shader theory is incorrect as when viewed in TSRW every object that has a normal map has Phong shader, like every other object. And normal map texture when viewed in S3PE is not indexed in any of the XMLs... So yes, this is weird. Importing normal map in TSRW shows properly imported normal map (aside for problems with drop shadow) but then it does not show in the game :/

But the interesting thing I haven't tried is _KEY package resource. Normal map is listed there in a specific place for all the objects that DO have a normal map. If I manage to add a normal map just as a normal _IMG resource in sim PE and then edit the _KEY resource to add it to the listing, it would be super nice if it worked like that :D

Further testing shall commence.

EDIT: Another interesting thing I noticed is that the name of the normal map also coincides with the overlay and multiplier names. Overlay and multiplier names have that hex code after it and overlay comes one place before the multiplier. Normal map comes before the overlay for just one place as well.
Mad Poster
#5 Old 14th Sep 2018 at 1:17 PM Last edited by GrijzePilion : 14th Sep 2018 at 1:27 PM.
All I know is, not all material shaders support normals. They can't be applied to terrain textures or CASt patterns, for example.

Although I'm not sure what point you're trying to make @mixa97sr, I do agree that it would be nice if a larger portion of the game's objects came with normals. It's perfectly possible for just about every buyable or buildable object in the game to have proper normal mapping. Best you can do is make them yourself, but that would require a significant amount of manual labor. And even then, they may not look as good as EA's. I suspect though that it would considerably improve the appearance of the average interior scene, since normal maps can do a hell of a lot to make certain materials appear more realistic. Think heavy woods, wools, leathers, but also seams and bevelled edges. I find that quite often, objects appear flat and lifeless. And there's nothing worse than a flat, featureless surface.

On the same topic: is there any benefit to AO mapping? TS3 supports AO maps, but I don't believe it's entirely clear what their purpose is. They also aren't used very much, if at all.

Look out for BRIDGEPORT'88 - it's the hottest new show on YT this season!
Already renewed for '89!

(Oh, and follow me on my Tumblr.)
Theorist
Original Poster
#6 Old 14th Sep 2018 at 6:22 PM
Ts3 AO is mainly done in the multiplier map, which is a toned down of what blender would bake as AO.

Also don't teach me how to make normal maps, I do know how to bake a normal map from a high detail sculpted object to low poly object, and it would surely be a better normal map than ea's because ea mainly uses low rez normal maps.



Sims 3 CAST materials are good, great even, but they are just that, materials, not shaders. They are specular mapped and have color data, but they are still, just a flat texture with only a shine to it.

But no, the technical part of normal mapping is that, no, it isn't possible if you don't change and edit an awful lot of resources in S3PE. I'm testing this with other people on discord group and it's a pain in the ass. You first have to make a new texture instance, change MATD refferences to add both normal map and normal map UV selector, and Lyra is also editing the TXTC resources.

If she suceeds (because no method for now gave results of normal map appearing in game on objects that we tried to add it to), then there should be a way. I hope that she or someone of us posts a tutorial on it, if it works... because EA never made it easy, and modding community haven't made the proper tools to support TS3 shader/mapping options.
Lab Assistant
#7 Old 14th Sep 2018 at 6:30 PM
Quote:
Originally Posted by GrijzePilion
All I know is, not all material shaders support normals. They can't be applied to terrain textures or CASt patterns, for example.

Although I'm not sure what point you're trying to make @mixa97sr, I do agree that it would be nice if a larger portion of the game's objects came with normals. It's perfectly possible for just about every buyable or buildable object in the game to have proper normal mapping. Best you can do is make them yourself, but that would require a significant amount of manual labor. And even then, they may not look as good as EA's. I suspect though that it would considerably improve the appearance of the average interior scene, since normal maps can do a hell of a lot to make certain materials appear more realistic. Think heavy woods, wools, leathers, but also seams and bevelled edges. I find that quite often, objects appear flat and lifeless. And there's nothing worse than a flat, featureless surface.

On the same topic: is there any benefit to AO mapping? TS3 supports AO maps, but I don't believe it's entirely clear what their purpose is. They also aren't used very much, if at all.


Our normal maps wouldn't be as good as EA's right? I don't wanna flex too much but if you say that you probably have probably never seen any of my work. Or even mixa's work!
Here's a sneak peek to destroy your theory hun
Theorist
Original Poster
#8 Old 14th Sep 2018 at 6:34 PM
Don't flame the thread tho, it's supposed to be a thread for researching how to even get the normal maps to work in the game at all!
Mad Poster
#9 Old 15th Sep 2018 at 11:57 AM
Don't flex on me, hun. This is a thread for figuring some technical stuff out, not a sass-off. That's a pretty sexy normal though, I'd say that's a standard we should all try to live up to.

Look out for BRIDGEPORT'88 - it's the hottest new show on YT this season!
Already renewed for '89!

(Oh, and follow me on my Tumblr.)
Theorist
Original Poster
#10 Old 15th Sep 2018 at 1:04 PM
Personally I'd say that that normal can be way better... but it's a sims game with low rez textures so, that's the best you can go with that :D

However, there's been progress and TXTC files have nothing to do with it (except taking part in forming the whole graphical representation of the objects in the game). I realised how MODL and MLOD resources are formed and that TGI in those resources is a referencing list that references other resources used in those resources.
The resources in the MATD chunk entry of the MLOD/MODL resources have to abide the order of the TGI list their referenced instances are ordered in... yeah this all sounds complicated and it gets even more complicated because to add a new texture you both have to add it to the MATD chunk of the MODL/MLOD resource and to TGI, and resources in MATD and TGI references of those resources have to be in the SAME ORDER. However, to do this, you would have to edit the MLOD/MODL binary/HEX code, but if you edit it manualy there will be offsets and the edited code will be... well broken. So the only way to do this is to have the editor of S3PE binary type of some kind...

And some people made it some time ago, and this is still being looked at There's still hope for normal maps!
Mad Poster
#11 Old 15th Sep 2018 at 2:15 PM
Wait so what exactly are you guys doing, you're finding out how to add normals to assets that don't already have them? Or are you trying to figure out how to add normals to asset types that don't normally support them?

Look out for BRIDGEPORT'88 - it's the hottest new show on YT this season!
Already renewed for '89!

(Oh, and follow me on my Tumblr.)
Lab Assistant
#12 Old 15th Sep 2018 at 2:51 PM
Quote:
Originally Posted by GrijzePilion
Wait so what exactly are you guys doing, you're finding out how to add normals to assets that don't already have them? Or are you trying to figure out how to add normals to asset types that don't normally support them?

We're trying to add normal maps to objects that don't have them to begin with. Very little objects support normal mapping natively in The Sims 3 and we're trying to add this possibility to an object that doesn't have this possibility in order to come up with steps for everyone to try themselves. It is quite curious that nobody wondered about this on the internet, so we were also curious to see how hard it would be.
Mad Poster
#13 Old 15th Sep 2018 at 4:53 PM
Wait, so what kinds of objects don't have the normal mapping then? I've never really looked into object modding much but most clothing items seem to have normal mapping. The vehicle models have normals, though possibly not all of them, and so do several statues. So maybe I'm just wrongly assuming that most of everything else has them as well. Now that I think about it, in fact, I don't recall ever seeing any normals on the PCs I've edited......or any chairs.....or any microwaves......

Well shit, count me in. I never even knew this was a problem. I'm someone who claims to be very fixated on graphics, but this has completely escaped my prying gaze. Now I'm outraged. Outraged, I tell you!

Look out for BRIDGEPORT'88 - it's the hottest new show on YT this season!
Already renewed for '89!

(Oh, and follow me on my Tumblr.)
Theorist
Original Poster
#14 Old 15th Sep 2018 at 7:41 PM
Yeah, most of the objects that aren't sims don't have normal maps.

Wallpapers and tiles support it, sims suport it, most of the curtains have it, most of the cars have it, a base game shower has it on the glass, most of the game's water obviously has animated normal maps, benches from base game have it on the overlay, the base game traditional bar and it's matching counters have it and the bot station from into the future has it... and probably few other objects. But all the other objects in the game do not have normal maps... and apparently even after understanding what is different and successfuly adding it to the obejct that does not have it, it still won't show up in the game.

I might be overlooking something, but for right now, I have no idea what that might be. TGI only references the IMG resources but what is important is the order of the resources loaded into MATD (material), who only use those TGI list references to connect to the images/textures they are using. Normal map in the MTNF part of the MATD is loaded first, and we managed to do that and successfully reference it to TGI and corresponding _IMG and TXTC resources, but... It's still not enough. There is something else different in packages with EA normal maps. And we still have to figure that out.
Mad Poster
#15 Old 15th Sep 2018 at 8:04 PM
Okay, just to play a bit of a devil's advocate: I assume you're using S3PE here. I'd do the same. But have you looked into what tools like TSRW and CTU can do? As I understand TSRW, it makes it very easy to add new resources to an asset.

Look out for BRIDGEPORT'88 - it's the hottest new show on YT this season!
Already renewed for '89!

(Oh, and follow me on my Tumblr.)
Theorist
Original Poster
#16 Old 15th Sep 2018 at 8:30 PM
TSRW breaks packages. I tried going that way and adding a normal map is impossible because it adds resources of the same instance over and over again, and even if it's managable, for adding TGI entries I'd have to export a package from TSRW but if I do that, then the package resources get corrupted!

I don't know what CTU is and might give it a go, but for now I'm using S3PE, and it was extremely helpful till now. Now I'm stuck and do not know what to do. The only difference between the two is lighting data which has occluders in package with normal map and does not have it in packages without it... and I don't know how and why can occluders affect the normal map.
Mad Poster
#17 Old 15th Sep 2018 at 8:37 PM
I've had some shader related issues with normals as well, see here. Still haven't gotten it to work. But TSRW corrupts packages you say? Are you using a version that came out after TS4 did? Because if so, yeah, it's broken. I'm using an old version Lyralei had lying around somewhere and it's perfectly fine as far as I'm aware.

Look out for BRIDGEPORT'88 - it's the hottest new show on YT this season!
Already renewed for '89!

(Oh, and follow me on my Tumblr.)
Theorist
Original Poster
#18 Old 15th Sep 2018 at 8:49 PM
@GrijzePilion

Oh I'm looking at that and yes I know a lot of that already (except the normal map being set to reskey type which is TXTC in S3PE, tho I don't even think it matters). Older version of TSRW would come in handy! Luckily I'm in contact with Lyra :D
Back to top