Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!
Ms. Byte (Deceased)
Original Poster
#51 Old 3rd Jan 2021 at 2:29 PM Last edited by CmarNYC : 3rd Jan 2021 at 5:04 PM.
Quote: Originally posted by tau534
Unless I've missed something this is the best I've got without spending more time than I want to on it. I've figured out a color ordering that seems to beat EA's in some cases and I've minimized the length of inline color runs.


This is almost perfect - I can get file sizes that are very close to EA's with mip quality that's also very close. Thank you, great work! You've already helped much more than I expected.

So I truly hate to do this to you but there's one image that doesn't convert correctly - when you load the converted LRLE, in the first mip there are small artifacts around the eyeball that get worse in the lower mips. Maybe it has something to do with it being full color with no transparency.

Edit: Your previous version didn't do this.

Edit2: I've attached just the write class with a few tweaks I tried. Using Array.Copy instead of = resulted in it hanging, and removing the part where you back up the color run fixed that but seems to work like your previous version.

I'm running into the same problem in my version.
Attached files:
File Type: zip  S4_2BC04EDF_00000000_D30E1BF8313204DC%%+UNKN.zip (1.28 MB, 67 downloads)
File Type: zip  tauTweaks.zip (2.1 KB, 37 downloads)

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Advertisement
Test Subject
#52 Old 3rd Jan 2021 at 6:21 PM
Try this, it works on my end with your new mipmap creation changes.
Attached files:
File Type: zip  tauTweaks.zip (2.1 KB, 47 downloads)
Ms. Byte (Deceased)
Original Poster
#53 Old 3rd Jan 2021 at 6:49 PM
So far this version is perfect with everything I've tried it on. Unless something comes up I think we have a winner. I'm uploading the new version for testing and will still poke around a little.

Thanks so much for everything!

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Test Subject
#54 Old 3rd Jan 2021 at 9:27 PM
Your welcome.
Instructor
#55 Old 9th Jan 2021 at 11:54 PM
Beeteedubs, if you two haven't seen this yet...

https://twitter.com/lowpolypancake/...079360391299072
https://twitter.com/lowpolypancake/...999403395964928

It's a UI mod -- that's what enables the sliders to show up in other parts of CAS at all -- and then anything in the included categories that's been converted to LRLE will work with it. This guy's literally starting by converting damn near every CAS texture in the case game to LRLE. LOOK WHAT YOU HAVE WROUGHT!
Ms. Byte (Deceased)
Original Poster
#56 Old 10th Jan 2021 at 2:01 AM
That's pretty awesome. Do you know if it only works with LRLE textures? There's no reason it couldn't work with any kind of texture unless EA restricted it to LRLE. If I can find the actual download I'd like to see what they did.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Test Subject
#57 Old 10th Jan 2021 at 3:40 AM
Hello! Idk where I may ask, but I saw Cidira shared the link of UI mod here. It seems like author of this mod are not planning to do it for Skin details or tatto, at least for cc. I create skin details and make up and if you in any way can create similar mod for other cas parts it would be the most irreplaceable mod ever. (Sorry again for the off-topic)
Instructor
#58 Old 10th Jan 2021 at 4:48 AM
There's no download yet, it's still in development. Seems like it's getting pretty close, though. I'm not sure what you mean about it not being restricted to LRLE, though, since I haven't heard about anyone being able to get any of the sliders except opacity to actually do anything on non-LRLE makeup, even though they were slideable. (I do recall the light-dark slider works on custom skintones even if they're RLE2, though.)

@dobro Questions about the mod should go to the modder.
Ms. Byte (Deceased)
Original Poster
#59 Old 10th Jan 2021 at 6:03 AM
Yes, I meant there's no reason I know of that any texture can't have it's hue, saturation, and brightness shifted by a slider since they all decompress to a bitmap, but EA may have set up the game somehow to only do it with LRLEs. I know DDS can be handled directly by the GPU, but there's nothing special like that about LRLE that I know of.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Instructor
#60 Old 10th Jan 2021 at 2:12 PM
Given that makeup just automatically gets working sliders once converted, and that I've been told the same thing happens with anything enabled by the UI mod, I'm guessing EA has put such a limitation in place. The question is whether it can be circumvented. That limitation may not be so easily accessible as the slider code.

There's some interesting stuff on Pancake's Patreon about having used a neural net to improve textures. No techie details, though, just pictures and the mention of having done so.
Test Subject
#61 Old 10th Jan 2021 at 8:52 PM
I suspect the reason for the EA preventing the sliders from working with RLE2 has to do with RLE2 being compressed DXT5 data and artifacts caused by the DXT5 format. I doubt it can be circumvented, it's likely hardcoded in the exe.
Forum Resident
#62 Old 12th Jan 2021 at 5:00 AM
Hiya! thepancake1 here. Yep, recoloring is restricted purely to LRLEs. I strongly suspect this was due to compression artifacts, as they straight up look terrible on some shades without using a neural net for deartifacting.
Here is what I mean.
DDS recolored

