Skip to content

Commit 3e24dc2

Browse files
authored
Merge branch 'staging' into fix_mac_browser
2 parents dbebb7d + 52520c1 commit 3e24dc2

37 files changed

Lines changed: 757 additions & 813 deletions

.github/workflows/main.yml

Lines changed: 87 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -22,98 +22,98 @@ env:
2222
SLGenerator: Visual Studio 17 2022
2323
SLDistributeDirectory: distribute
2424
SLFullDistributePath: "streamlabs-build.app/distribute" # The .app extension is required to run macOS tests correctly.
25-
LibOBSVersion: 29.1.3sl37mb26
25+
LibOBSVersion: 30.2.3sl4
2626
PACKAGE_NAME: osn
2727

2828
jobs:
29-
macos64:
30-
name: 'macOS'
31-
runs-on: ${{ matrix.image }}
32-
strategy:
33-
matrix:
34-
BuildReleases: [Release-x86_64, Release-arm64]
35-
include:
36-
- BuildReleases: Release-x86_64
37-
image: macos-13
38-
BuildConfig: RelWithDebInfo
39-
ReleaseName: release
40-
Architecture: x86_64
41-
- BuildReleases: Release-arm64
42-
image: macos-14
43-
BuildConfig: RelWithDebInfo
44-
ReleaseName: release
45-
Architecture: arm64
46-
env:
47-
OS_TAG: "osx"
48-
steps:
49-
- name: 'Checkout'
50-
uses: actions/checkout@v3
51-
with:
52-
submodules: 'recursive'
53-
- name: Get the version
54-
id: get_version
55-
run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT
56-
shell: bash
57-
- name: Install Node.js
58-
uses: actions/setup-node@v3
59-
with:
60-
node-version: '18.x'
61-
- name: Install dependencies
62-
shell: bash
63-
run: './ci/install-dependencies-osx.sh'
64-
- name: 'Configure obs-studio-node'
65-
shell: bash
66-
run: './ci/configure-osn-osx.sh'
67-
env:
68-
BUILD_CONFIG: ${{matrix.BuildConfig}}
69-
RELEASE_NAME: ${{matrix.ReleaseName}}
70-
ARCHITECTURE: ${{matrix.Architecture}}
71-
tagartifact: ${{ steps.get_version.outputs.VERSION }}
72-
- name: 'Build obs-studio-node'
73-
run: ./ci/build-osn-osx.sh
74-
shell: bash
75-
env:
76-
BUILD_CONFIG: ${{matrix.BuildConfig}}
77-
SENTRY_AUTH_TOKEN: ${{secrets.SENTRY_AUTH_TOKEN}}
78-
- name: Put version into package.json
79-
if: startsWith(github.ref, 'refs/tags/')
80-
run: node ci/bump-version.js "${{ steps.get_version.outputs.VERSION }}" "${{env.PACKAGE_PATH}}"
81-
env:
82-
PACKAGE_PATH: "${{env.SLFullDistributePath}}/${{env.InstallPath}}"
83-
- name: 'Run tests'
84-
continue-on-error: true
85-
run: 'yarn run test'
86-
env:
87-
SLOBS_BE_STREAMKEY: ${{secrets.testsStreamKey}}
88-
SLOBS_TEST_USER_POOL_TOKEN: ${{secrets.testsUserPoolToken}}
29+
# macos64:
30+
# name: 'macOS'
31+
# runs-on: ${{ matrix.image }}
32+
# strategy:
33+
# matrix:
34+
# BuildReleases: [Release-x86_64, Release-arm64]
35+
# include:
36+
# - BuildReleases: Release-x86_64
37+
# image: macos-13
38+
# BuildConfig: RelWithDebInfo
39+
# ReleaseName: release
40+
# Architecture: x86_64
41+
# - BuildReleases: Release-arm64
42+
# image: macos-14
43+
# BuildConfig: RelWithDebInfo
44+
# ReleaseName: release
45+
# Architecture: arm64
46+
# env:
47+
# OS_TAG: "osx"
48+
# steps:
49+
# - name: 'Checkout'
50+
# uses: actions/checkout@v3
51+
# with:
52+
# submodules: 'recursive'
53+
# - name: Get the version
54+
# id: get_version
55+
# run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT
56+
# shell: bash
57+
# - name: Install Node.js
58+
# uses: actions/setup-node@v3
59+
# with:
60+
# node-version: '18.x'
61+
# - name: Install dependencies
62+
# shell: bash
63+
# run: './ci/install-dependencies-osx.sh'
64+
# - name: 'Configure obs-studio-node'
65+
# shell: bash
66+
# run: './ci/configure-osn-osx.sh'
67+
# env:
68+
# BUILD_CONFIG: ${{matrix.BuildConfig}}
69+
# RELEASE_NAME: ${{matrix.ReleaseName}}
70+
# ARCHITECTURE: ${{matrix.Architecture}}
71+
# tagartifact: ${{ steps.get_version.outputs.VERSION }}
72+
# - name: 'Build obs-studio-node'
73+
# run: ./ci/build-osn-osx.sh
74+
# shell: bash
75+
# env:
76+
# BUILD_CONFIG: ${{matrix.BuildConfig}}
77+
# SENTRY_AUTH_TOKEN: ${{secrets.SENTRY_AUTH_TOKEN}}
78+
# - name: Put version into package.json
79+
# if: startsWith(github.ref, 'refs/tags/')
80+
# run: node ci/bump-version.js "${{ steps.get_version.outputs.VERSION }}" "${{env.PACKAGE_PATH}}"
81+
# env:
82+
# PACKAGE_PATH: "${{env.SLFullDistributePath}}/${{env.InstallPath}}"
83+
# - name: 'Run tests'
84+
# continue-on-error: true
85+
# run: 'yarn run test'
86+
# env:
87+
# SLOBS_BE_STREAMKEY: ${{secrets.testsStreamKey}}
88+
# SLOBS_TEST_USER_POOL_TOKEN: ${{secrets.testsUserPoolToken}}
8989

