Actually, in my small swing program I need to simultaneously display the gif and play the sound. At this stage, I first play a melody, after which my jdialog c jlabel appears, in which gif is depicted. I tried to create a separate stream for output gif, but experience is not enough. Who faced such a problem?