Obs linux browser source

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

CEF-based OBS Studio browser plugin

License

obsproject/obs-browser

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Sign In Required

Please sign in to use Codespaces.

Launching GitHub Desktop

If nothing happens, download GitHub Desktop and try again.

Launching GitHub Desktop

If nothing happens, download GitHub Desktop and try again.

Launching Xcode

If nothing happens, download Xcode and try again.

Launching Visual Studio Code

Your codespace will open once ready.

There was a problem preparing your codespace, please try again.

Latest commit

Git stats

Files

Failed to load latest commit information.

README.md

obs-browser introduces a cross-platform Browser Source, powered by CEF (Chromium Embedded Framework), to OBS Studio. A Browser Source allows the user to integrate web-based overlays into their scenes, with complete access to modern web APIs.

Additionally, obs-browser enables Service Integration (linking third party services) and Browser Docks (webpages loaded into the interface itself) on all supported platforms, except for Wayland (Linux).

This plugin is included by default on official packages on Windows, macOS, the Ubuntu PPA and the official Flatpak (most Linux distributions).

obs-browser provides a global object that allows access to some OBS-specific functionality from JavaScript. This can be used to create an overlay that adapts dynamically to changes in OBS.

TypeScript Type Definitions

If you’re using TypeScript, type definitions for the obs-browser bindings are available through npm and yarn.

# npm npm install --save-dev @types/obs-studio # yarn yarn add --dev @types/obs-studio

Get Browser Plugin Version

/** * @returns string> OBS Browser plugin version */ window.obsstudio.pluginVersion // => 2.17.0

Register for event callbacks

/** * @callback EventListener * @param CustomEvent> event */ /** * @param string> type * @param EventListener> listener */ window.addEventListener('obsSceneChanged', function(event)  var t = document.createTextNode(event.detail.name) document.body.appendChild(t) >)

Descriptions for these events can be found here.

  • obsSceneChanged
  • obsSourceVisibleChanged
  • obsSourceActiveChanged
  • obsStreamingStarting
  • obsStreamingStarted
  • obsStreamingStopping
  • obsStreamingStopped
  • obsRecordingStarting
  • obsRecordingStarted
  • obsRecordingPaused
  • obsRecordingUnpaused
  • obsRecordingStopping
  • obsRecordingStopped
  • obsReplaybufferStarting
  • obsReplaybufferStarted
  • obsReplaybufferSaved
  • obsReplaybufferStopping
  • obsReplaybufferStopped
  • obsVirtualcamStarted
  • obsVirtualcamStopped
  • obsExit
  • [Any custom event emitted via obs-websocket vendor requests]

Get webpage control permissions

Permissions required: NONE

/** * @typedef Level - The level of permissions. 0 for NONE, 1 for READ_OBS (OBS data), 2 for READ_USER (User data), 3 for BASIC, 4 for ADVANCED and 5 for ALL */ /** * @callback LevelCallback * @param Level> level */ /** * @param LevelCallback> cb - The callback that receives the current control level. */ window.obsstudio.getControlLevel(function (level)  console.log(level) >)

Permissions required: READ_OBS

/** * @typedef Status * @property boolean> recording - not affected by pause state * @property boolean> recordingPaused * @property boolean> streaming * @property boolean> replaybuffer * @property boolean> virtualcam */ /** * @callback StatusCallback * @param Status> status */ /** * @param StatusCallback> cb - The callback that receives the current output status of OBS. */ window.obsstudio.getStatus(function (status)  console.log(status) >)

Permissions required: READ_USER

/** * @typedef Scene * @property string> name - name of the scene * @property number> width - width of the scene * @property number> height - height of the scene */ /** * @callback SceneCallback * @param Scene> scene */ /** * @param SceneCallback> cb - The callback that receives the current scene in OBS. */ window.obsstudio.getCurrentScene(function(scene)  console.log(scene) >)

Permissions required: READ_USER

/** * @callback ScenesCallback * @param string[]> scenes */ /** * @param ScenesCallback> cb - The callback that receives the scenes. */ window.obsstudio.getScenes(function (scenes)  console.log(scenes) >)

Permissions required: READ_USER

/** * @callback TransitionsCallback * @param string[]> transitions */ /** * @param TransitionsCallback> cb - The callback that receives the transitions. */ window.obsstudio.getTransitions(function (transitions)  console.log(transitions) >)

Permissions required: READ_USER

/** * @callback TransitionCallback * @param string> transition */ /** * @param TransitionCallback> cb - The callback that receives the transition currently set. */ window.obsstudio.getCurrentTransition(function (transition)  console.log(transition) >)

Permissions required: BASIC

/** * Does not accept any parameters and does not return anything */ window.obsstudio.saveReplayBuffer()

Permissions required: ADVANCED

/** * Does not accept any parameters and does not return anything */ window.obsstudio.startReplayBuffer()

Permissions required: ADVANCED

/** * Does not accept any parameters and does not return anything */ window.obsstudio.stopReplayBuffer()

Permissions required: ADVANCED

/** * @param string> name - Name of the scene */ window.obsstudio.setCurrentScene(name)

Set the current transition

Permissions required: ADVANCED

/** * @param string> name - Name of the transition */ window.obsstudio.setCurrentTransition(name)
/** * Does not accept any parameters and does not return anything */ window.obsstudio.startStreaming()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.stopStreaming()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.startRecording()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.stopRecording()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.pauseRecording()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.unpauseRecording()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.startVirtualcam()
/** * Does not accept any parameters and does not return anything */ window.obsstudio.stopVirtualcam()