Denoised DDS recolored


@CmarNYC and @tau534, thank you so much for figuring it out! I particularly disliked hair not being recolorable. EA with their blueish "black" hair just drove me insane. I've reimplemented it in python, which I'd like to share soon.
Instructor
#63 Old 13th Jan 2021 at 1:30 AM
@simmythesim Oh goodness yes, I can't wait to be able to desaturate every black hair in the damn game. (And darken quite a few, too. The combination of those two things will prevent me from needing to do a full-game overhaul of the black hair texture. I'm looking forward to this so much.)
Lab Assistant
#64 Old 13th Jan 2021 at 6:42 AM
Hi all, firstly thank you so much Cmar and tau for cracking this format!
I was playing around with LRLEs in anticipation for pancake's mod, and when I was using dark LRLE textures I noticed a lot of artifacts that aren't there in my RLE2 textures.

See this example, the first picture is the RLE2 version, and the second is the LRLE version.

I know these formats are prone to compression artifacts but I thought LRLE was meant to alleviate some of it, at least it did for the skintones patch, which is confusing why it's a lot worse in this case.
Not sure if this is a problem on my end or if the format just isn't good for some things.
Ms. Byte (Deceased)
Original Poster
#65 Old 13th Jan 2021 at 8:13 AM
Quote: Originally posted by jwofles
Hi all, firstly thank you so much Cmar and tau for cracking this format!
I was playing around with LRLEs in anticipation for pancake's mod, and when I was using dark LRLE textures I noticed a lot of artifacts that aren't there in my RLE2 textures.

See this example, the first picture is the RLE2 version, and the second is the LRLE version.
...
I know these formats are prone to compression artifacts but I thought LRLE was meant to alleviate some of it, at least it did for the skintones patch, which is confusing why it's a lot worse in this case.
Not sure if this is a problem on my end or if the format just isn't good for some things.


LRLE is compressed but lossless so there should be no artifacts generated by compression/decompression if everything's working correctly. Could you explain your process - how did you generate these textures and using which tools? Could you upload your original texture which I assume is a custom PNG? Do the artifacts appear in the textures the same way as in game?

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Test Subject
#66 Old 13th Jan 2021 at 5:25 PM
The only reasons I can think for the artifacts is either EA has some filtering going on for RLE2 or some mipmap issue. To be honest, if I look closely I can see the same artifacts on the RLE2 version just smoothed out and toned down.
Ms. Byte (Deceased)
Original Poster
#67 Old 13th Jan 2021 at 6:38 PM
Quote: Originally posted by tau534
The only reasons I can think for the artifacts is either EA has some filtering going on for RLE2 or some mipmap issue. To be honest, if I look closely I can see the same artifacts on the RLE2 version just smoothed out and toned down.


This makes sense if the texture was extracted from RLE and converted straight to LRLE complete with its DXT compression artifacts. Interestingly, a skin creator told me he did that with a skin definition texture and the LRLE version looked better. Either way, the real test is to start with an original full quality png or uncompressed DDS.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Lab Assistant
#68 Old 13th Jan 2021 at 10:37 PM Last edited by jwofles : 13th Jan 2021 at 10:58 PM.
Here are my files - https://www.simfileshare.net/download/2271266/

My process for testing this was taking an old cc of mine, changing a couple of the swatches to LRLE type on s4s, and then importing the LRLEs from the LRLE tool using s4pe.
I made 3 LRLEs;
'RLE2export' was the RLE2 texture exported to .png from s4s and then converted to LRLE using the tool from this thread. In the package this is the green swatch.
'photoshopExport' is the original texture exported from photoshop as a .png, and then converted to LRLE using the tool again. In the package this is the blue swatch.
'hqPhotoshopExport' is the same as the one before, but I exported it in the hq texture size from photoshop. In the package this is red swatch.

The package also has a black swatch which is the RLE2 texture.
In game the RLE2 export and photoshop export looked identical, but the hq texture looked different. The original RLE2 texture still looked better than all the LRLEs.

Here's a picture of the rle2export LRLE, photoshopexport LRLE, the hq photoshopexport LRLE, and then the RLE2. Graphics setting on max with uncompressed sim textures on.

In s4s and the LRLE converter the textures all look identical, so I guess this is the game doing some weird filtering?
Ms. Byte (Deceased)
Original Poster
#69 Old 13th Jan 2021 at 11:34 PM
Quote: Originally posted by jwofles
Here are my files - https://www.simfileshare.net/download/2271266/

