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!
Quick Reply
Search this Thread
Test Subject
Original Poster
#1 Old 15th Jul 2011 at 2:30 AM
Default Strange line in custom tattoo render.
Ive been making a few tattoos recently. I just sorted out my problem with them not scaling properly, but now one of my tattoos has a strange line underneath it where there should be no line.

I have submitted two pictures. The first one shows the render in-game of the tattoo. The line appears at all sizes, in CAS and in play.

The second picture is a screenshot of what the .dds file is made up of. I have turned on the alpha channel to give you an idea of where my alpha sits in relation to the graphic.
No, I don't have the alpha channel visible when I save.
I save using 8.8.8.8. ARGB 32 bpp unsigned.

I have several other tattoos that I have recently fixed the scaling and alphas on which do not have this error.
I first assumed it might be caused by the graphic touching the edges of the image. So I cut it back a pixel. That didn't fix things. I also have other graphics which touch the edge of the image which render fine in the game.

Does anyone know what causes this? I spent a lot of time drawing this bastard and I don't want to have to scrap it because of a stupid line.

I used the tattooinator to create the .package
Screenshots
Advertisement
Née whiterider
retired moderator
#2 Old 15th Jul 2011 at 2:36 AM
Could you attach the DDS so we can take a closer look?

What I lack in decorum, I make up for with an absence of tact.
Ms. Byte (Deceased)
#3 Old 15th Jul 2011 at 12:36 PM
My guess is that the bottom line of pixels isn't pure black, but Whiterider's right that a look at the dds would be helpful.
Test Subject
Original Poster
#4 Old 15th Jul 2011 at 5:06 PM
Here is the .dds file.

I just did a quick check and all of the pixels at the top and the bottom are coming out 0,0,0 RGB.

That was the first thing I thought of when I went back to try and fix it. The next was 0,0,0 all of the coloured pixels touching the edge - top and bottom - of the image. But I have 3 or 4 other .dds files which have coloured pixels at the edge of the image and they render properly in-game.

The thumbnail also shows this defect (see attachment.)

Thanks.
Screenshots
Attached files:
File Type: zip  AMF_Badge5.zip (85.1 KB, 10 downloads) - View custom content
Née whiterider
retired moderator
#5 Old 15th Jul 2011 at 6:56 PM
Hmm, you're quite right. Maybe you're nearing a Tattooinator/EA dimension limitation - try resizing the image down a little, to see if the same problem occurs?

What I lack in decorum, I make up for with an absence of tact.
Ms. Byte (Deceased)
#6 Old 15th Jul 2011 at 7:52 PM
It's 512x512, which is the standard, so I doubt dimensions are the problem. Resizing is something worth trying, though.

Did you check the bottom line in the alpha too, in case there's a line of opacity there? Gotta say I don't see one in the image, though, and I don't see it in the Tattooinator preview. Tonight I'll take a closer look and see if it shows up the same way in my game.
Test Subject
Original Poster
#7 Old 16th Jul 2011 at 2:27 AM Last edited by srmacpherson : 16th Jul 2011 at 2:58 AM.
Quote: Originally posted by CmarNYC
It's 512x512, which is the standard, so I doubt dimensions are the problem. Resizing is something worth trying, though.

Did you check the bottom line in the alpha too, in case there's a line of opacity there? Gotta say I don't see one in the image, though, and I don't see it in the Tattooinator preview. Tonight I'll take a closer look and see if it shows up the same way in my game.



Ah! I hadn't actually done a spot check on the values of the alpha channel. Since I had done a "fill" of 0,0,0 I assumed everything would be the same value. My "fill" command doesn't seem to want to actually fill the selected area with the value I choose. The area outside the graphic used to be white in the alpha, so when I filled it 0,0,0 it actually only went to 2,2,2.

The top and bottom lines are still 0,0,0 from before, but maybe when I re-package this .dds that may make the difference.
I'll have to test it out later tonight.


Hopefully this is just one of those silly mistakes, easily fixed.




----later----

Nope. That didn't fix things. Still have that bloody line there.
Ms. Byte (Deceased)
#8 Old 16th Jul 2011 at 2:54 AM
I noticed the 2,2,2 also and tried filling it with pure black, but it didn't help.