Register for visibility callbacks

This method is legacy. Register an event listener instead.

/** * onVisibilityChange gets callbacks when the visibility of the browser source changes in OBS * * @deprecated * @see obsSourceVisibleChanged * @param boolean> visibility - True -> visible, False -> hidden */ window.obsstudio.onVisibilityChange = function(visibility)  >;

Register for active/inactive callbacks

This method is legacy. Register an event listener instead.

/** * onActiveChange gets callbacks when the active/inactive state of the browser source changes in OBS * * @deprecated * @see obsSourceActiveChanged * @param bool> True -> active, False -> inactive */ window.obsstudio.onActiveChange = function(active)  >;

obs-browser includes integration with obs-websocket’s Vendor requests. The vendor name to use is obs-browser , and available requests are:

  • emit_event — Takes event_name and ? event_data parameters. Emits a custom event to all browser sources. To subscribe to events, see here
    • See #340 for example usage.

    There are no available vendor events at this time.

    OBS Browser cannot be built standalone. It is built as part of OBS Studio.

    By following the instructions, this will enable Browser Source & Custom Browser Docks on all three platforms. Both BUILD_BROWSER and CEF_ROOT_DIR are required.

    Follow the build instructions and be sure to download the CEF Wrapper and set CEF_ROOT_DIR in CMake to point to the extracted wrapper.

    Use the macOS Full Build Script. This will automatically download & enable OBS Browser.

    Follow the build instructions and choose the «If building with browser source» option. This includes steps to download/extract the CEF Wrapper, and set the required CMake variables.

    About

    CEF-based OBS Studio browser plugin

    Источник

    (Legacy) Linux Browser

    obs-linuxbrowser.png

    One tip when using this new browser with obs compared to the old qtwebkit browser source, if you don’t want to see the scroll bars in the source, you need to add the following command line options in your source configuration.

    After applying those you may need to restart OBS in order for the results to take affect, hitting the restart browser button doesn’t seem to work.

    Osiris

    David Carver

    Member

    Yes, I can but the old browser plugin didn’t display the scroll bars by default. I can also hide them by applying a crop filter as well and just cutting off the scroll bars.

    JLRS

    New Member

    I can’t setup Linux Browser, if anybody help me.

    I have already uploaded the files to: home/webm/.config/obs-studio/plugin_config/
    and not work.

    I created the directory «plugins» and neither work:

    no-linux-browswer_01.jpg

    I have not directory «PLUGINS» only «PLUGIN_CONFIG».

    no-linux-browswer_02.png

    I wait. Thank you in advanced.

    bazukas

    I can’t setup Linux Browser, if anybody help me.

    I have already uploaded the files to: home/webm/.config/obs-studio/plugin_config/
    and not work.

    I created the directory «plugins» and neither work:

    no-linux-browswer_01.jpg

    I have not directory «PLUGINS» only «PLUGIN_CONFIG».

    no-linux-browswer_02.png

    I wait. Thank you in advanced.

    Hello, you need to create the «plugins» directory yourself, you can find installation instructions over here: https://github.com/bazukas/obs-linuxbrowser#installing

    JLRS

    New Member

    Hello, you need to create the «plugins» directory yourself, you can find installation instructions over here: https://github.com/bazukas/obs-linuxbrowser#installing

    Thankyou very much BAZUKAS !

    I created the folders manually with Double Commander, but; the route was not correct, since TERMNAL was very simple:

    1.- mkdir -p $HOME/.config/obs-studio/plugins

    2.- tar xfvz (download folder) /linuxbrowser0.2.0-obs18.0.1-64bit.tgz -C $HOME/.config/obs-studio/plugins

    vapeahoy

    Member

    Ok so I just verified a bug with this, I think:I run obs studio in portable mode, mint 18.2, and *if* i have the config files, and thus also linux browsers unique plugin folder, in the portable location-> Then I can only see the plugin’s options for linux browser but get *no output*, it doesn’t work. I disable portable mode, move all config files to the standard location for obs studio on my distro-> Linux browser works with it’s output.
    This saddens me greatly, and i’m hoping it’s either just an oversight on my part or that we can get this fixed asap.
    It does not seem to be a permission issue on my end that I can see or anything like that, i’m open for ideas tho.
    Obs studio itself has some issues with running in portable mode, that frankly shouldn’t still exist but they’re quite minor, such as log file location etc (it still writes/uploads logs just fine).

    edit: initially i thought it was just something about my compiling, but it was just this thing with portable mode. Tested both compile from source/premade binaries.

    bazukas

    Ok so I just verified a bug with this, I think:I run obs studio in portable mode, mint 18.2, and *if* i have the config files, and thus also linux browsers unique plugin folder, in the portable location-> Then I can only see the plugin’s options for linux browser but get *no output*, it doesn’t work. I disable portable mode, move all config files to the standard location for obs studio on my distro-> Linux browser works with it’s output.
    This saddens me greatly, and i’m hoping it’s either just an oversight on my part or that we can get this fixed asap.
    It does not seem to be a permission issue on my end that I can see or anything like that, i’m open for ideas tho.
    Obs studio itself has some issues with running in portable mode, that frankly shouldn’t still exist but they’re quite minor, such as log file location etc (it still writes/uploads logs just fine).

    edit: initially i thought it was just something about my compiling, but it was just this thing with portable mode. Tested both compile from source/premade binaries.

    Источник

    Читайте также:  Shutdown with time linux
Оцените статью
Adblock
detector