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 / January 2008

Tip: Looking for answers? Try searching our database.

jpeg  image compression using java source code

Thread view: 
Avinash.Masal@gmail.com - 02 Jan 2008 07:55 GMT
Urgent please.... how to compress a single jpeg image frame to
maintain  quality and  half of it's original storage size using java
source code.........
Andrew Thompson - 02 Jan 2008 08:26 GMT
>Urgent please....

What is your budget for this 'urgency'?
(And if '0$', why should we care?)

Signature

Andrew Thompson
http://www.physci.org/

Joshua Cranmer - 02 Jan 2008 23:25 GMT
> Urgent please.... how to compress a single jpeg image frame to
> maintain  quality and  half of it's original storage size using java
> source code.........

public class JavaJPEGCompressor {
    public final static byte[] compressImage(byte[] image) {
         byte[] ret = new byte[image.length/2];
         System.arraycopy(image, 0, ret, 0, ret.length);
         return ret;
    }
}

Exactly half the size, but I don't think it's quite a legal image. It's
also technically the same quality...

Send me $10.00 in the mail immediately for your time ;-) .

Signature

Beware of bugs in the above code; I have only proved it correct, not
tried it. -- Donald E. Knuth

Jeff Higgins - 03 Jan 2008 00:14 GMT
Avinash wrote:
> Urgent please.... how to compress a single jpeg image frame to
> maintain  quality and  half of it's original storage size using java
> source code.........

Please note the earlier replies.

The Java Advanced Imaging Project

<https://jai.dev.java.net/>

advertises lossless JPEG plugins.

<http://preview.tinyurl.com/3e5dm4>

I have no experience with this API.


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



©2008 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.