My process for testing this was taking an old cc of mine, changing a couple of the swatches to LRLE type on s4s, and then importing the LRLEs from the LRLE tool using s4pe.
I made 3 LRLEs;
'RLE2export' was the RLE2 texture exported to .png from s4s and then converted to LRLE using the tool from this thread. In the package this is the green swatch.
'photoshopExport' is the original texture exported from photoshop as a .png, and then converted to LRLE using the tool again. In the package this is the blue swatch.
'hqPhotoshopExport' is the same as the one before, but I exported it in the hq texture size from photoshop. In the package this is red swatch.

The package also has a black swatch which is the RLE2 texture.
In game the RLE2 export and photoshop export looked identical, but the hq texture looked different. The original RLE2 texture still looked better than all the LRLEs.

Here's a picture of the rle2export LRLE, photoshopexport LRLE, the hq photoshopexport LRLE, and then the RLE2. Graphics setting on max with uncompressed sim textures on.

In s4s the textures all look identical, so unless s4s is displaying it wrong I guess this is the game doing some weird filtering?


Thanks. I exported the textures from the package as png and I can't see a significant difference, they all have the same subtle artifacts. It's entirely possible my eyes just aren't picking up differences, though. I'd be interested in starting with an original texture that has no artifacts to see if a LRLE made from it is artifact free.

It's certainly possible the game processes textures differently by format - it only does hue sliders on LRLE for example. It may compensate for RLE2 artifacting by doing a little smoothing.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Test Subject
#70 Old 14th Jan 2021 at 5:11 AM
All I've gathered from my testing so far is that, one,I need a stand still in cas mod, two, which is related, the artifacts don't appear when using the club outfit editor, and three the artifacts appear in live mode.
Ms. Byte (Deceased)
Original Poster
#71 Old 19th Jan 2021 at 3:20 PM
I've experimented a bit more by taking jwofles's texture, smoothing it as much as I could, and importing it as LRLE to one swatch and as RLE2 to another. In CAS the LRLE version has very significant artifacts (worse than before) while the RLE2 version has the same artifacts but less visible. I then extracted the LRLE version back to png and it looks identical to the original, at least to my eyes. The file size is bigger than the original png and I don't know what to make of that. It does look like the game smooths RLE2, or maybe it just doesn't render LRLE very well on clothing.

Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.

Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Instructor
#72 Old 20th Jan 2021 at 2:34 AM
I wonder if one of the reasons for switching some things to LRLE is to be able to get the same or better result without smoothing, then? Since their LRLE textures are presumably all saved from never-compressed working files in PSD format or whatever else they use, they don't have the same amount of issues with compression artifacts that we do, since so much of what we do begins with EA RLE2s.

I'm going to see if @simmythesim wants to chime in on this again, though, given the work he's done on improving clothing textures in LRLE conversion.
Forum Resident
#73 Old 21st Jan 2021 at 10:27 AM
I think DDS has some smoothing\blurring applied to it. From what I see, the source textures have been re-exported to LRLE. Without any loss in compression, it most likely displays the texture without any post-processing. Either that or somehow, one of the parts in the conversion process is going wrong. Maybe the dds to png step is the one going wrong?
Lab Assistant
#74 Old 28th Jan 2021 at 10:41 PM
I did a bit more testing on a couple things.
Firstly, as pancake / @simmythesim released their mod, I wanted to see if their textures looked different. I found that similar compression artifacts were happening on their textures files too.
This is just reassuring more than anything because I wasn't sure if I wasn't doing something wrong lol.

The other thing I tried was using S4S to convert my textures. They support DDS and .png import, however they both gave the same result.
The compression seemed to be a little bit better but there's still very apparent artifacting compared to the original.

Quote: Originally posted by tau534
All I've gathered from my testing so far is that, one,I need a stand still in cas mod, two, which is related, the artifacts don't appear when using the club outfit editor, and three the artifacts appear in live mode.

This is really interesting, and confusing. I checked it out in my game too and found that the club outfit editor/mannequin outfit editor had no artifacts.

You guys are right about there being some smoothing to RLE2, and that LRLE doesn't look good on clothing. Perhaps LRLE does get smoothed on skintones and makeup, but not other categories because it isn't used, and in that sense, the engine just doesn't support the use of LRLE elsewhere.
The things that confuse that (at least for me) is that the mannequin CAS has no artifacts, the textures exported by this tool or in the S4S viewport have no artifacts, and the textures that S4S converts has different artifacts to the one in the tool. I can't really wrap my head around that.

Either way I'm so grateful for the work done on this format and I apologise for my nit-picking, all this just has me really puzzled lol.
Forum Resident
#75 Old 6th Feb 2021 at 9:00 PM
@jwofles, I got to reproduce your findings in-game. Interestingly, it's a compression issue. The Repeat Color command seems to be causing this. I forced it to use the Copy Color Command for all colors in a texture and it worked much better.

Before:

After:

@CmarNYC @tau534. I've tried debugging my code and your C# code, but the results are similar. It leads me to believe that the Repeat Color command has a bug in the EA code itself.
Page 3 of 4
Back to top