Class OpenProjector.Builder
- java.lang.Object
-
- nl.harm27.obs.websocket.api.base.BaseBuilder
-
- nl.harm27.obs.websocket.api.requests.general.OpenProjector.Builder
-
- Enclosing class:
- OpenProjector
public static class OpenProjector.Builder extends BaseBuilder
-
-
Constructor Summary
Constructors Constructor Description Builder(BiConsumer<BaseRequest,Consumer<BaseResponse>> requestConsumer, Consumer<BaseRequest> batchConsumer, Supplier<String> messageIdSupplier)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OpenProjector.Request
batchMessage()
Batch the message to the OBS Studio instance.Optional<String>
getGeometry()
Size and position of the projector window (only if monitor is -1).Optional<Integer>
getMonitor()
Monitor to open the projector on.Optional<String>
getName()
Name of the source or scene to be displayed (ignored for other projector types).Optional<ProjectorType>
getType()
Type of projector: `Preview` (default), `Source`, `Scene`, `StudioProgram`, or `Multiview` (case insensitive).void
sendMessage(Consumer<OpenProjector.Response> consumer)
Send the message to the OBS Studio instance.void
setGeometry(String geometry)
Size and position of the projector window (only if monitor is -1).void
setMonitor(int monitor)
Monitor to open the projector on.void
setName(String name)
Name of the source or scene to be displayed (ignored for other projector types).void
setType(ProjectorType type)
Type of projector: `Preview` (default), `Source`, `Scene`, `StudioProgram`, or `Multiview` (case insensitive).-
Methods inherited from class nl.harm27.obs.websocket.api.base.BaseBuilder
batchMessage, getNewMessageId, sendMessage
-
-
-
-
Constructor Detail
-
Builder
public Builder(BiConsumer<BaseRequest,Consumer<BaseResponse>> requestConsumer, Consumer<BaseRequest> batchConsumer, Supplier<String> messageIdSupplier)
-
-
Method Detail
-
getType
public Optional<ProjectorType> getType()
Type of projector: `Preview` (default), `Source`, `Scene`, `StudioProgram`, or `Multiview` (case insensitive).
-
setType
public void setType(ProjectorType type)
Type of projector: `Preview` (default), `Source`, `Scene`, `StudioProgram`, or `Multiview` (case insensitive).
-
getMonitor
public Optional<Integer> getMonitor()
Monitor to open the projector on. If -1 or omitted, opens a window.
-
setMonitor
public void setMonitor(int monitor)
Monitor to open the projector on. If -1 or omitted, opens a window.
-
getGeometry
public Optional<String> getGeometry()
Size and position of the projector window (only if monitor is -1). Encoded in Base64 using [Qt's geometry encoding](https://doc.qt.io/qt-5/qwidget.html#saveGeometry). Corresponds to OBS's saved projectors.
-
setGeometry
public void setGeometry(String geometry)
Size and position of the projector window (only if monitor is -1). Encoded in Base64 using [Qt's geometry encoding](https://doc.qt.io/qt-5/qwidget.html#saveGeometry). Corresponds to OBS's saved projectors.
-
getName
public Optional<String> getName()
Name of the source or scene to be displayed (ignored for other projector types).
-
setName
public void setName(String name)
Name of the source or scene to be displayed (ignored for other projector types).
-
sendMessage
public void sendMessage(Consumer<OpenProjector.Response> consumer)
Send the message to the OBS Studio instance.
-
batchMessage
public OpenProjector.Request batchMessage()
Batch the message to the OBS Studio instance.
-
-