Save image as jpeg

I need help

"I need help" doesn't tell us anything. You could be absolute beginner and don't know how to change the file type as gener7 mentioned, or you are using more advanced methods like changing the color bits per channel to something greater than 8. An example of that is the usage of camera raw files, when they get imported into photoshop they generally come in a 16 bits per channel. In that example saving as jpeg will not work in older versions of photoshop as jpeg is an 8 bits per channel file format. In photoshop CC they added a bit of code that detects you are trying to save as jpg when your in 16 bit mode and changes it for you.
Now I went through all these details just to show why "I need help" can be overly simplified for a response. This is why it is always a good idea to post what version of photoshop you have, if it standard or extended (CS6 or earlier) or from the cloud (CC) or even elements which is a watered down version of photoshop.
It is also a good idea to post what operating system you have and what version it is. And finally if it is relevant post a capture of your screen, especially if you do not know how to ask the question such as terminology for example.
Ok, I am done, I hope you can solve your issue.

Similar Messages

  • Save Image into JPEG in increment fashion

    Hi,
    I have an Image in which i want to save it on incremental fashion,
    since directly save it using ImageIO.write(BufferedImage, String, File) method
    will make me to create a huge BufferedImage.
    I want to avoid it (huge BufferedImage) since it will make me to have huge memory which create "java.lang.OutOfMemoryError: Java heap space" exception.
    Is there any way to save image in increment fashion (into JPEG /JPG) so that i can use few memory
    as much as possible? (I can create partially BufferedImage of the Image which if combined will contain full Image)
    Thanks and Regards,
    Ady
    Edited by: Chopperfly on Jul 28, 2008 3:53 AM
    Edited by: Chopperfly on Jul 28, 2008 8:10 PM

    Olek wrote:
    Hi,
    If you would install an additional library you could use JAI -> see the
    java advanced imaging forum at this site.
    There you can read and save images in many ways.
    Here is an example for storing a tiff
    public boolean storeTIFF(BufferedImage pic, File file) throws FileNotFoundException{
    try {
    ImageEncoder ie = ImageCodec.createImageEncoder("tiff", new FileOutputStream(file), new TIFFEncodeParam());
    ie.encode(pic);
    return true;
    catch (IOException ioe) {
    ioe.printStackTrace();
    return false;
    }OlekI don't see how this has anything to do with OP's request.
    @OP: Why are you using such large images? What are you doing? Have you tried increasing the heap size? I'd like to know more. I've done lots of work with graphics/images and don't recall hitting this problem. Even if you have an image that was like 8000 x 8000 x 4 channels, that would be less than 300 megs of memory.

  • Safari 6.0.5 Mac won't "SAVE IMAGE AS" jpegs from web pages

    Hi. Trying to figure out what has changed here.
    In the past, when I've located a specific graphic on a web page — say, a .png or .jpg file through a Google image search in Safari — I could right click and choose "SAVE IMAGE AS" and download the image to my desktop.
    No more.
    Now Safari insists on appending ".webarchive" to the end of the file (for example, "image.jpg.webarchive" or "image.png.webarchive"), but won't let me download it. I tried to "SAVE IMAGE AS" a file called 27.png from a web page, for example, and got this error message:
    If I try to remove the ".webarchive" extension, I get this error message:
    I used to be able to simply right click an image, select "SAVE IMAGE AS" and save .jpg and .png files to my desktop. It still works that way in Firefox.
    I am not looking for workarounds or other ways to do this, as I have spent many years doing it this way and it has become habit; I am trying to find out how I can get the old Safari behavior back. Any ideas on why this behavior changed in Safari and how I can revert?

    @andyBall_uk
    Inexplicably, it is now working as it should. I don't get it, but I am not going to question it. I tried to figure it out for an hour, then read your reply, did the duck search you linked to and had no trouble "SAVING PICTURE AS" in .jpg form. It now works on the original images I was trying to download as well. I did not close or open Safari, nor did I restart my computer.
    I'm just going to go ahead and say that you fixed whatever was wrong. Nice work!

  • "Save image" button of Camera Raw does not save JPEG with modifications made.

    I am using Bridge CC to process my RAW images and make modifications to some JPEG images as well.  I have no need to further alter images in Photoshop at the moment, so I do all modifications in Camera Raw. After altering my images, I then press the "save image" button at the left bottom corner of Camera Raw and choose the settings to save in JPEG.  However, when I upload these JPEG images to a website or when I email them, the image is uploaded without the modifications I had done!  It seems to me that Camera Raw is saving JPEGs the same way it does for RAW images, in a non-destructive manner, only attaching instructions for the images to be displayed properly on Photoshop. But when I save an image in JPEG, I expect the image to be saved entirely with the modifications I made while still keeping the original RAW file.  What goes on then?  What is Camera Raw doing and how do I get to save a modified image in JPEG with Camera Raw?  Would you please explain?
    Many thanks for your help,
    Beza

    Hi,
    What version of camera raw and operating system are you using?

  • How do i save image as a Jpeg?

    I cant work out how to save my image so i can print it!!

    There are two ways. File>save as  or File>Save For Web.
    Either option will save as a jpeg. In the save as dialog box look toward the bottom for a file type box. Click it and you can choose from a variety of file formats there including jpg. If you see a bunch of formats but jpg is not listed, then odds are your in the wrong mode. Jpg is only supported in 8 bits per channel. Goto Image>Mode then choose 8bits/channel.
    As for save for web - In the upper righthand corner of that dialog box you can choose a preset or select the drop down box for the file format.

  • I have problems with uploading images to my printing company have the images have been manipulated through CS6 i have saved images as jpeg but the printer company tell me they are not j peg, they will not upload images save from a camera are fine

    I have problems with uploading images to my internet printing company when  the images have been manipulated through CS6 and  i have saved images as jpeg  the printer company tell me they are not j peg,
    but images saved from my phone or camera images that have not been manipulated upload fine, What am i doing wrong?

    Save/Export them as JPG. Photoshop defaults to PSD, so make sure you select JPG and not just rename the file to .jpg.
    There are two ways to save them as JPG: Regular Save as option or Save for Web & Devices
    Take your pick.

  • How do I save modified RAW images in JPEG format?

    Hi,
    I have several RAW images that I mass modified with the "Camera Raw" editor (I modified one and applied the changes to all other images). How can I now save the modified images as JPEG images? I know I could open each file in Photoshop and save it as JPEG there, but that would take A LONG time.
    Thanks for any pointers!
         Mark

    They have to be opened, one by one, before the adjustments are applied and the image files saved, but the process can be automated.  For instance through the already included Image Processor, or Image Processor Pro, also pre-installed, or through Actions and Droplets you create yourself.

  • Can't Save a Big TIFF 16 bit RGB Image to JPEG

    Hi all,
    I'm using Photoshop CS5 Extended on Windows 7 64 bit (Home Premium).
    I've stitched a panorama in Photoshop using merge from 19 RAW files (Canon 5D mkII) in 16 bit. All was fine, I saved the merged image as TIFF 16 and worked on it. Resolution of the panoramic image is around 33000x4900. File flattened and no active selections left.
    Once I was happy I ran Image Processor on it with an action to watermark and add EXIF copyright data. This failed saying that it could not save to JPEG (it performed the action correctly, just stopped at saving it). This normally works fine with other TIFF 16 RGB images I have done.
    I tried to save it manually, but at that point I noticed that the "save for web" option was grayed out and that the "Save As" dialog did not display JPEG in the options.
    What I did:
    1.) tried to open it with ACR and save it as JPEG. This has worked fine
    2.) tried to resize it to 20000x3600 (more or less) and it worked fine (meaning the option to save it as JPEG where back there)
    3.) tried to convert it full-size to 8 bit and that did not work
    I'm not too bothered because I have the ACR workaround, but it is annoying and in the past I've done bigger panoramas with CS4 and I've never encountered this problem before now.
    Any ideas?
    The image is almost 1 GB so I'm not going to post it...
    Thanks for your help!

    My inital thoguht was: there must be some size limit on the JPEG format that this person is hitting.
    So a quick Google search later (quicker than posting a thread!) and I found this: http://kb2.adobe.com/cps/325/325073.html Although it's focussed on CS2/3 it seems that the limit of 30,000 pixels vertical or horizontal has remained in place for CS5.
    M

  • How to save multiple images from jpeg to psd?

    I'm pretty new at this and have tons of vacation photos. Things I've read have left me terrified of leaving my images in jpeg, but I don't know how to save them all to .psd (and is that really the format I want to use?). I tried, and suddenly I'm out of space on my harddrive, so I think I've made copies of copies and have way more saved than I need. Any advice is appreciated - thanks.

    <[email protected]> wrote<br />> ...Things I've read have left me terrified of leaving my images in jpeg...<br /><br />Andrea,<br /><br />If the JPEG files are straight out of your camera, there is no harm in <br />"leaving" them as-is...  they don't degrade from just sitting there.<br /><br />The possible degradation of JPEG files comes from saving as a JPEG - <br />typically after you have done an edit to the image.<br /><br />One good way to approach the issue:  when you open an image for editing, <br />before you do anything, click the menu File > Save As...  and then choose <br />the PSD file type.  This will make a copy for you to work with, which will <br />NOT degrade as you save, re-edit, re-save, etc.  After you're finished <br />working it over, if you need a JPEG copy, use the File > Save As...  and <br />select JPEG to make an edited copy in the smaller file format.  (File > Save <br />For Web is also useful for this - it allows you to set your quality and size <br />parameters on-the-fly as you save)<br /><br />HTH,<br /><br />Byron

  • How to save applet in image(gif/jpeg) format

    Hi there !
    how to save applet in image (gif/jpeg) format. i have just gone through JIMI package where serilization is there ,WHERE U CAN SORE in image format ...........can anybudy help me out.........if possible then pleeez provide me some example.
    Thanks in advan...........

    I think that is possible because i have seen some commercial applets that do that.
    -http://www.izhuk.com/painter/
    -http://www.lawrencegoetz.com/programs/signature/
    Thses two saves the image in the server since applets cant write in the host they are running. Maybe it would be possible whit JFS, i don't know.
    For now I am trying to store an image draw in the applet on my server.
    My idea now is copying the image to a buffer or something, open a connection to the server and receive the image with a perl CGI.
    There is an example with text:
    -http://java.sun.com/docs/books/tutorial/networking/urls/readingWriting.html
    I want to do something similar but with an image.

  • How can I save images as a bitmap instead of jpeg format?

    I would like to save images I find at web sites in bitmap format.
    However it seems only jpeg type format is the way firefox will let me save images. Is there a way to save images in bitmap format?

    Firefox will only save an image in the format that it is delivered in, it has no file type conversion capabilities.

  • How to save Camera Raw image as JPEG

    I have opened a jpeg as Camera Raw (7.3) and adjusted it and wanted to save it as jpeg, but the only option is *.dng? Any ideas?
    Thanks

    You have to open it into the Elements Editor and save from there.  The Adobe Camera Raw plug-in for regular Photoshop, not Elements, will allow saving from within the plug-in but not the Elements version of ACR.

  • New to using Firefox with MAC: How does one save a single jpeg image from the web (as in a right click on a pc?)

    New to using Firefox with MAC: How does one save a single jpeg from the internet, similar to using the right mouse click on a pc?

    If your question comes about because you have a single button mouse, it's time to visit your local computer store and get a ''real'' mouse for that MAC. I don't "get" Apple, they sell their hardware for almost twice what a comparable PC would sell for - and then they leave out what is probably the most important time saving control, the right-button.
    See this for setting the hidden pref for context menus in Firefox, for Mac's.
    http://kb.mozillazine.org/Ui.click_hold_context_menus
    type '''about:config''' in the URL bar and hit Enter
    Pref Name = '''ui.click_hold_context_menus'''
    Double-click to Toggle to '''True'''

  • Blurry smart objects in Photoshop Save for Web jpegs

    I create graphs, etc in Illustrator, place them as Smart Objects in a master Photoshop file before outputing Save for Web jpegs to use as PowerPoint slide backgrounds. Everything created in Illustrator or Photoshop through that process (Quality 80 or 100 with any of the SfW options on or off) Save for Webs are blurry when imported (at 100%) into PowerPoint. The only way I have been able to get anything crisp in PowerPoint was saving a Photoshop pdf. However, that was only the text created in Photoshop. The Illustrator Smart Object part was still blurry. Anyone have any idea on the best process to combine Photoshop and Illustrator files into one file for import into PowerPoint as a clean, crisp background? At this point I am open to all suggestions.

    There are parts that are being added in Photoshop, hence going from Illustrator through Photoshop as a Smart Object and then onto PowerPoint. If I wasn't 5 months down the line and just nearing deadline, I would recreate everything in Illustrator. Assuming that I have to continue at this point down the Illustrator through Photoshop line of working, how do you designate pngs or jpegs to be 220ppi. Jpegs have a 1-12 quality (and 12 is still blurry).
    Note regarding PowerPoint, I embed the full-page image into the background so others that are using this can't move (by accident or on purpose) the background.

  • How to play/record at same time and save image from video

    i started working on a project and that made my life hell although it was so simple. reason was that i couldnt find small/simple code to understand problems and no proper documents. . finally i have done that. and here is the code (without much complex code of interface). it shows vidoe, records a small part of it at start and takes a snapshot (no buttons or events involved). hope it might help someone starting to learn JMF.
    import java.io.*;
    import java.awt.*;
    import java.net.*;
    import java.awt.event.*;
    import java.util.Vector;
    import javax.media.*;
    import javax.media.rtp.*;
    import javax.media.rtp.event.*;
    import javax.media.rtp.rtcp.*;
    import javax.media.protocol.*;
    import javax.media.protocol.DataSource;
    import javax.media.format.AudioFormat;
    import javax.media.format.VideoFormat;
    import javax.media.Format;
    import javax.media.format.FormatChangeEvent;
    import javax.media.control.BufferControl;
    import javax.media.control.FrameGrabbingControl;
    import javax.imageio.ImageIO;
    import java.util.Date;
    import javax.media.util.BufferToImage;
    import java.awt.image.BufferedImage;
    * AVReceive2 to receive RTP transmission using the new RTP API.
    public class AVReceive2 implements ReceiveStreamListener, SessionListener,
    ControllerListener
    public static DataSource ds2, ds, ds3;
    String sessions[] = null;
    RTPManager mgrs[] = null;
    Vector playerWindows = null;
    boolean dataReceived = false;
    Object dataSync = new Object();
    public AVReceive2(String sessions[]) {
    this.sessions = sessions;
    public static DataSource getData() {
    return ds;
    protected boolean initialize() {
    try {
    InetAddress ipAddr;
    SessionAddress localAddr = new SessionAddress();
    SessionAddress destAddr;
    mgrs = new RTPManager[sessions.length];
    playerWindows = new Vector();
    SessionLabel session;
    // Open the RTP sessions.
    for (int i = 0; i < sessions.length; i++) {
    // Parse the session addresses.
    try {
    session = new SessionLabel(sessions);
    } catch (IllegalArgumentException e) {
    System.err.println("Failed to parse the session address given: " + sessions[i]);
    return false;
    System.err.println(" - Open RTP session for: addr: " + session.addr + " port: " + session.port + " ttl: " + session.ttl);
    mgrs[i] = (RTPManager) RTPManager.newInstance();
    mgrs[i].addSessionListener(this);
    mgrs[i].addReceiveStreamListener(this);
    ipAddr = InetAddress.getByName(session.addr);
    if( ipAddr.isMulticastAddress()) {
    // local and remote address pairs are identical:
    localAddr= new SessionAddress( ipAddr,
    session.port,
    session.ttl);
    destAddr = new SessionAddress( ipAddr,
    session.port,
    session.ttl);
    } else {
    localAddr= new SessionAddress( InetAddress.getLocalHost(),
    session.port);
    destAddr = new SessionAddress( ipAddr, session.port);
    mgrs[i].initialize( localAddr);
    // You can try out some other buffer size to see
    // if you can get better smoothness.
    BufferControl bc = (BufferControl)mgrs[i].getControl("javax.media.control.BufferControl");
    if (bc != null)
    bc.setBufferLength(350);
    mgrs[i].addTarget(destAddr);
    } catch (Exception e){
    System.err.println("Cannot create the RTP Session: " + e.getMessage());
    return false;
    // Wait for data to arrive before moving on.
    long then = System.currentTimeMillis();
    long waitingPeriod = 30000; // wait for a maximum of 30 secs.
    try{
    synchronized (dataSync) {
    while (!dataReceived &&
    System.currentTimeMillis() - then < waitingPeriod) {
    if (!dataReceived)
    System.err.println(" - Waiting for RTP data to arrive...");
    dataSync.wait(1000);
    } catch (Exception e) {}
    if (!dataReceived) {
    System.err.println("No RTP data was received.");
    close();
    return false;
    return true;
    public boolean isDone() {
    //return playerWindows.size() == 0;
    return false;
    * Close the players and the session managers.
    protected void close() {
    for (int i = 0; i < playerWindows.size(); i++) {
    try {
    ((PlayerWindow)playerWindows.elementAt(i)).close();
    } catch (Exception e) {}
    playerWindows.removeAllElements();
    // close the RTP session.
    for (int i = 0; i < mgrs.length; i++) {
    if (mgrs[i] != null) {
    mgrs[i].removeTargets( "Closing session from AVReceive2");
    mgrs[i].dispose();
    mgrs[i] = null;
    PlayerWindow find(Player p) {
    for (int i = 0; i < playerWindows.size(); i++) {
    PlayerWindow pw = (PlayerWindow)playerWindows.elementAt(i);
    if (pw.player == p)
    return pw;
    return null;
    PlayerWindow find(ReceiveStream strm) {
    for (int i = 0; i < playerWindows.size(); i++) {
    PlayerWindow pw = (PlayerWindow)playerWindows.elementAt(i);
    if (pw.stream == strm)
    return pw;
    return null;
    * SessionListener.
    public synchronized void update(SessionEvent evt) {
    if (evt instanceof NewParticipantEvent) {
    Participant p = ((NewParticipantEvent)evt).getParticipant();
    System.err.println(" - A new participant had just joined: " + p.getCNAME());
    * ReceiveStreamListener
    public synchronized void update( ReceiveStreamEvent evt) {
    RTPManager mgr = (RTPManager)evt.getSource();
    Participant participant = evt.getParticipant();     // could be null.
    ReceiveStream stream = evt.getReceiveStream(); // could be null.
    if (evt instanceof RemotePayloadChangeEvent) {
    System.err.println(" - Received an RTP PayloadChangeEvent.");
    System.err.println("Sorry, cannot handle payload change.");
    System.exit(0);
    else if (evt instanceof NewReceiveStreamEvent) {
    try {
    stream = ((NewReceiveStreamEvent)evt).getReceiveStream();
    //DataSource
    ds2 = stream.getDataSource(); // this original cant be used now
    // ds is used to play video
    ds = Manager.createCloneableDataSource(ds2);
    // ds3 is used to record video
    ds3 = ((SourceCloneable)ds).createClone();
    // Find out the formats.
    RTPControl ctl = (RTPControl)ds.getControl("javax.media.rtp.RTPControl");
    if (ctl != null){
    System.err.println(" - Recevied new RTP stream: " + ctl.getFormat());
    } else
    System.err.println(" - Recevied new RTP stream");
    if (participant == null)
    System.err.println(" The sender of this stream had yet to be identified.");
    else {
    System.err.println(" The stream comes from: " + participant.getCNAME());
    // create a player by passing datasource to the Media Manager
    Player p = javax.media.Manager.createPlayer(ds);
    if (p == null)
    return;
    p.addControllerListener(this);
    p.realize();
    PlayerWindow pw = new PlayerWindow(p, stream);
    playerWindows.addElement(pw);
    // Notify intialize() that a new stream had arrived.
    synchronized (dataSync) {
    dataReceived = true;
    dataSync.notifyAll();
    } catch (Exception e) {
    e.printStackTrace();
    return;
    else if (evt instanceof StreamMappedEvent) {
    if (stream != null && stream.getDataSource() != null) {
    DataSource ds = stream.getDataSource();
    // Find out the formats.
    RTPControl ctl = (RTPControl)ds.getControl("javax.media.rtp.RTPControl");
    System.err.println(" - The previously unidentified stream ");
    if (ctl != null)
    System.err.println(" " + ctl.getFormat());
    System.err.println(" had now been identified as sent by: " + participant.getCNAME());
    else if (evt instanceof ByeEvent) {
    System.err.println(" - Got \"bye\" from: " + participant.getCNAME());
    PlayerWindow pw = find(stream);
    if (pw != null) {
    pw.close();
    playerWindows.removeElement(pw);
    * ControllerListener for the Players.
    public synchronized void controllerUpdate(ControllerEvent ce) {
    Player p = (Player)ce.getSourceController();
    if (p == null)
    return;
    // Get this when the internal players are realized.
    if (ce instanceof RealizeCompleteEvent) {
    PlayerWindow pw = find(p);
    if (pw == null) {
    // Some strange happened.
    System.err.println("Internal error!");
    System.exit(-1);
    pw.initialize();
    pw.setVisible(true);
    p.start();
    try {
    // make it wait so that video can start otherwise image will be null. u must call this method with a button
    Thread.sleep(2500);
    catch (Exception e) {
    e.printStackTrace();
    // Grab a frame from the capture device
    FrameGrabbingControl frameGrabber = (FrameGrabbingControl) p.getControl(
    "javax.media.control.FrameGrabbingControl");
    Buffer buf = frameGrabber.grabFrame();
    // Convert frame to an buffered image so it can be processed and saved
    Image img = (new BufferToImage( (VideoFormat) buf.getFormat()).
    createImage(buf));
    BufferedImage buffImg = new BufferedImage(img.getWidth(null),
    img.getHeight(null),
    BufferedImage.TYPE_INT_RGB);
    Graphics2D g = buffImg.createGraphics();
    g.drawImage(img, null, null);
    // Overlay curent time on image
    g.setColor(Color.RED);
    g.setFont(new Font("Verdana", Font.BOLD, 12));
    g.drawString( (new Date()).toString(), 10, 25);
    try { // Save image to disk as PNG
    ImageIO.write(buffImg, "jpeg", new File("c:\\webcam.jpg"));
    catch (Exception e) {
    e.printStackTrace();
    // this will record the video for a few seconds. this should also be called properly by menu or buttons
    record(ds3);
    if (ce instanceof ControllerErrorEvent) {
    p.removeControllerListener(this);
    PlayerWindow pw = find(p);
    if (pw != null) {
    pw.close();
    playerWindows.removeElement(pw);
    System.err.println("AVReceive2 internal error: " + ce);
    * A utility class to parse the session addresses.
    class SessionLabel {
    public String addr = null;
    public int port;
    public int ttl = 1;
    SessionLabel(String session) throws IllegalArgumentException {
    int off;
    String portStr = null, ttlStr = null;
    if (session != null && session.length() > 0) {
    while (session.length() > 1 && session.charAt(0) == '/')
    session = session.substring(1);
    // Now see if there's a addr specified.
    off = session.indexOf('/');
    if (off == -1) {
    if (!session.equals(""))
    addr = session;
    } else {
    addr = session.substring(0, off);
    session = session.substring(off + 1);
    // Now see if there's a port specified
    off = session.indexOf('/');
    if (off == -1) {
    if (!session.equals(""))
    portStr = session;
    } else {
    portStr = session.substring(0, off);
    session = session.substring(off + 1);
    // Now see if there's a ttl specified
    off = session.indexOf('/');
    if (off == -1) {
    if (!session.equals(""))
    ttlStr = session;
    } else {
    ttlStr = session.substring(0, off);
    if (addr == null)
    throw new IllegalArgumentException();
    if (portStr != null) {
    try {
    Integer integer = Integer.valueOf(portStr);
    if (integer != null)
    port = integer.intValue();
    } catch (Throwable t) {
    throw new IllegalArgumentException();
    } else
    throw new IllegalArgumentException();
    if (ttlStr != null) {
    try {
    Integer integer = Integer.valueOf(ttlStr);
    if (integer != null)
    ttl = integer.intValue();
    } catch (Throwable t) {
    throw new IllegalArgumentException();
    * GUI classes for the Player.
    class PlayerWindow extends Frame {
    Player player;
    ReceiveStream stream;
    PlayerWindow(Player p, ReceiveStream strm) {
    player = p;
    stream = strm;
    public void initialize() {
    add(new PlayerPanel(player));
    public void close() {
    player.close();
    setVisible(false);
    dispose();
    public void addNotify() {
    super.addNotify();
    pack();
    * GUI classes for the Player.
    class PlayerPanel extends Panel {
    Component vc, cc;
    PlayerPanel(Player p) {
    setLayout(new BorderLayout());
    if ((vc = p.getVisualComponent()) != null)
    add("Center", vc);
    if ((cc = p.getControlPanelComponent()) != null)
    add("South", cc);
    public Dimension getPreferredSize() {
    int w = 0, h = 0;
    if (vc != null) {
    Dimension size = vc.getPreferredSize();
    w = size.width;
    h = size.height;
    if (cc != null) {
    Dimension size = cc.getPreferredSize();
    if (w == 0)
    w = size.width;
    h += size.height;
    if (w < 160)
    w = 160;
    return new Dimension(w, h);
    public void record(DataSource ds) {
    Format formats[] = new Format[1];
    formats[0] = new VideoFormat(VideoFormat.CINEPAK);
    FileTypeDescriptor outputType =
    new FileTypeDescriptor("video.x_msvideo");
    Processor p = null;
    try {
    p = Manager.createRealizedProcessor(new ProcessorModel(ds,formats,
    outputType));
    } catch (IOException e) {
    e.printStackTrace();
    } catch (NoProcessorException e) {
    e.printStackTrace();
    } catch (CannotRealizeException e) {
    e.printStackTrace();
    // get the output of the processor
    DataSource source = p.getDataOutput();
    // create a File protocol MediaLocator with the location
    // of the file to
    // which bits are to be written
    MediaLocator dest = new MediaLocator("file://vvv.mpeg");
    // create a datasink to do the file writing & open the
    // sink to make sure
    // we can write to it.
    DataSink filewriter = null;
    try {
    filewriter = Manager.createDataSink(source, dest);
    filewriter.open();
    } catch (NoDataSinkException e) {
    e.printStackTrace();
    } catch (IOException e) {
    e.printStackTrace();
    } catch (SecurityException e) {
    e.printStackTrace();
    // now start the filewriter and processor
    try {
    filewriter.start();
    } catch (IOException e) {
    e.printStackTrace();
    p.start();
    try {
    Thread.sleep(10000);
    }catch(Exception e) { }
    p.close();
    filewriter.close();
    // stop and close the processor when done capturing...
    // close the datasink when EndOfStream event is received...
    public static void main(String argv[]) {
    //     if (argv.length == 0)
    //     prUsage();
    String[] a = new String[1];
    a[0] = ("192.168.0.45/4002");
    AVReceive2 avReceive = new AVReceive2(a);
    if (!avReceive.initialize()) {
    System.err.println("Failed to initialize the sessions.");
    System.exit(-1);
    // Check to see if AVReceive2 is done.
    try {
    while (!avReceive.isDone())
    Thread.sleep(1000);
    } catch (Exception e) {}
    System.err.println("Exiting AVReceive2");
    static void prUsage() {
    System.err.println("Usage: AVReceive2 <session> <session> ...");
    System.err.println(" <session>: <address>/<port>/<ttl>");
    //System.exit(0);
    }// end of AVReceive2
    so here the code. all messed up. coz i have just completed it and havent worked on interface or formatting this code properly (didnt have much time). but hope it will help. ask me if u have any questions. dont want others to have those basic problems that i had to face.

    u did a good effort for the JMF beginners i appreciate that....thanks i lot....i need you help in a project in
    which i have to connect to a d-link 950G IP camera and process that
    mpeg-4 stream (i know there are some problems in JMF and mpeg4) and show it over applet of JFrame.
    IP is 172.25.35.22
    Edited by: alchemist on Jul 16, 2008 6:09 AM

Maybe you are looking for

  • Can't create a print queue on OS 10.7 via HP driver installed by Apple

    I've ust bought a reconditioned iMac and am getting applications up and running, but I'm unable to get my HP Laserjet 2200DN printer working. The Add Printer pane (Print & Scan Preferences) remains blank: Name & Location and Print Using & Add areas a

  • Search external hard drive

    I just got my Mac two days ago and I cannot search for movies on my external hard drive. I tried to add and remove through System Preferences-Spotlight-Privacy then add/remove but I still can't search it.

  • Usage Reporting via client object model

    Hi, Is there any way that I can get the site last modified date, unique visitors per month via client object model? Is it so that to get the site last modified date i have to loop into all lists/libraries and get the lastitemmodifieddate property? -P

  • HT5622 Download game for my apple id

    I download game

  • Windows Vista Driver for Sound Blaster 5.1 P

    I want driver for Windows Vista 32 Bit edition for Sound Blaster 5. PCI sound card. I have loaded the Windows XP driver but as a result of that it is playing audio in 2 speaker stereo mode, but i have creative 5. speaker system. As a result of that s