Please help, why if fade on images so sloow

Hi all,
I'm sorry for crossposting but javafx is too slow for simplest fade in effect, and no one is here to help me :( :( :(
the original post is here: http://forums.sun.com/thread.jspa?threadID=5365155
it even has points if anyone is willing to help.
I reall think that such a simple effect should'nt be slow (especialy with d3d).

The code is in the original post
http://forums.sun.com/thread.jspa?threadID=5365155
I've made this one because there were no answers there,

Similar Messages

  • Please help: Why JMF does't play .avi video clip?

    The player doesn't play .avi media file, or plays sound only, but it works fine when palying .mpg files, anything I need to pay attention to when using the following code to generate a player to play video clips?
    import java.awt.*;
    import java.awt.event.*;
    import java.io.*;
    import javax.swing.*;
    import javax.media.*;
    public class PlayClip extends JFrame {
    //singliton design pattern
    private static PlayClip instance;
    protected Player player;
    private File file= new File ("goal.avi");
    private PlayClip () {
    instance=null;
    initComponents();
    public static PlayClip getInstance(){
    if (instance==null)
    instance=new PlayClip ();
    return instance;
    private void initComponents() {
    JButton OK = new JButton ("OK");
    OK.addActionListener (
    new ActionListener () {
    public void actionPerformed (ActionEvent e) {
    player.close ();
    instance = null;
    dispose();
    getContentPane ().add (OK, BorderLayout.NORTH);
    setSize (300, 300);
    show ();
    createPlayer ();
    /** Creates new form PlayClip */
    private void createPlayer () {
    if (file == null) {
    return;
    removePreviousPlayer ();
    try {
    //create a new player and add listener
    player = Manager.createPlayer (file.toURL () );
    player.addControllerListener (new EventHandler () );
    player.start (); //start player
    catch (Exception e) {
    JOptionPane.showMessageDialog (this, "Invalid file or location", "Error loading file", JOptionPane.ERROR_MESSAGE );
    System.exit (1);
    private void removePreviousPlayer () {
    if (player == null )
    return;
    player.close ();
    Component visual = player.getVisualComponent ();
    Component control = player.getControlPanelComponent ();
    Container c = getContentPane ();
    if (visual != null)
    c.remove (visual);
    if (control !=null)
    c.remove (control);
    private class EventHandler implements ControllerListener {
    public void controllerUpdate (ControllerEvent e) {
    if (e instanceof RealizeCompleteEvent ) {
    Container c = getContentPane ();
    Component visualComponent = player.getVisualComponent ();
    if (visualComponent != null)
    c.add (visualComponent, BorderLayout.CENTER);
    Component controlsComponent = player.getControlPanelComponent ();
    if (controlsComponent != null)
    c.add (controlsComponent, BorderLayout.SOUTH);
    c.doLayout ();
    }

    JDunlop,
    thanks for your quick reply to my java.sun.com forum posting! i just got back from vacation, so i didn't get a chance to try your method til now. i pulled your email address off the website to update you on my problem playing an avi file in JMStudio (JMF).
    as per your instructions, i downloaded the divx player at www.divx.com and tried to play the avi file. this is the error the divx player gives:
    Divx Player 2.1
    The file contains unknown video data
    The file contains the following type of data:
    Video data: FOURCC code "MP42"
    You may need to install a new video codec on your computer to watch this video
    Some quick questions:
    1. Where could I find the "MP42" codec to play my avi file in JMStudio (JMF)? Does java.sun.com have video codecs?
    2. You mentioned in your posting "If you don't have the one that was used in the encoding, your out of luck." Does this mean that I need to know how the avi file was originally coded and have the original codec to decode (play) it?
    Thanks,
    lac410
    P.S. If you need more Duke Dollars for your help, I'd be happy to award them to you.
    Re: Please help: Why JMF does't play .avi video clip?
    Author: JDunlop Jun 5, 2003 5:00 AM
    sounds to me like you are missing a video codecs. If you don't have the one that was used in the encoding, your out of luck. Download the player from divx.com, it will tell you which codecs the video needs (if it won't play). You can then search the net for that particular codecs.

  • Please Help me, How to cut image ?

    I have a image (jpg file). The image is animal, and the image contain 2 basic colours (white is background, black describe animal). I want to cut background around animal
    Please Help me ???
    Please source code .??? Example??

    well it depends what you want to do with this- do you just want to use the black part without a whit contour?
    however if you want to have 2 colors PLEASE save as GIF or as PNG and not as JPG - JPG tends to blur the image a little so your mask will get screwed up with JPG
    the easiest way for me is to do this job in photoshop and save as Tiff then load it with Javax.ImageIO so transparency is kept

  • Urgent, please help. why the ListSelectionListener() called twice?

    I had two JList, and every time, I click value in list1, it will call the ListSelectionListener() twice, and when I click on value in List2, it called the list2 actionListener twice also, I don't know why?
    Please help.
    The part of the code list below:
    jList1 = new JList(words1);
    JScrollPane scrollPane1 = new JScrollPane(jList1); jList1.setBackground(Color.lightGray);
    jList1.setBorder(BorderFactory.createLoweredBevelBorder());
    jList1.addListSelectionListener(new javax.swing.event.ListSelectionListener() {
    public void valueChanged(ListSelectionEvent e) {
         jList1_valueChanged(e){
    /* add Column_Name to the jList2*/
    JScrollPane scrollPane2 = new JScrollPane(jList2);
    jList2.setBackground(Color.lightGray);
    jList2.setBorder(BorderFactory.createLoweredBevelBorder());
    jList2.addListSelectionListener(new javax.swing.event.ListSelectionListener() {
    public void valueChanged(ListSelectionEvent e) {
    jList2_valueChanged(e);
    void jList1_valueChanged(ListSelectionEvent evt)
    void jList2_valueChanged(ListSelectionEvent evt)
    {     }

    You can call ListSelectionEvent.getValueIsChanging() to find out if the selection is in progress or if has been finished. You will get an event both when the user starts the selection (presses the button) and when he/she finishes it (lets go of the betton).
    /Michael

  • Please help why doesn't command s single user work?

    Why doen't my mac command s single users mode not work?? i forgot my admins password and i broke the disc like 3 months ago so im left with no choise
    please help asap

    Single user or verbose mode is for troubleshooting, not changing the admin password.
    According to your profile you are runing Lion so an alternative may work for you.
    OS X Lion: Apple ID can be used to reset your user account password
    Or here >  Reset a Mac OS X 10.7 Lion Password

  • Please help!!  No "still image" button option...  There last night - now GONE.  ?!?!

    Hello!
    Thank you in advance for anyone/everyone who answers this questions.  I need your help!
    (The most frustrating thing about this - is that it was working easily and perfectly last night with not even a hiccup.  argh.
    So:
    I am putting two movies in one iDVD project and then I'm going to burn on a DL DVD.
    The first movie is in and all of the Chapter Markers imported beautifully with the titles, etc..., BUT....last night I was able to select the Motion Button - Change it to a STILL IMAGE and then drop in my own Still Image.  It was looking great!
    Today, I can't.
    I select the Motion Button and the only "Button Info" Menu it gives me is one that has Font control, Size control, Label, and Transitions.  NO "Still Image" box to check...no box to click and drag my image into - nothing.  argh again!
    On the map page, if I select the "chapter/scene selection" - all it say is "Loop Movie" and gives me a box to check or uncheck.
    Help!  Help!  Help!
    I feel like I'm losing my mind.  I've gone thru and checked to see if there's anything I could've changed, but can't think of anything.
    Of course, I'm on a tight deadline, so please help.
    Thank you!  Thank you!!
    Jocelyn

    I figured it out!!!
    It seems to be a glitch in the "Center Stage" theme.
    I switched to the Revolution Theme, made all of my adjustments, then switched back to Center Stage and it worked!!
    Hilarious, too, because I've been looking for an answer for a couple of hours and right when I sat down at the computer again to try my "plan" - the NEXT post I opened - confirmed it for me!  Woooohoooo!

  • Please help - why won't my Ipod songs transfer into new Itunes?

    I have a new Macbook, and want to move all the songs from my Ipod into my Itunes library on this computer. Nothing works. Can someone please help?
    Please note - currently my library is on my crappy HP. But I did read that you can transfer all songs from the Ipod alone (including those not purchased from Itunes).
    macbook   Mac OS X (10.4.8)  
    mac book   Mac OS X (10.4.8)  

    I use an application called Senuti. That transfers all content from your iPod to your Mac, including non purchased content. It's free and easy to use. With your iPod connected to your Mac, launch Senuti and the rest is pretty simple. I would suggest you create a folder on your desktop and set your destination to that folder in the Senuti preferences. Also, it's a good idea to keep everything organized by checking the artist and album boxes in the preferences as well. Like I said, it's pretty easy. Good luck.
    http://fadingred.org/senuti/

  • Please help with transparancy fade.

    Hello, I have a script that I am using but cannot figure out how to make the bottom reflection fade to transparancy. The image on the left is what comes out from the script & the image on the right shows how I want the reflection to fade into transparancy.
    Any and all help would be greatly appreciated.
    Thanks!
    P.S. I'm a Photoshop n00b so please try to be simple in the instructions.
    EDIT: I forgot to mention that the image needs to remain at it's original 60px × 224px, the fade to transparency cannot change the image size.

    I would forget the script.  Since you have little PS experience here is a simple way that might work for you.
    Take image and click on marque tool and make a selection from the guy's foot to bottom of picture.  You will have a dotted line that marches like ants.
    Next click on gradient tool, or toggle it from paint bucket tool.  In upper left corner click on 2nd box's down arrow to open gradient picker.  Choose second one that says "Forground to transparency". 
    Choose white as forground color.
    Take your cursor and drag it from top of box to bottom.  You should fade from white to transparency.  Vary opacity for effect you want.
    Work on a copy of original, or at least use "save as"  after the above steps, and enter new name so original is preserved and can be recalled if you don't like result.

  • Please help, why do i keep getting the white screen of death?

    ok i have a blackberry curve mobile, i dropped it in a pint of lager new years eve. i have left it to dry for months. first time i turned it on i was getting the white screen and it kept happning. so i tried updating the software and it worked fine for about 3 minutes. so i just left phone for a couple of weeks tried updating software again. last night it stayed on without turning off or having the white screen, but i get up in the morning to check my phone click it then the white screen appears again. making me very angry, because the white screen doesnt come on if i have my phone connected to USB to pc it stays on. anyone know why this is happning?

    Hi and Welcome to the Community!
    With moisture intrusion into a BB, the only thing that is predictable is that the results will be unpredictable. All of your symptoms could be perfectly understandable given the lager-bath your BB received. I'd recommend a new device ASAP (and get regular backups of your data, of course).
    Good luck!
    Occam's Razor nearly always applies when troubleshooting technology issues!
    If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
    Join our BBM Channels
    BSCF General Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

  • Please help me how to view images using IIS

    I have oracle 9i,running on win2000 server,and I have installed vb 6.0 on the same system as oracle running.
    I want to use Ask I am running a demo which is given in
    Oracle_home\ora90\oo4o\IIS\SAMPLES\ASP\ComputerOrderEntry
    folder.I created the Virtual Dir as directed in the readme filewhich says I need to open QueryPage.asp in my browser,when I do that it's not running but it's shows me the file which opens asp file in notepad.I want to ask why this happening?Is I have done something wrong or ..... ???? please let me know
    the cause in detail.
    warm regards : Alok Kumar

    I am not using ASP. You need to find out how to access your ASP web server. What is the home page? How do you invoke any ASP page. When you can open a simple HelloWorld.asp script, you will know how to open the ASP through the MS web server.
    Larry

  • PLease, Help: Compressor 4 not recognize image sequence (Tiff or Jpg) for create a video.

    Dragging or open it from menu, Compressor not recognize image sequence. In the menu doesn´t appear anything.
    THe only way I Found ti was take all the image sequences in Final Cut X, changing duration for one frame, and exporting to compressor for create Pro Res.
    This image are from RAW fotograms and I exported from photoshop.
    I need to use compressor because I have to convert thousands of frames.
    (It´s incredible and sad, how Da Vinci Resolve is working better andgetting people from Final Cut... I love Apple).
    Any help?

    mollo wrote:
    Dragging or open it from menu, Compressor not recognize image sequence. In the menu doesn´t appear anything.
    By menu, you mean you tried to add the image sequence to a batch lby clicking on the plus sign icon and it didn't give you a browsing window, or what…?
    Russ

  • PLEASE HELP ME to put an image over a background image !!

    Hello,
    I need help on my AWT program. I have a map being displayed, and would like an image of a car (car.gif) to be displayed over the image of the map.
    So my question is: How do I make this map a background image, and put the picture of the car right over it. I need my map loaded all the time, and the picture of the car will be reloaded many times over the same map, so a class method to load this map would be perfect. Any help, code, or suggestions would be great. Thanks so much!
    Here is what I currently have for my map.
    import java.awt.*;
    import java.awt.event.*;
    public class MyImage extends Panel {
        private Image im = null;
        Graphics g;
        public void getMap(){
          im = Toolkit.getDefaultToolkit().getImage("C:\\test_map.gif");
             MediaTracker tracker = new MediaTracker(this);
             tracker.addImage(im,0);
             try {
                 tracker.waitForID(0);
             }catch (InterruptedException e){}
                 repaint();
       public void paint(Graphics g){
            this.g = g;
             if (im != null)     {
                g.drawImage(im,0,0,this.getWidth(),this.getHeight(),this);  //706,397
        }

    Look at this sample, the car will start when the button will be pressed, and stop on the next press.
    import java.awt.event.*;
    import java.awt.*;
    public class UsaTrip extends Frame 
         mapPanel map   = new mapPanel();
         Button   move  = new Button("Move");
         TheMover mover = null;
    public UsaTrip()
         addWindowListener(new WindowAdapter()
        {     public void windowClosing(WindowEvent ev)
              {     dispose();
                   System.exit(0);}});
         setBounds(10,10,500,400);
         setLayout(new BorderLayout());
         add(map,BorderLayout.CENTER);
         add(move,BorderLayout.SOUTH);
         move.addActionListener(new ActionListener()
         {     public void actionPerformed( ActionEvent e )
                   if (mover == null)
                        mover = new TheMover(map);     
                        move.setLabel("Stop");          
                   else
                        mover.end();
                        mover = null;     
                        move.setLabel("Move");          
         setVisible(true);
    public class TheMover extends Thread
         mapPanel map;
         boolean  go   = true;
         int      spin = 0;
    public TheMover(mapPanel m)
         map = m;
         start();
    public void end()
         go        = false;
    public synchronized void run()
         while (go)
              map.moveCar();
              try     {sleep(100);}
              catch(InterruptedException i){}
    public class mapPanel extends Panel
         Image map;
         Image car;
         int   x=10,y=30;   
    public mapPanel()
         map = getToolkit().getImage("usa.gif");
         car = getToolkit().getImage("home24.gif");
         MediaTracker tracker = new MediaTracker(this);
         tracker.addImage(map,0);
         tracker.addImage(car,0);
         try   {tracker.waitForID(0);}
         catch (InterruptedException e){}
    public void moveCar()
         repaint(x,y,25,25);
         x++;
         repaint(x,y,25,25);
    public void update(Graphics g)
         paint(g);
    public void paint(Graphics g)
         Rectangle r = g.getClipBounds();
         g.drawImage(map,r.x,r.y,r.x+r.width,r.y+r.height,
                              r.x,r.y,r.x+r.width,r.y+r.height,this);
         g.drawImage(car,x,y,this);
    public static void main(String[] args )
         new UsaTrip();
    Noah
    import java.awt.event.*;
    import java.awt.*;
    public class UsaTrip extends Frame
         mapPanel map = new mapPanel();
         Button move = new Button("Move");
         TheMover mover = null;
    public UsaTrip()
         addWindowListener(new WindowAdapter()
    {     public void windowClosing(WindowEvent ev)
              {     dispose();
                   System.exit(0);}});
         setBounds(10,10,500,400);
         setLayout(new BorderLayout());
         add(map,BorderLayout.CENTER);
         add(move,BorderLayout.SOUTH);
         move.addActionListener(new ActionListener()
         {     public void actionPerformed( ActionEvent e )
                   if (mover == null)
                        mover = new TheMover(map);     
                        move.setLabel("Stop");          
                   else
                        mover.end();
                        mover = null;     
                        move.setLabel("Move");          
         setVisible(true);
    public class TheMover extends Thread
         mapPanel map;
         boolean go = true;
         int spin = 0;
    public TheMover(mapPanel m)
         map = m;
         start();
    public void end()
         go = false;
    public synchronized void run()
         while (go)
              map.moveCar();
              try     {sleep(100);}
              catch(InterruptedException i){}
    public class mapPanel extends Panel
         Image map;
         Image car;
         int x=10,y=30;
    public mapPanel()
         map = getToolkit().getImage("usa.gif");
         car = getToolkit().getImage("home24.gif");
         MediaTracker tracker = new MediaTracker(this);
         tracker.addImage(map,0);
         tracker.addImage(car,0);
         try {tracker.waitForID(0);}
         catch (InterruptedException e){}
    public void moveCar()
         repaint(x,y,25,25);
         x++;
         repaint(x,y,25,25);
    public void update(Graphics g)
         paint(g);
    public void paint(Graphics g)
         Rectangle r = g.getClipBounds();
         g.drawImage(map,r.x,r.y,r.x+r.width,r.y+r.height,
                   r.x,r.y,r.x+r.width,r.y+r.height,this);
         g.drawImage(car,x,y,this);
    public static void main(String[] args )
         new UsaTrip();

  • *Class Project - Please help:  Why does my movie clip keep playing over and over?

    I am desperate for help on this one as its my Final Flash
    class project and I just can't get my scenes/movie clips to play in
    the order I want them to.
    I have Scene 1 (movie clip 1) that plays and then Scene 2
    (movie clip 2) plays. The problem is that Scene 2 (or movie clip 2)
    repeats itself over and over again. I can't get it to go back to
    Scene 1 (movie clip 1) to play that again.
    I want it go to to this Scene 1 and actually start at a
    certain frame to continue on with the story.
    I have named my movie clip instances.
    What am I doing wrong? I went into movie clip 2, into
    actions, and movie clip control, and I don't really see a way to
    tell it to go back and play movie clip 1. Trying to see how to
    refer back to the instance name of the movie clip and get it to
    play.
    Ideas? Please please? I would be forever greatful.
    Angie

    quote:
    Originally posted by:
    computerkitten
    I wonder if I should just take that movie clip out of the
    scene completely.... and not have the second scene at all. Maybe I
    should just have 1 scene and these 2 movie clips. Wonder if that
    would work better?
    As Nickels55 said, above, scenes add unnecessary complexity.
    So the answer to this is: YES. Scenes are awkward in Flash. Never
    use them in any final project. Put everything on a single timeline
    in a single scene, and you will have much better control of the
    project.

  • Please Help - why are pics not in focus and sharp?

    I have a 24-70mm f/2.8L lens and am finding that it is not as sharp as i'd expect.  I'm sure it's me and not the lens so hoping someone can help me understand what i'm doing or not doing correctly.
    I'm attaching a picture as an example...hand held...here are the settings:
    EF24-70mm f/2.8L II USM
    59.0mm
    1/640 sec;   f/2.8;   ISO 400
    Shutter priority;   Spot metering
    shot with 70D
    when you zoom into the tree it is cleary not in focus/sharp ;(
    I've tried at differen shutter speeds but still having the same issue... going to try different apertures next...
    Body: Canon 6D, Canon T1i, Canon Elan II,
    Glass: Canon 24-70mm f/2.8L II USM, Canon 18-55 kit lens, Sigma 70-300mm f4-5.6, Canon 50mm f/1.8,
    Flash: Canon Speedlite 430ex ii

    next considered a pic with text to really see what's up cropped image to post... this was taken 10feet away from the text - text is on a piece of paper that is 4x4... outside since that is the best light right now - overcast and about an hour before sun set.... shot in M, set the shutter speed an aperture, and use Auto for ISO.  I usually only shoot in Tv or Av so maybe this wasn't a good test for how i use it but wanted to see what would happen...
    settings:
    EF24-70mm f/2.8L II USM
    67.0 mm
    1/200 sec;   f/2.8;   ISO 250
    anual;   Spot metering
    center AF
    Body: Canon 6D, Canon T1i, Canon Elan II,
    Glass: Canon 24-70mm f/2.8L II USM, Canon 18-55 kit lens, Sigma 70-300mm f4-5.6, Canon 50mm f/1.8,
    Flash: Canon Speedlite 430ex ii

  • Please help beginner with CSS background-image

    I'm using Dreamweaver CS4. I set up a local site  on my computer. D:Data\Local_sites\Gravity_Works. Under this directory using Dreamweaver I created 3 folders -  css, images and Templates. In the images folder I have an image -  bg_body_winter.jpg. In the Templates folder I have Gravity-Works-Home01.dwt . I created a new page form the template file and named it index-test01.html and saved it directly in the Gravity_Works folder
    I have this css code in a linked css file in the css folder :
    body {
        background: url(/images/bg_body_winter.jpg) no-repeat scroll center top #C1CAD6;
    body  {
        font: 100% Verdana, Arial, Helvetica, sans-serif;
        margin: 0;
    I uploaded the site to a test folder on my server at fatcow.com. You can see the page using the link below.
    http://www.openrangeimaging.com/Test/Gravity-Test/index-test01.html
    The image appears as it should in Dreamweaver Live View. It does not appear in Design view. It also does not appear when previewing the local file in a browser. The image does not appear when looking at the index-test01.html file thats on the server using the link above. The background-color I specified shows up but not the image.
    I'm confused about how I should name the path to the image. I beleive  it should be site root relative so that no matter where I upload the site,  the image can be found. Can anyone tell me how I should name the path to the image correctly.
    I feel like I should know how to do this and have searched around in the online help and the tutorial books I have but I'm just not getting it.
    TIA for any help.

    body {
        background: url(/images/bg_body_winter.jpg) no-repeat scroll center top #C1CAD6;
    Using a site root relative path, means the server will look for the images folder at
    http://www.openrangeimaging.com/images
    Try using a doc relative path while you're testing (remove the leading / from the path).

Maybe you are looking for