png file to insert a logo
› Forums › Desktop Info › png file to insert a logo
- This topic has 28 replies, 3 voices, and was last updated 3 years ago by
Glenn.
-
AuthorPosts
-
-
4 November, 2019 at 9:55 pm #2252
mitoba
Hi friends,
I’ve inserted a pnf file to insert a logo above of the info, but my logo shows a white border althought my logo is transparent.
Why it could be?
Regards.
-
5 November, 2019 at 2:41 am #2253
mitoba
Sorry, i’ve typed PNF instead of PNG.
Regards.
-
5 November, 2019 at 6:57 am #2254
perhaps you can attach the logo.
-
5 November, 2019 at 9:00 pm #2255
mitoba
-
6 November, 2019 at 1:54 pm #2256
the effect you’re seeing is the result of anti-aliasing a transparent image. when you load the image into an editor and zoom right in, you’ll see the edge pixels are partially transparent. Those partially transparent pixels are showing up as white when DTI renders them.
Now, I haven’t studied the code yet so I can’t say if that’s something I can do anything about. I’ll update you when I know more.
-
7 November, 2019 at 12:16 am #2260
mitoba
Thanks a lot. Keep in wait.
-
7 November, 2019 at 11:19 pm #2261
MistaMule
I had this problem. Try remaking your logo with a black background (or whatever your DTI background colour) but NOT transparent. Let DTI deal with the transparency.
MM-
13 November, 2019 at 9:27 am #2263
That works too! I would never have thought of that 🙂
-
-
13 November, 2019 at 9:32 am #2264
The white pixels are created during resizing and is seemingly an unavoidable consequence of resizing anti-aliased transparent images. I’ve added code to skip resizing if both logo-width and logo-height are zero.
So now you have two options: make the background black as MistaMule mentions or make it the desired size so no resizing is done.
-
14 November, 2019 at 7:02 am #2269
MistaMule
Glenn, I believe that png graphics format has a background colour value in its header.
As long as the logo file does not have a transparent background then DTI can display it correctly. My logo file has black background; I changed DTI to RED background and 25% transparency and the display was correct, background was all RED.
Tried to attach an image but I don’t have a public website.
Glenn, If you send me your e-mail address I’ll send some screen shots.
MM -
14 November, 2019 at 7:55 am #2270
There’s a button down below to attach files labelled “Browse”
-
14 November, 2019 at 8:21 am #2271
MistaMule
Glenn,
Cann’t see one labelled “Browse”! I can see b,i,link,b-quote,del,img,ul,ol,li,code,close tags.
I tried img but it asked for URL of image.
MM -
14 November, 2019 at 9:28 am #2272
-
14 November, 2019 at 6:28 pm #2275
MistaMule
Glenn, Your attachment was too small to read. I have sent the screen dumps to your support e-mail address.
I guess you think I’m a bit stupid but the only buttons I have on this screen are b,i,link,b-quote,del,img,ul,ol,li,code,close tags and 3 boxes for Name, Mail and Website and at the bottom SUBMIT.
I would send a screen print but ….MM
-
15 November, 2019 at 11:36 am #2278
You need to be a registered user.
-
15 November, 2019 at 10:16 pm #2283
Anonymous
Glenn,
Didn’t think about loggin in as a registered user.
Following on from my post on 14 November, 2019 at 7:02 am attached (hopefully) is an image of DTI to RED background and 25% transparency.
MM -
16 November, 2019 at 12:24 pm #2286
I still see a black edge around the image.
-
16 November, 2019 at 7:36 pm #2291
Anonymous
Glenn, Attached are 2 file. File DTI_composite_4rr.png shows my DTI before and after reading Mitoba’s post. File DTI_page1.png shows DTI after removing yellow line at the bottom of my logo file.
Now I admit that the final version may not be perfect but IMHO it is an improvement on what I had at the start.
Regards, Bob -
25 November, 2019 at 7:54 pm #2310
mitoba
So, Is there any solution?
Thanks.
-
25 November, 2019 at 8:26 pm #2311
1. Try mistamule’s suggestion of making the image background black.
2. Wait for v2.1 and test with logo-width and logo-height = 0
-
-
27 November, 2019 at 7:02 pm #2314
mitoba
Mistamule’s solutions doesn’t work for me.
I’ll wait for 2.1 version…
Thanks.
-
27 November, 2019 at 7:29 pm #2315
Anonymous
Mitoba, The attached image was created using your logo and ImageMagick and the following batch file.
echo off
rem create a blank black image the same width as your DTI.
convert -size 400×72 xc:black 128-58-max.png -gravity center -composite output1.png
convert output1.png -font Segoe-UI-Bold -gravity west -pointsize 24 -fill yellow -annotate +20+0 “LHS Text” output2.png
convert output2.png -font Segoe-UI-Bold -gravity east -pointsize 24 -fill yellow -annotate +20+0 “RHS Text” GMV_logo_for_DTIc.png -
29 November, 2019 at 4:26 pm #2321
I’ve been researching this some more and it all comes down to those pesky half transparent pixels around the edge of the image. The ones that are created by the anti-aliasing. If you can avoid anti-aliasing then that is probably the best thing to do. Otherwise…
The original image is gmv-0.png. You can see a close-up of the semi-transparent pixels in gmv-1.png
It will take some figuring out to deal with this in the code. But meanwhile…
You can clean these up to make it look a lot better. I loaded the image into Paint Dot Net. I used the Magic Wand tool to select the edges. Select the empty area around the outside. Adjust the Tolerance setting so it starts to include those pesky half transparent pixels but not the solid pixels. I ended up about 60% see gmv-2.png
Press delete to remove the selected pixels. Save it as 32 bit png. The result is much more pleasing. see gmv-3.png
-
This reply was modified 3 years ago by
Glenn.
-
This reply was modified 3 years ago by
Glenn.
-
This reply was modified 3 years ago by
Glenn.
-
This reply was modified 3 years ago by
-
24 January, 2020 at 2:57 am #2539
mitoba
Hi Glenn,
Could you check this in the code?
Regards.
-
24 January, 2020 at 6:48 am #2540
what would you like me to check?
-
-
5 February, 2020 at 10:49 pm #2552
mitoba
I would like to add a png file with my logo without the pixels around problem, if it possible.
Thanks.
-
6 February, 2020 at 6:39 am #2555
make sure there’s no semi transparent pixels
-
-
-
AuthorPosts
- The topic ‘png file to insert a logo’ is closed to new replies.