90-
OSN_ACCESS_KEY_ID: ${{secrets.AWS_RELEASE_ACCESS_KEY_ID}}
91-
OSN_SECRET_ACCESS_KEY: ${{secrets.AWS_RELEASE_SECRET_ACCESS_KEY}}
92-
RELEASE_NAME: ${{matrix.ReleaseName}}
90+
# OSN_ACCESS_KEY_ID: ${{secrets.AWS_RELEASE_ACCESS_KEY_ID}}
91+
# OSN_SECRET_ACCESS_KEY: ${{secrets.AWS_RELEASE_SECRET_ACCESS_KEY}}
92+
# RELEASE_NAME: ${{matrix.ReleaseName}}
9393

94-
- name: Tar artifact for deployment
95-
if: startsWith(github.ref, 'refs/tags/')
96-
run: tar -cvzf ${{env.TARGET_ARTIFACT}}.tar.gz -C ${{env.SLFullDistributePath}} ${{env.InstallPath}}
97-
env:
98-
TARGET_ARTIFACT: ${{env.PACKAGE_NAME}}-${{ steps.get_version.outputs.VERSION }}-${{matrix.ReleaseName}}-${{env.OS_TAG}}-${{matrix.Architecture}}
99-
- name: Configure AWS credentials
100-
if: startsWith(github.ref, 'refs/tags/')
101-
uses: aws-actions/configure-aws-credentials@v1
102-
with:
103-
aws-access-key-id: ${{secrets.AWS_RELEASE_ACCESS_KEY_ID}}
104-
aws-secret-access-key: ${{secrets.AWS_RELEASE_SECRET_ACCESS_KEY}}
105-
aws-region: us-west-2
106-
- name: Deploy
107-
if: startsWith(github.ref, 'refs/tags/')
108-
run: aws s3 cp ${{env.TARGET_ARTIFACT}}.tar.gz s3://${{env.RELEASE_BUCKET}} --acl public-read
109-
env:
110-
TARGET_ARTIFACT: ${{env.PACKAGE_NAME}}-${{ steps.get_version.outputs.VERSION }}-${{matrix.ReleaseName}}-${{env.OS_TAG}}-${{matrix.Architecture}}
111-
- name: 'Upload debug files to Sentry'
112-
if: startsWith(github.ref, 'refs/tags/')
113-
run: 'python ./ci/sentry-osx.py'
114-
env:
115-
SENTRY_AUTH_TOKEN: ${{secrets.SENTRY_AUTH_TOKEN}}
116-
BUILDCONFIG: ${{matrix.BuildConfig}}
94+
# - name: Tar artifact for deployment
95+
# if: startsWith(github.ref, 'refs/tags/')
96+
# run: tar -cvzf ${{env.TARGET_ARTIFACT}}.tar.gz -C ${{env.SLFullDistributePath}} ${{env.InstallPath}}
97+
# env:
98+
# TARGET_ARTIFACT: ${{env.PACKAGE_NAME}}-${{ steps.get_version.outputs.VERSION }}-${{matrix.ReleaseName}}-${{env.OS_TAG}}-${{matrix.Architecture}}
99+
# - name: Configure AWS credentials
100+
# if: startsWith(github.ref, 'refs/tags/')
101+
# uses: aws-actions/configure-aws-credentials@v1
102+
# with:
103+
# aws-access-key-id: ${{secrets.AWS_RELEASE_ACCESS_KEY_ID}}
104+
# aws-secret-access-key: ${{secrets.AWS_RELEASE_SECRET_ACCESS_KEY}}
105+
# aws-region: us-west-2
106+
# - name: Deploy
107+
# if: startsWith(github.ref, 'refs/tags/')
108+
# run: aws s3 cp ${{env.TARGET_ARTIFACT}}.tar.gz s3://${{env.RELEASE_BUCKET}} --acl public-read
109+
# env:
110+
# TARGET_ARTIFACT: ${{env.PACKAGE_NAME}}-${{ steps.get_version.outputs.VERSION }}-${{matrix.ReleaseName}}-${{env.OS_TAG}}-${{matrix.Architecture}}
111+
# - name: 'Upload debug files to Sentry'
112+
# if: startsWith(github.ref, 'refs/tags/')
113+
# run: 'python ./ci/sentry-osx.py'
114+
# env:
115+
# SENTRY_AUTH_TOKEN: ${{secrets.SENTRY_AUTH_TOKEN}}
116+
# BUILDCONFIG: ${{matrix.BuildConfig}}
117117

