VintaSoft Imaging .NET SDK 15.1: Documentation for .NET developer
Vintasoft.Imaging.Media Namespace / ImageCaptureDeviceConfiguration Class
Members Object Syntax Example Hierarchy Requirements SeeAlso
In This Topic
ImageCaptureDeviceConfiguration Class
In This Topic
Obtains information about image capture devices, which are available in the system.
Object Model
ImageCaptureDeviceConfiguration
Syntax
'Declaration

Public MustInherit NotInheritable Class ImageCaptureDeviceConfiguration

public static class ImageCaptureDeviceConfiguration

Example

This C#/VB.NET code shows how to show information about available image capture devices:


Class ImageCaptureDeviceConfiguration_Example
    Public Shared Sub Test()
        System.Console.WriteLine(GetInformation())
    End Sub

    Public Shared Function GetInformation() As String
        Dim sb As New System.Text.StringBuilder()

        ' gets available capture devices
        Dim availableDevices As System.Collections.ObjectModel.ReadOnlyCollection(Of Vintasoft.Imaging.Media.ImageCaptureDevice) = Vintasoft.Imaging.Media.ImageCaptureDeviceConfiguration.GetCaptureDevices()

        For Each device As Vintasoft.Imaging.Media.ImageCaptureDevice In availableDevices
            ' FriendlyName
            sb.AppendLine(String.Format("{0}, supported formats:", device.FriendlyName))
            ' SupportedFormats
            For Each format As Vintasoft.Imaging.Media.ImageCaptureFormat In device.SupportedFormats
                sb.AppendLine(format.ToString())
            Next
            sb.AppendLine()
        Next

        Return sb.ToString()
    End Function
End Class


class ImageCaptureDeviceConfiguration_Example
{
    public static void Test()
    {
        System.Console.WriteLine(GetInformation());
    }

    public static string GetInformation()
    {
        System.Text.StringBuilder sb = new System.Text.StringBuilder();

        // gets available capture devices
        System.Collections.ObjectModel.ReadOnlyCollection<Vintasoft.Imaging.Media.ImageCaptureDevice> availableDevices = 
            Vintasoft.Imaging.Media.ImageCaptureDeviceConfiguration.GetCaptureDevices();

        foreach (Vintasoft.Imaging.Media.ImageCaptureDevice device in availableDevices)
        {
            // FriendlyName
            sb.AppendLine(string.Format("{0}, supported formats:", device.FriendlyName));
            // SupportedFormats
            foreach (Vintasoft.Imaging.Media.ImageCaptureFormat format in device.SupportedFormats)
                sb.AppendLine(format.ToString());
            sb.AppendLine();
        }

        return sb.ToString();
    }
}

Inheritance Hierarchy

System.Object
   Vintasoft.Imaging.Media.ImageCaptureDeviceConfiguration

Requirements

Target Platforms: .NET 10; .NET 9; .NET 8; .NET 7; .NET 6; .NET Framework 4.8, 4.7, 4.6, 4.5, 4.0, 3.5

See Also