Doesn't Auto-Play Audio Duration Take into Account when Creating Images for Movies?

I’m trying to use the latest Aspose.Slides video creation below.

I am happy to have this feature. appreciate.

If you create a frame image according to the sample source code,
The image will be about 2 seconds per slide.

・Animation of transitions between slides
・shape animation
・Text animation

And if the above shapes and settings are included, I think it will be the number of seconds that matches the animation, but won’t the time for the embedded sound that is set to automatically play on the above target be considered?

  • Auto-play settings for embedded sounds

When you actually start the slide show, it will move to the next slide after the above embedded sound time has elapsed.
I would appreciate it if you could respond during this time, but is it technically difficult?

Best regard.

image.png (6.2 KB)

Embedded audio with auto-play settings is also displayed in the animation window, so I guess there is a setting for the time itself somewhere, but what about that?

@Greeeeen,
Could you please share a sample presentation, and your output video file, and indicate the issues you encountered after the conversion?

sample.7z (3.7 MB)

I have attached the zip.

  • PPT files
  • Video file exported from office PPT file to video
  • Image & video folder
    –> Image sequence
    –> Movie file created from serial numbered images

is included.

The source and ffmpeg command will be posted at the end.

First open the PPT file and watch the animation window.
There are 4 pages, and you can see that each page from 2 to 4 has embedded audio that automatically starts during the slide show.
And on page 3, you’ll see that the text animation is combined after the audio finishes playing.

If you make this slide into a video with Office genuine PowerPoint, of course, the audio time will be secured and it will start to flow (attached)
You shouldn’t be able to move on to the next slide until each audio has finished playing.
On page 3, the text animation starts after the audio ends.

Process the target PPT file as the source.
Then, image files as in the attached file are created with serial numbers.
Then, use ffmpeg to convert this sequence of images into a video file. (This video is also attached)

Looking at this, it seems that the number of seconds of the audio playback part is ignored and only the time of the text animation on the 3rd page is reflected.

Is it not possible to reflect the time of the audio displayed in the animation window?

・Source code

var FPS = 30;
var dir = Path.Combine(Path.GetDirectoryName(pptPath), "png");

using (var ppt = new Presentation(pptPath))
{
    using (var animationsGenerator = new PresentationAnimationsGenerator(ppt))
    using (var player = new PresentationPlayer(animationsGenerator, FPS))
    {
        player.FrameTick += (sender, args) =>
        {
            args.GetFrame().Save(Path.Combine(dir, $"frame_{sender.FrameIndex}.png"));
        };

        animationsGenerator.Run(ppt.Slides);
    }
}

・ffmpeg command

ffmpeg -r 30 -i C:\test\png\frame_%d.png -vcodec libx264 -pix_fmt yuv420p -r 60 C:\test\png\out.mp4

Best regard.

@Greeeeen,
Thank you for describing the details. I’ve added a ticket with ID SLIDESNET-43627 to our issue-tracking system. Our development team will investigate the case and look into your questions. We will inform you of any progress.

1 Like