This is one of the weirdest things I've ever seen this game do. I tried various ways of saving the image in different formats, and kept getting the same problem. At smaller scales than your screengrab, you can actually see that the line at the bottom kind of looks like part of the image, sort of repeating. (See below.) I really think this is a bug in the tattoo rendering in the game since I can sort of see a hint of it in a couple of other tattoos. I tried scaling the image down to pull it a little over 20 pixels below the top and that helped, so if you scale and lower it a bit more that may fix it. I also was able to fix it completely by using an image with no mipmaps, making me think the game is somehow reading the mipmaps as part of the main image. Or something. Anyway, that gives you a couple of possibilities.
Screenshots
Test Subject
Original Poster
#9 Old 16th Jul 2011 at 2:59 AM
Quote: Originally posted by CmarNYC
I noticed the 2,2,2 also and tried filling it with pure black, but it didn't help.

I also was able to fix it completely by using an image with no mipmaps, making me think the game is somehow reading the mipmaps as part of the main image. Or something. Anyway, that gives you a couple of possibilities.


Very strange. All of my other tattoos save with mip-maps and work. I'll have to play around with it some more and see what I can do. But not tonight.
Thanks for your help so far.
Ms. Byte (Deceased)
#10 Old 16th Jul 2011 at 2:51 PM
I'm not saying it's the mipmaps themselves, it's clear that it's a problem with tattoos that are close to the edges but omitting the mipmaps seemed to help. Possibly it's some kind of cropping thing since the edges of the tattoo look a little cut off. Really does look like a bug in the game.

I did a similar shape tattoo from scratch with GIMP and got the same result. (pic 1) Then a triangle tattoo with the point up - this time the line was smaller and at the top, plus some barely visible bumps at the bottom. (pic 2) Then a triangle that's a little smaller and not so close to the edges, and that was fine. (pic 3) I think you just have to stay clear of the edges.
Screenshots
Test Subject
Original Poster
#11 Old 16th Jul 2011 at 5:59 PM
Well then, looks like problem solved. This might be an important note for tutorials in case other people run into this problem.

How far from the edges did you have to pull the graphic? I have 3 other .dds files that have the black outline of the tattoo touching the edge of the image, alpha included. Yet when I scaled those images, there was no issue.

Thank you for all of your help. Hopefully this will be able to help others as well.

SRMacPherson.
Ms. Byte (Deceased)
#12 Old 16th Jul 2011 at 9:54 PM
The one that's fine is well off the top and bottom edges - sorry, I didn't measure and got rid of the images. My feeling is that the amount that's up to the edge makes a difference too, in other words tattoos that only have a point or curve almost touching the edge don't seem to have a visible problem. I'll make a note in my tutorial.
Test Subject
Original Poster
#13 Old 19th Jul 2011 at 12:24 AM
Quote: Originally posted by CmarNYC
... tattoos that only have a point or curve almost touching the edge don't seem to have a visible problem. I'll make a note in my tutorial.


That seems to go with what I've got here as well. The tattoos I mentioned before that touch the edge are the edges of circular objects. Hilts of swords, tips of leaves, wings, that sort of thing.

I ran tattooinator on another tattoo I was working on that I can't get the colours to work with. It has the same shield shape as this one I'm having trouble with. In the game, it too has the same issue.

I'm pulling the image in by 12 pixels x,y and go on from there until its enough.
Thanks a tonne for all of your help.
Test Subject
Original Poster
#14 Old 19th Jul 2011 at 12:41 AM
-12pixels affects it... halfway.
The icon still clearly shows the error, but when placed on the body, the error only appears after the tattoo is enlarged beyond a certain point.
So I'm guessing that the image should be no larger than 495x495 if you have large flat edges on the image.

I wish I could make changes to the image, resave the .package and see the results live in-game without having to exit and restart.
Ms. Byte (Deceased)
#15 Old 19th Jul 2011 at 12:46 PM
We all wish Sims 3 had a separate CAS that could reload stuff the way Sims 2 did!
Back to top