Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / May 2006

Tip: Looking for answers? Try searching our database.

discoloration around text...

Thread view: 
tiewknvc9 - 08 May 2006 22:09 GMT
hi!

im writing a program that (first) creates a standard colored background
with some text drawn in front of it (with drawstring) -- all in a
graphics2D object.

Then I save the bufferedImage of the graphics2D object to the disk as a
jpeg.

I cannot see the graphics2D object that is being created, I only see
the output.

However the outputted jpeg, (which again is a VERY simple graphic
containing text and a background), appears to be pixellated all around
the text.  What I mean is that there is a discoloration.  Some pixels
around the text appear in variously similar colors to the background.

unfortunately I require a perfected image that has no discoloration.

any ideas?
Oliver Wong - 08 May 2006 22:25 GMT
> hi!
>
[quoted text clipped - 16 lines]
>
> any ideas?

   Don't use JPEG. Use, for example, PNG or BMP.

   - Oliver
Eric Sosman - 08 May 2006 22:44 GMT
tiewknvc9 wrote On 05/08/06 17:09,:
> hi!
>
[quoted text clipped - 14 lines]
>
> unfortunately I require a perfected image that has no discoloration.

   You probably shouldn't use JPEG for this application.
JPEG was designed for "real-world" images, not for synthetic
images with "cartoon-like" sharp edges.  See Question 3 in
the JPEG FAQ

    http://www.faqs.org/faqs/jpeg-faq/part1/

Signature

Eric.Sosman@sun.com



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.