118118
win64:
119119
name: 'Windows 64-bit'

js/module.d.ts

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,9 @@ export declare const enum ETextType {
110110
TextInfo = 3
111111
}
112112
export declare const enum ETextInfoType {
113-
Normal = 0,
114-
Warning = 1,
115-
Error = 2,
113+
Normal = 0,
114+
Warning = 1,
115+
Error = 2
116116
}
117117
export declare const enum ENumberType {
118118
Scroller = 0,
@@ -148,7 +148,7 @@ export declare const enum ESourceOutputFlags {
148148
DoNotDuplicate = 128,
149149
Deprecated = 256,
150150
DoNotSelfMonitor = 512,
151-
ForceUiRefresh = 1073741824,
151+
ForceUiRefresh = 1073741824
152152
}
153153
export declare const enum ESceneDupType {
154154
Refs = 0,
@@ -354,7 +354,7 @@ export interface IGlobal {
354354
getOutputFlagsFromId(id: string): number;
355355
setOutputSource(channel: number, input: ISource): void;
356356
getOutputSource(channel: number): ISource;
357-
addSceneToBackstage(input: ISource) : void;
357+
addSceneToBackstage(input: ISource): void;
358358
removeSceneFromBackstage(input: ISource): void;
359359
readonly totalFrames: number;
360360
readonly laggedFrames: number;
@@ -558,7 +558,7 @@ export interface ISceneItem {
558558
streamVisible: boolean;
559559
recordingVisible: boolean;
560560
video: IVideo;
561-
readonly transformInfo: ITransformInfo;
561+
transformInfo: ITransformInfo;
562562
crop: ICropInfo;
563563
moveUp(): void;
564564
moveDown(): void;
@@ -612,8 +612,6 @@ export interface IFader {
612612
destroy(): void;
613613
attach(source: IInput): void;
614614
detach(): void;
615-
addCallback(cb: (db: number) => void): ICallbackData;
616-
removeCallback(cbData: ICallbackData): void;
617615
}
618616
export interface IVolmeterFactory {
619617
create(type: EFaderType): IVolmeter;
@@ -623,8 +621,6 @@ export interface IVolmeter {
623621
destroy(): void;
624622
attach(source: IInput): void;
625623
detach(): void;
626-
addCallback(cb: (magnitude: number[], peak: number[], inputPeak: number[]) => void): ICallbackData;
627-
removeCallback(cbData: ICallbackData): void;
628624
}
629625
export interface ICallbackData {
630626
}
@@ -641,7 +637,6 @@ export interface IDisplay {
641637
getPreviewSize(x: number, y: number): void;
642638
shouldDrawUI: boolean;
643639
paddingSize: number;
644-
video: IVideo;
645640
setPaddingColor(r: number, g: number, b: number, a: number): void;
646641
setBackgroundColor(r: number, g: number, b: number, a: number): void;
647642
setOutlineColor(r: number, g: number, b: number, a: number): void;
@@ -752,7 +747,7 @@ export declare const enum ERecordingFormat {
752747
FLV = "flv",
753748
MOV = "mov",
754749
MKV = "mkv",
755-
TS = "ts",
750+
TS = "mpegts",
756751
M3M8 = "m3m8"
757752
}
758753
export declare const enum ERecordingQuality {

js/module.ts

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1337,19 +1337,6 @@ export interface IFader {
13371337
* Otherwise, is a no-op.
13381338
*/
13391339
detach(): void;
1340-
1341-
/**
1342-
* Add a callback to the fader. Callback will be called
1343-
* each time volume associated with the attached source changes.
1344-
* @param cb - A callback that occurs when volume changes.
1345-
*/
1346-
addCallback(cb: (db: number) => void): ICallbackData;
1347-
1348-
/**
1349-
* Remove a callback to prevent events from occuring immediately.
1350-
* @param cbData - Object passed back from a call to {@link ObsFader#addCallback}
1351-
*/
1352-
removeCallback(cbData: ICallbackData): void;
13531340
}
13541341

13551342
export interface IVolmeterFactory {
@@ -1384,22 +1371,6 @@ export interface IVolmeter {
13841371
* Detaches the currently attached source from the volmeter object
13851372
*/
13861373
detach(): void;
1387-
1388-
/**
1389-
* Add a callback to the volmeter. Callback will be called
1390-
* each time volume associated with the attached source changes.
1391-
* @param cb - A callback that occurs when volume changes.
1392-
*/
1393-
addCallback(
1394-
cb: (magnitude: number[],
1395-
peak: number[],
1396-
inputPeak: number[]) => void): ICallbackData;
1397-
1398-
/**
1399-
* Remove a callback to prevent events from occuring immediately.
1400-
* @param cbData - Object passed back from a call to {@link ObsVolmeter#addCallback}
1401-
*/
1402-
removeCallback(cbData: ICallbackData): void;
14031374
}
14041375

14051376
/**

obs-studio-client/source/audio-track.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,9 @@ Napi::Value osn::AudioTrack::Create(const Napi::CallbackInfo &info)
6262
if (!conn)
6363
return info.Env().Undefined();
6464

65-
std::vector<ipc::value> response = conn->call_synchronous_helper("AudioTrack", "Create", {});
65+
uint32_t bitrate = info[0].ToNumber().Uint32Value();
66+
std::string name = info[1].ToString().Utf8Value();
67+
std::vector<ipc::value> response = conn->call_synchronous_helper("AudioTrack", "Create", {ipc::value(bitrate), ipc::value(name)});
6668

6769
if (!ValidateResponse(info, response))
6870
return info.Env().Undefined();

0 commit comments

Comments
 (0)