Skip to content

CameraFinder Class#

The camera finder can be used to query information about camera devices connected to the system.

Inheritance Hierarchy#

System.Object
  Basler.Pylon.CameraFinder

Syntax#

C#

public static class CameraFinder

VB

Public NotInheritable Class CameraFinder

The CameraFinder type exposes the following members.

Methods#

NameDescription
Public methodStatic memberEnumerate() Retrieves information about cameras connected to the system.
Public methodStatic memberEnumerate(String) Retrieves information about cameras of a specific type connected to the system.
Public methodStatic memberGetDeviceAccessibilityInfo Returns information about the accessibility of a camera device.
 

CameraFinder.Enumerate Method#

Retrieves information about cameras connected to the system.

Syntax#

C#

public static List<ICameraInfo> Enumerate()

VB

Public Shared Function Enumerate As List(Of ICameraInfo)

Return Value#

Type: List(ICameraInfo)
Returns a list of ICameraInfo objects, one for each camera found. The list is ordered by device type and serial number. Device type order: USB, GigE, Camera Link, other device types ordered by using the < operator, Camera Emulation

Remarks#

The function queries for camera devices connected to the system and returns a list of ICameraInfo objects describing the cameras. The returned information can be used to create a specific Camera object.

Thread Safety: This method is thread-safe.

Error Safety: Can throw exceptions.

CameraFinder.Enumerate Method (String)#

Retrieves information about cameras of a specific type connected to the system.

Syntax#

C#

public static List<ICameraInfo> Enumerate(
    string deviceType
)

VB

Public Shared Function Enumerate ( 
    deviceType As String
) As List(Of ICameraInfo)

Parameters#

 

deviceType
Type: System.String
The name of the device type to enumerate connected devices. The static class DeviceType can be used to get a list of valid device class names.

Return Value#

Type: List(ICameraInfo)
Returns a list of ICameraInfo objects, one per camera found. The list is ordered by serial number

Remarks#

The function queries for camera devices of a specific device class connected to the system and returns a list of ICameraInfo objects describing the cameras. The returned information can be used to create a specific Camera object. The static class DeviceType can be used to get a list of valid device type names.

Thread Safety: This method is thread-safe.

Error Safety: Can throw exceptions.

CameraFinder.GetDeviceAccessibilityInfo Method#

Returns information about the accessibility of a camera device.

Syntax#

C#

public static DeviceAccessibilityInfo GetDeviceAccessibilityInfo(
    ICameraInfo cameraInfo
)

VB

Public Shared Function GetDeviceAccessibilityInfo ( 
    cameraInfo As ICameraInfo
) As DeviceAccessibilityInfo

Parameters#

 

cameraInfo
Type: Basler.Pylon.ICameraInfo
An ICameraInfo object specifying the camera device of which the state is returned. The Enumerate() methods can be used to retrieve ICameraInfo objects.

Return Value#

Type: DeviceAccessibilityInfo
Returns a DeviceAccessibilityInfo value for the camera device.

Remarks#

This function can be used to check if a camera device is currently reachable. This can be used to prevent errors when opening a camera.

Note Note
Some cameras do not support this feature and may return DeviceAccessibilityInfo.Unknown.
  Thread Safety: This method is thread-safe.

Error Safety: Can throw exceptions.

CameraFinder.Enumerate Method#

Overload List#

NameDescription
Public methodStatic memberEnumerate() Retrieves information about cameras connected to the system.
Public methodStatic memberEnumerate(String) Retrieves information about cameras of a specific type connected to the system.