Class SOFTReopenDevice

java.lang.Object
org.lwjgl.openal.SOFTReopenDevice

public class SOFTReopenDevice extends Object
Native bindings to the SOFT_reopen_device extension.

This extension provides a mechanism for applications to move the output of a device from one endpoint to another. Standard OpenAL devices are associated with an output on the system upon being opened, but if the endpoint should no longer be the desired output, there is no method for the application to easily change it. The only option for the application is to delete all AL objects, destroy the context, close the device handle, open a new device, and reload/recreate the necessary resources. A method to more simply move the device with its existing resources to a different output is easier, requiring less management from the application.

  • Method Details

    • nalcReopenDeviceSOFT

      public static boolean nalcReopenDeviceSOFT(long device, long deviceName, long attribs)
      Unsafe version of: ReopenDeviceSOFT
    • alcReopenDeviceSOFT

      public static boolean alcReopenDeviceSOFT(long device, @Nullable ByteBuffer deviceName, @Nullable IntBuffer attribs)
      Once a playback device is opened, it becomes associated with a particular output endpoint. When this output is no longer the desired output, the playback device can be reopened to re-associate it with a potentially different output endpoint using alcReopenDeviceSOFT.
      Parameters:
      device - a non-NULL handle for an existing device
      deviceName - the device name to open, or NULL for the default (same as would be passed to OpenDevice)
      attribs - an attribute list to configure the device with, with the same attribute list that would be passed to CreateContext.
    • alcReopenDeviceSOFT

      public static boolean alcReopenDeviceSOFT(long device, @Nullable CharSequence deviceName, @Nullable IntBuffer attribs)
      Once a playback device is opened, it becomes associated with a particular output endpoint. When this output is no longer the desired output, the playback device can be reopened to re-associate it with a potentially different output endpoint using alcReopenDeviceSOFT.
      Parameters:
      device - a non-NULL handle for an existing device
      deviceName - the device name to open, or NULL for the default (same as would be passed to OpenDevice)
      attribs - an attribute list to configure the device with, with the same attribute list that would be passed to CreateContext.
    • alcReopenDeviceSOFT

      public static boolean alcReopenDeviceSOFT(long device, @Nullable ByteBuffer deviceName, @Nullable int[] attribs)
      Array version of: ReopenDeviceSOFT
    • alcReopenDeviceSOFT

      public static boolean alcReopenDeviceSOFT(long device, @Nullable CharSequence deviceName, @Nullable int[] attribs)
      Array version of: ReopenDeviceSOFT