Today you are going to learn how to conversion progress in VB.NET. Conversion progress in VB.NET can be implemented with ByteScout Image To Video SDK. ByteScout Image To Video SDK is the SDK that is designed to generate video slideshow with 100+ 2d and 3D transition effects. Can generate WMV, AVI, WEBM video file with adjustable quality, framerate, output video size.
Fast application programming interfaces of ByteScout Image To Video SDK for VB.NET plus the instruction and the VB.NET code below will help you quickly learn conversion progress. Follow the instruction from the scratch to work and copy and paste code for VB.NET into your editor. Enhanced documentation and tutorials are available along with installed ByteScout Image To Video SDK if you’d like to dive deeper into the topic and the details of the API.
Trial version can be downloaded from our website. Source code samples for VB.NET and documentation are included.
On-demand (REST Web API) version:
Web API (on-demand version)
On-premise offline SDK for Windows:
60 Day Free Trial (on-premise)
Imports System.Diagnostics
Imports System.Threading
Imports BytescoutImageToVideo
Class Program
Friend Shared Sub Main(ByVal args As String())
Console.WriteLine("Converting JPG slides to video, please wait...")
' Create BytescoutImageToVideoLib.ImageToVideo object instance
Dim converter As New ImageToVideo()
' Activate the component
converter.RegistrationName = "demo"
converter.RegistrationKey = "demo"
' set default "in" effect for slides (you can also set effects for each single slide)
converter.Slides.DefaultSlideInEffect = 1 ' teFadeIn (1) - fades in effect for slides transition
converter.Slides.DefaultSlideInEffectDuration = 500 ' 500 msec for in effect
' Add images and set the duration for every slide
Dim slide As Slide
slide = converter.AddImageFromFileName("..\..\..\..\slide1.jpg")
slide.Duration = 3000 ' 3000ms = 3s
slide = converter.AddImageFromFileName("..\..\..\..\slide2.jpg")
slide.Duration = 3000
slide = converter.AddImageFromFileName("..\..\..\..\slide3.jpg")
slide.Duration = 3000
' Set output video size
converter.OutputWidth = 640
converter.OutputHeight = 480
' Set output video file name
converter.OutputVideoFileName = "result.wmv"
Console.WriteLine("Conversion started. Hit a key to abort...")
' Run the conversion
converter.Run()
' Show conversion progress:
Dim i As Integer = 0
Dim spin As Char() = New Char() {"|"c, "/"c, "-"c, "\"c}
While Not Console.KeyAvailable AndAlso converter.IsRunning
Dim progress As Single = converter.ConversionProgress
Console.WriteLine([String].Format("Converting images {0}% {1}", progress, spin(i)))
Console.CursorTop -= 1
i = i + 1
i = i Mod 4
Thread.Sleep(50)
End While
If converter.IsRunning Then
converter.Stop()
Console.WriteLine("Conversion aborted by user.")
Else
Console.WriteLine("Conversion competed successfully.")
End If
' Release resources
System.Runtime.InteropServices.Marshal.ReleaseComObject(converter)
' Open the result video file in default media player
Process.Start("result.wmv")
Console.WriteLine()
Console.WriteLine(vbLf & "Press any key to exit...")
Console.ReadKey()
End Sub
End Class
60 Day Free Trial or Visit ByteScout Image To Video SDK Home Page
Explore ByteScout Image To Video SDK Documentation
Explore Samples
Sign Up for ByteScout Image To Video SDK Online Training
Get Your API Key
Explore Web API Docs
Explore Web API Samples
60 Day Free Trial or Visit ByteScout Image To Video SDK Home Page
Explore ByteScout Image To Video SDK Documentation
Explore Samples
Sign Up for ByteScout Image To Video SDK Online Training
Get Your API Key
Explore Web API Docs
Explore Web API Samples