pax_global_header00006660000000000000000000000064147725726450014535gustar00rootroot0000000000000052 comment=04d8598a46b95a4abc320bd571f98a5e79304dbe blur-filter-obs-plugin-1.1.0/000077500000000000000000000000001477257264500160405ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.clang-format000066400000000000000000000134161477257264500204200ustar00rootroot00000000000000# please use clang-format version 16 or later Standard: c++17 AccessModifierOffset: -8 AlignAfterOpenBracket: Align AlignConsecutiveAssignments: false AlignConsecutiveDeclarations: false AlignEscapedNewlines: Left AlignOperands: true AlignTrailingComments: true AllowAllArgumentsOnNextLine: false AllowAllConstructorInitializersOnNextLine: false AllowAllParametersOfDeclarationOnNextLine: false AllowShortBlocksOnASingleLine: false AllowShortCaseLabelsOnASingleLine: false AllowShortFunctionsOnASingleLine: Inline AllowShortIfStatementsOnASingleLine: false AllowShortLambdasOnASingleLine: Inline AllowShortLoopsOnASingleLine: false AlwaysBreakAfterDefinitionReturnType: None AlwaysBreakAfterReturnType: None AlwaysBreakBeforeMultilineStrings: false AlwaysBreakTemplateDeclarations: false BinPackArguments: true BinPackParameters: true BraceWrapping: AfterClass: false AfterControlStatement: false AfterEnum: false AfterFunction: true AfterNamespace: false AfterObjCDeclaration: false AfterStruct: false AfterUnion: false AfterExternBlock: false BeforeCatch: false BeforeElse: false IndentBraces: false SplitEmptyFunction: true SplitEmptyRecord: true SplitEmptyNamespace: true BreakBeforeBinaryOperators: None BreakBeforeBraces: Custom BreakBeforeTernaryOperators: true BreakConstructorInitializers: BeforeColon BreakStringLiterals: false # apparently unpredictable ColumnLimit: 120 CompactNamespaces: false ConstructorInitializerAllOnOneLineOrOnePerLine: true ConstructorInitializerIndentWidth: 8 ContinuationIndentWidth: 8 Cpp11BracedListStyle: true DerivePointerAlignment: false DisableFormat: false FixNamespaceComments: true ForEachMacros: - 'json_object_foreach' - 'json_object_foreach_safe' - 'json_array_foreach' - 'HASH_ITER' IncludeBlocks: Preserve IndentCaseLabels: false IndentPPDirectives: None IndentWidth: 8 IndentWrappedFunctionNames: false KeepEmptyLinesAtTheStartOfBlocks: true MaxEmptyLinesToKeep: 1 NamespaceIndentation: None ObjCBinPackProtocolList: Auto ObjCBlockIndentWidth: 8 ObjCSpaceAfterProperty: true ObjCSpaceBeforeProtocolList: true PenaltyBreakAssignment: 10 PenaltyBreakBeforeFirstCallParameter: 30 PenaltyBreakComment: 10 PenaltyBreakFirstLessLess: 0 PenaltyBreakString: 10 PenaltyExcessCharacter: 100 PenaltyReturnTypeOnItsOwnLine: 60 PointerAlignment: Right ReflowComments: false SortIncludes: false SortUsingDeclarations: false SpaceAfterCStyleCast: false SpaceAfterLogicalNot: false SpaceAfterTemplateKeyword: false SpaceBeforeAssignmentOperators: true SpaceBeforeCtorInitializerColon: true SpaceBeforeInheritanceColon: true SpaceBeforeParens: ControlStatements SpaceBeforeRangeBasedForLoopColon: true SpaceInEmptyParentheses: false SpacesBeforeTrailingComments: 1 SpacesInAngles: false SpacesInCStyleCastParentheses: false SpacesInContainerLiterals: false SpacesInParentheses: false SpacesInSquareBrackets: false StatementMacros: - 'Q_OBJECT' TabWidth: 8 TypenameMacros: - 'DARRAY' UseTab: ForContinuationAndIndentation --- Language: ObjC AccessModifierOffset: 2 AlignArrayOfStructures: Right AlignConsecutiveAssignments: None AlignConsecutiveBitFields: None AlignConsecutiveDeclarations: None AlignConsecutiveMacros: Enabled: true AcrossEmptyLines: false AcrossComments: true AllowShortBlocksOnASingleLine: Never AllowShortEnumsOnASingleLine: false AllowShortFunctionsOnASingleLine: Empty AllowShortIfStatementsOnASingleLine: Never AllowShortLambdasOnASingleLine: None AttributeMacros: ['__unused', '__autoreleasing', '_Nonnull', '__bridge'] BitFieldColonSpacing: Both #BreakBeforeBraces: Webkit BreakBeforeBraces: Custom BraceWrapping: AfterCaseLabel: false AfterClass: true AfterControlStatement: Never AfterEnum: false AfterFunction: true AfterNamespace: false AfterObjCDeclaration: false AfterStruct: false AfterUnion: false AfterExternBlock: false BeforeCatch: false BeforeElse: false BeforeLambdaBody: false BeforeWhile: false IndentBraces: false SplitEmptyFunction: false SplitEmptyRecord: false SplitEmptyNamespace: true BreakAfterAttributes: Never BreakArrays: false BreakBeforeConceptDeclarations: Allowed BreakBeforeInlineASMColon: OnlyMultiline BreakConstructorInitializers: AfterColon BreakInheritanceList: AfterComma ColumnLimit: 120 ConstructorInitializerIndentWidth: 4 ContinuationIndentWidth: 4 EmptyLineAfterAccessModifier: Never EmptyLineBeforeAccessModifier: LogicalBlock ExperimentalAutoDetectBinPacking: false FixNamespaceComments: true IndentAccessModifiers: false IndentCaseBlocks: false IndentCaseLabels: true IndentExternBlock: Indent IndentGotoLabels: false IndentRequiresClause: true IndentWidth: 4 IndentWrappedFunctionNames: true InsertBraces: false InsertNewlineAtEOF: true KeepEmptyLinesAtTheStartOfBlocks: false LambdaBodyIndentation: Signature NamespaceIndentation: All ObjCBinPackProtocolList: Auto ObjCBlockIndentWidth: 4 ObjCBreakBeforeNestedBlockParam: false ObjCSpaceAfterProperty: true ObjCSpaceBeforeProtocolList: true PPIndentWidth: -1 PackConstructorInitializers: NextLine QualifierAlignment: Leave ReferenceAlignment: Right RemoveSemicolon: false RequiresClausePosition: WithPreceding RequiresExpressionIndentation: OuterScope SeparateDefinitionBlocks: Always ShortNamespaceLines: 1 SortIncludes: false #SortUsingDeclarations: LexicographicNumeric SortUsingDeclarations: true SpaceAfterCStyleCast: true SpaceAfterLogicalNot: false SpaceAroundPointerQualifiers: Default SpaceBeforeCaseColon: false SpaceBeforeCpp11BracedList: true SpaceBeforeCtorInitializerColon: true SpaceBeforeInheritanceColon: true SpaceBeforeParens: ControlStatements SpaceBeforeRangeBasedForLoopColon: true SpaceBeforeSquareBrackets: false SpaceInEmptyBlock: false SpaceInEmptyParentheses: false SpacesBeforeTrailingComments: 2 SpacesInConditionalStatement: false SpacesInLineCommentPrefix: Minimum: 1 Maximum: -1 Standard: c++17 TabWidth: 4 UseTab: Never blur-filter-obs-plugin-1.1.0/.gersemirc000066400000000000000000000004421477257264500200210ustar00rootroot00000000000000# yaml-language-server: $schema=https://raw.githubusercontent.com/BlankSpruce/gersemi/master/gersemi/configuration.schema.json color: false definitions: [] line_length: 120 indent: 2 list_expansion: favour-inlining quiet: false unsafe: false workers: 10 warn_about_unknown_commands: false blur-filter-obs-plugin-1.1.0/.github/000077500000000000000000000000001477257264500174005ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/000077500000000000000000000000001477257264500210405ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/build-plugin/000077500000000000000000000000001477257264500234335ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/build-plugin/action.yaml000066400000000000000000000064351477257264500256040ustar00rootroot00000000000000name: Set up and build plugin description: Builds the plugin for specified architecture and build config inputs: target: description: Target architecture for dependencies required: true config: description: Build configuration required: false default: RelWithDebInfo codesign: description: Enable codesigning (macOS only) required: false default: 'false' codesignIdent: description: Developer ID for application codesigning (macOS only) required: false default: '-' workingDirectory: description: Working directory for packaging required: false default: ${{ github.workspace }} runs: using: composite steps: - name: Run macOS Build if: runner.os == 'macOS' shell: zsh --no-rcs --errexit --pipefail {0} working-directory: ${{ inputs.workingDirectory }} env: CCACHE_DIR: ${{ inputs.workingDirectory }}/.ccache CODESIGN_IDENT: ${{ inputs.codesignIdent }} CODESIGN_TEAM: ${{ inputs.codesignTeam }} run: | : Run macOS Build local -a build_args=(--config ${{ inputs.config }}) if (( ${+RUNNER_DEBUG} )) build_args+=(--debug) if [[ '${{ inputs.codesign }}' == 'true' ]] build_args+=(--codesign) .github/scripts/build-macos ${build_args} - name: Install Dependencies 🛍️ if: runner.os == 'Linux' shell: bash run: | : Install Dependencies 🛍️ echo ::group::Install Dependencies eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" echo "/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin" >> $GITHUB_PATH brew install --quiet zsh echo ::endgroup:: - name: Run Ubuntu Build if: runner.os == 'Linux' shell: zsh --no-rcs --errexit --pipefail {0} working-directory: ${{ inputs.workingDirectory }} env: CCACHE_DIR: ${{ inputs.workingDirectory }}/.ccache run: | : Run Ubuntu Build local -a build_args=( --target ubuntu-${{ inputs.target }} --config ${{ inputs.config }} ) if (( ${+RUNNER_DEBUG} )) build_args+=(--debug) .github/scripts/build-ubuntu ${build_args} - name: Run Windows Build if: runner.os == 'Windows' shell: pwsh run: | # Run Windows Build if ( $Env:RUNNER_DEBUG -ne $null ) { Set-PSDebug -Trace 1 } $BuildArgs = @{ Target = '${{ inputs.target }}' Configuration = '${{ inputs.config }}' } .github/scripts/Build-Windows.ps1 @BuildArgs - name: Create Summary 📊 if: contains(fromJSON('["Linux", "macOS"]'),runner.os) shell: zsh --no-rcs --errexit --pipefail {0} env: CCACHE_DIR: ${{ inputs.workingDirectory }}/.ccache run: | : Create Summary 📊 local -a ccache_data if (( ${+RUNNER_DEBUG} )) { setopt XTRACE ccache_data=("${(fA)$(ccache -s -vv)}") } else { ccache_data=("${(fA)$(ccache -s)}") } print '### ${{ runner.os }} Ccache Stats (${{ inputs.target }})' >> $GITHUB_STEP_SUMMARY print '```' >> $GITHUB_STEP_SUMMARY for line (${ccache_data}) { print ${line} >> $GITHUB_STEP_SUMMARY } print '```' >> $GITHUB_STEP_SUMMARY blur-filter-obs-plugin-1.1.0/.github/actions/check-changes/000077500000000000000000000000001477257264500235235ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/check-changes/action.yaml000066400000000000000000000052141477257264500256660ustar00rootroot00000000000000name: Check For Changed Files description: Checks for changed files compared to specific git reference and glob expression inputs: baseRef: description: Git reference to check against required: false ref: description: Git reference to check with required: false default: HEAD checkGlob: description: Glob expression to limit check to specific files required: false useFallback: description: Use fallback compare against prior commit required: false default: 'true' diffFilter: description: git diff-filter string to use required: false default: '' outputs: hasChangedFiles: value: ${{ steps.checks.outputs.hasChangedFiles }} description: True if specified files were changed in comparison to specified git reference changedFiles: value: ${{ steps.checks.outputs.changedFiles }} description: List of changed files runs: using: composite steps: - name: Check For Changed Files ✅ shell: bash id: checks env: GIT_BASE_REF: ${{ inputs.baseRef }} GIT_REF: ${{ inputs.ref }} GITHUB_EVENT_FORCED: ${{ github.event.forced }} GITHUB_REF_BEFORE: ${{ github.event.before }} USE_FALLBACK: ${{ inputs.useFallback }} DIFF_FILTER: ${{ inputs.diffFilter }} run: | : Check for Changed Files ✅ if [[ "${RUNNER_DEBUG}" ]]; then set -x; fi shopt -s extglob shopt -s dotglob if [[ "${GIT_BASE_REF}" ]]; then if ! git cat-file -e "${GIT_BASE_REF}" &> /dev/null; then echo "::warning::Provided base reference ${GIT_BASE_REF} is invalid" if [[ "${USE_FALLBACK}" == 'true' ]]; then GIT_BASE_REF='HEAD~1' fi fi else if ! git cat-file -e ${GITHUB_REF_BEFORE} &> /dev/null; then GITHUB_REF_BEFORE='4b825dc642cb6eb9a060e54bf8d69288fbee4904' fi GIT_BASE_REF='HEAD~1' case "${GITHUB_EVENT_NAME}" in pull_request) GIT_BASE_REF="origin/${GITHUB_BASE_REF}" ;; push) if [[ "${GITHUB_EVENT_FORCED}" != 'true' ]]; then GIT_BASE_REF="${GITHUB_REF_BEFORE}"; fi ;; *) ;; esac fi changes=($(git diff --name-only --diff-filter="${DIFF_FILTER}" ${GIT_BASE_REF} ${GIT_REF} -- ${{ inputs.checkGlob }})) if (( ${#changes[@]} )); then file_string="${changes[*]}" echo "hasChangedFiles=true" >> $GITHUB_OUTPUT echo "changedFiles=[\"${file_string// /\",\"}\"]" >> $GITHUB_OUTPUT else echo "hasChangedFiles=false" >> $GITHUB_OUTPUT echo "changedFiles=[]" >> GITHUB_OUTPUT fi blur-filter-obs-plugin-1.1.0/.github/actions/package-plugin/000077500000000000000000000000001477257264500237275ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/package-plugin/action.yaml000066400000000000000000000070241477257264500260730ustar00rootroot00000000000000name: Package plugin description: Packages the plugin for specified architecture and build config. inputs: target: description: Build target for dependencies required: true config: description: Build configuration required: false default: RelWithDebInfo codesign: description: Enable codesigning (macOS only) required: false default: 'false' notarize: description: Enable notarization (macOS only) required: false default: 'false' codesignIdent: description: Developer ID for application codesigning (macOS only) required: false default: '-' installerIdent: description: Developer ID for installer package codesigning (macOS only) required: false default: '' codesignTeam: description: Developer team for codesigning (macOS only) required: false default: '' codesignUser: description: Apple ID username for notarization (macOS only) required: false default: '' codesignPass: description: Apple ID password for notarization (macOS only) required: false default: '' package: description: Create Windows or macOS installation package required: false default: 'false' workingDirectory: description: Working directory for packaging required: false default: ${{ github.workspace }} runs: using: composite steps: - name: Run macOS Packaging if: runner.os == 'macOS' shell: zsh --no-rcs --errexit --pipefail {0} working-directory: ${{ inputs.workingDirectory }} env: CODESIGN_IDENT: ${{ inputs.codesignIdent }} CODESIGN_IDENT_INSTALLER: ${{ inputs.installerIdent }} CODESIGN_TEAM: ${{ inputs.codesignTeam }} CODESIGN_IDENT_USER: ${{ inputs.codesignUser }} CODESIGN_IDENT_PASS: ${{ inputs.codesignPass }} run: | : Run macOS Packaging local -a package_args=(--config ${{ inputs.config }}) if (( ${+RUNNER_DEBUG} )) package_args+=(--debug) if [[ '${{ inputs.codesign }}' == 'true' ]] package_args+=(--codesign) if [[ '${{ inputs.notarize }}' == 'true' ]] package_args+=(--notarize) if [[ '${{ inputs.package }}' == 'true' ]] package_args+=(--package) .github/scripts/package-macos ${package_args} - name: Install Dependencies 🛍️ if: runner.os == 'Linux' shell: bash run: | : Install Dependencies 🛍️ echo ::group::Install Dependencies eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" echo "/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin" >> $GITHUB_PATH brew install --quiet zsh echo ::endgroup:: - name: Run Ubuntu Packaging if: runner.os == 'Linux' shell: zsh --no-rcs --errexit --pipefail {0} working-directory: ${{ inputs.workingDirectory }} run: | : Run Ubuntu Packaging package_args=( --target ubuntu-${{ inputs.target }} --config ${{ inputs.config }} ) if (( ${+RUNNER_DEBUG} )) build_args+=(--debug) if [[ '${{ inputs.package }}' == 'true' ]] package_args+=(--package) .github/scripts/package-ubuntu ${package_args} - name: Run Windows Packaging if: runner.os == 'Windows' shell: pwsh run: | # Run Windows Packaging if ( $Env:RUNNER_DEBUG -ne $null ) { Set-PSDebug -Trace 1 } $PackageArgs = @{ Target = '${{ inputs.target }}' Configuration = '${{ inputs.config }}' } .github/scripts/Package-Windows.ps1 @PackageArgs blur-filter-obs-plugin-1.1.0/.github/actions/run-clang-format/000077500000000000000000000000001477257264500242145ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/run-clang-format/action.yaml000066400000000000000000000041601477257264500263560ustar00rootroot00000000000000name: Run clang-format description: Runs clang-format and checks for any changes introduced by it inputs: failCondition: description: Controls whether failed checks also fail the workflow run required: false default: never workingDirectory: description: Working directory for checks required: false default: ${{ github.workspace }} runs: using: composite steps: - name: Check Runner Operating System 🏃‍♂️ if: runner.os == 'Windows' shell: bash run: | : Check Runner Operating System 🏃‍♂️ echo "::notice::run-clang-format action requires a macOS-based or Linux-based runner." exit 2 - name: Check for Changed Files ✅ uses: ./.github/actions/check-changes id: checks with: checkGlob: "'*.c' '*.h' '*.cpp' '*.hpp' '*.m' '*.mm'" diffFilter: 'ACM' - name: Install Dependencies 🛍️ if: runner.os == 'Linux' && fromJSON(steps.checks.outputs.hasChangedFiles) shell: bash run: | : Install Dependencies 🛍️ echo ::group::Install Dependencies eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" echo "/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin" >> $GITHUB_PATH echo "/home/linuxbrew/.linuxbrew/opt/clang-format@17/bin" >> $GITHUB_PATH brew install --quiet zsh echo ::endgroup:: - name: Run clang-format 🐉 if: fromJSON(steps.checks.outputs.hasChangedFiles) id: result shell: zsh --no-rcs --errexit --pipefail {0} working-directory: ${{ inputs.workingDirectory }} env: CHANGED_FILES: ${{ steps.checks.outputs.changedFiles }} run: | : Run clang-format 🐉 if (( ${+RUNNER_DEBUG} )) setopt XTRACE print ::group::Install clang-format-17 brew install --quiet obsproject/tools/clang-format@17 print ::endgroup:: print ::group::Run clang-format-17 local -a changes=(${(s:,:)CHANGED_FILES//[\[\]\'\"]/}) ./build-aux/run-clang-format --fail-${{ inputs.failCondition }} --check ${changes} print ::endgroup:: blur-filter-obs-plugin-1.1.0/.github/actions/run-gersemi/000077500000000000000000000000001477257264500232755ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/run-gersemi/action.yaml000066400000000000000000000037321477257264500254430ustar00rootroot00000000000000name: Run gersemi description: Runs gersemi and checks for any changes introduced by it inputs: failCondition: description: Controls whether failed checks also fail the workflow run required: false default: never workingDirectory: description: Working directory for checks required: false default: ${{ github.workspace }} runs: using: composite steps: - name: Check Runner Operating System 🏃‍♂️ if: runner.os == 'Windows' shell: bash run: | : Check Runner Operating System 🏃‍♂️ echo "::notice::run-gersemi action requires a macOS-based or Linux-based runner." exit 2 - name: Check for Changed Files ✅ uses: ./.github/actions/check-changes id: checks with: checkGlob: "'*.cmake' '*CMakeLists.txt'" diffFilter: 'ACM' - name: Install Dependencies 🛍️ if: runner.os == 'Linux' && fromJSON(steps.checks.outputs.hasChangedFiles) shell: bash run: | : Install Dependencies 🛍️ echo ::group::Install Dependencies eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" echo "/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin" >> $GITHUB_PATH brew install --quiet zsh echo ::endgroup:: - name: Run gersemi 🎛️ if: fromJSON(steps.checks.outputs.hasChangedFiles) id: result shell: zsh --no-rcs --errexit --pipefail {0} working-directory: ${{ github.workspace }} env: CHANGED_FILES: ${{ steps.checks.outputs.changedFiles }} run: | : Run gersemi 🎛️ if (( ${+RUNNER_DEBUG} )) setopt XTRACE print ::group::Install gersemi brew install --quiet obsproject/tools/gersemi print ::endgroup:: print ::group::Run gersemi local -a changes=(${(s:,:)CHANGED_FILES//[\[\]\'\"]/}) ./build-aux/run-gersemi --fail-${{ inputs.failCondition }} --check ${changes} print ::endgroup:: blur-filter-obs-plugin-1.1.0/.github/actions/setup-macos-codesigning/000077500000000000000000000000001477257264500255675ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/actions/setup-macos-codesigning/action.yaml000066400000000000000000000153771477257264500277450ustar00rootroot00000000000000name: Set up macOS codesigning description: Sets up code signing certificates, provisioning profiles, and notarization information inputs: codesignIdentity: description: Codesigning identity required: true installerIdentity: description: Codesigning identity for package installer required: false codesignCertificate: description: PKCS12 certificate in base64 format required: true certificatePassword: description: Password required to install PKCS12 certificate required: true keychainPassword: description: Password to use for temporary keychain required: false notarizationUser: description: Apple ID to use for notarization required: false notarizationPassword: description: Application password for notarization provisioningProfile: description: Provisioning profile in base64 format required: false outputs: haveCodesignIdent: description: True if necessary codesigning credentials were found value: ${{ steps.codesign.outputs.haveCodesignIdent }} haveProvisioningProfile: description: True if necessary provisioning profile credentials were found value: ${{ steps.provisioning.outputs.haveProvisioningProfile || steps.codesign.outputs.haveProvisioningProfile }} provisioningProfileUUID: description: UUID of imported provisioning profile value: ${{ steps.provisioning.outputs.provisioningProfileUUID }} haveNotarizationUser: description: True if necessary notarization credentials were found value: ${{ steps.notarization.outputs.haveNotarizationUser || steps.codesign.outputs.haveNotarizationUser }} codesignIdent: description: Codesigning identity value: ${{ steps.codesign.outputs.codesignIdent }} installerIdent: description: Codesigning identity for package installer value: ${{ steps.codesign.outputs.installerIdent }} codesignTeam: description: Codesigning team value: ${{ steps.codesign.outputs.codesignTeam }} runs: using: composite steps: - name: Check Runner Operating System 🏃‍♂️ if: runner.os != 'macOS' shell: bash run: | : Check Runner Operating System 🏃‍♂️ echo "setup-macos-codesigning action requires a macOS-based runner." exit 2 - name: macOS Codesigning ✍️ shell: zsh --no-rcs --errexit --pipefail {0} id: codesign env: MACOS_SIGNING_IDENTITY: ${{ inputs.codesignIdentity }} MACOS_SIGNING_IDENTITY_INSTALLER: ${{ inputs.installerIdentity}} MACOS_SIGNING_CERT: ${{ inputs.codesignCertificate }} MACOS_SIGNING_CERT_PASSWORD: ${{ inputs.certificatePassword }} MACOS_KEYCHAIN_PASSWORD: ${{ inputs.keychainPassword }} run: | : macOS Code Signing ✍️ if (( ${+RUNNER_DEBUG} )) setopt XTRACE if [[ ${MACOS_SIGNING_IDENTITY} && ${MACOS_SIGNING_IDENTITY_INSTALLER} && ${MACOS_SIGNING_CERT} ]] { print 'haveCodesignIdent=true' >> $GITHUB_OUTPUT local -r certificate_path="${RUNNER_TEMP}/build_certificate.p12" local -r keychain_path="${RUNNER_TEMP}/app-signing.keychain-db" print -n "${MACOS_SIGNING_CERT}" | base64 --decode --output=${certificate_path} : "${MACOS_KEYCHAIN_PASSWORD:="$(print ${RANDOM} | shasum | head -c 32)"}" print '::group::Keychain setup' security create-keychain -p "${MACOS_KEYCHAIN_PASSWORD}" ${keychain_path} security set-keychain-settings -lut 21600 ${keychain_path} security unlock-keychain -p "${MACOS_KEYCHAIN_PASSWORD}" ${keychain_path} security import "${certificate_path}" -P "${MACOS_SIGNING_CERT_PASSWORD}" -A \ -t cert -f pkcs12 -k ${keychain_path} \ -T /usr/bin/codesign -T /usr/bin/security -T /usr/bin/xcrun security set-key-partition-list -S 'apple-tool:,apple:' -k "${MACOS_KEYCHAIN_PASSWORD}" \ ${keychain_path} &> /dev/null security list-keychain -d user -s ${keychain_path} 'login-keychain' print '::endgroup::' local -r team_id="${${MACOS_SIGNING_IDENTITY##* }//(\(|\))/}" print "codesignIdent=${MACOS_SIGNING_IDENTITY}" >> $GITHUB_OUTPUT print "installerIdent=${MACOS_SIGNING_IDENTITY_INSTALLER}" >> $GITHUB_OUTPUT print "MACOS_KEYCHAIN_PASSWORD=${MACOS_KEYCHAIN_PASSWORD}" >> $GITHUB_ENV print "codesignTeam=${team_id}" >> $GITHUB_OUTPUT } else { print 'haveCodesignIdent=false' >> $GITHUB_OUTPUT print 'haveProvisioningProfile=false' >> $GITHUB_OUTPUT print 'haveNotarizationUser=false' >> $GITHUB_OUTPUT } - name: Provisioning Profile 👤 shell: zsh --no-rcs --errexit --pipefail {0} id: provisioning if: ${{ fromJSON(steps.codesign.outputs.haveCodesignIdent) }} env: MACOS_SIGNING_PROVISIONING_PROFILE: ${{ inputs.provisioningProfile }} run: | : Provisioning Profile 👤 if (( ${+RUNNER_DEBUG} )) setopt XTRACE if [[ "${MACOS_SIGNING_PROVISIONING_PROFILE}" ]] { print 'haveProvisioningProfile=true' >> $GITHUB_OUTPUT local -r profile_path="${RUNNER_TEMP}/build_profile.provisionprofile" print -n "${MACOS_SIGNING_PROVISIONING_PROFILE}" \ | base64 --decode --output="${profile_path}" print '::group::Provisioning Profile Setup' mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles security cms -D -i ${profile_path} -o ${RUNNER_TEMP}/build_profile.plist local -r uuid="$(plutil -extract UUID raw ${RUNNER_TEMP}/build_profile.plist)" local -r team_id="$(plutil -extract TeamIdentifier.0 raw -expect string ${RUNNER_TEMP}/build_profile.plist)" if [[ ${team_id} != '${{ steps.codesign.outputs.codesignTeam }}' ]] { print '::notice::Code Signing team in provisioning profile does not match certificate.' } cp ${profile_path} ~/Library/MobileDevice/Provisioning\ Profiles/${uuid}.provisionprofile print "provisioningProfileUUID=${uuid}" >> $GITHUB_OUTPUT print '::endgroup::' } else { print 'haveProvisioningProfile=false' >> $GITHUB_OUTPUT } - name: Notarization 🧑‍💼 id: notarization if: fromJSON(steps.codesign.outputs.haveCodesignIdent) shell: zsh --no-rcs --errexit --pipefail {0} env: MACOS_NOTARIZATION_USERNAME: ${{ inputs.notarizationUser }} MACOS_NOTARIZATION_PASSWORD: ${{ inputs.notarizationPassword }} run: | : Notarization 🧑‍💼 if (( ${+RUNNER_DEBUG} )) setopt XTRACE if [[ ${MACOS_NOTARIZATION_USERNAME} && ${MACOS_NOTARIZATION_PASSWORD} ]] { print 'haveNotarizationUser=true' >> $GITHUB_OUTPUT } else { print 'haveNotarizationUser=false' >> $GITHUB_OUTPUT } blur-filter-obs-plugin-1.1.0/.github/scripts/000077500000000000000000000000001477257264500210675ustar00rootroot00000000000000blur-filter-obs-plugin-1.1.0/.github/scripts/.Aptfile000066400000000000000000000001651477257264500224560ustar00rootroot00000000000000package 'cmake' package 'ccache' package 'git' package 'jq' package 'ninja-build', bin: 'ninja' package 'pkg-config' blur-filter-obs-plugin-1.1.0/.github/scripts/.Brewfile000066400000000000000000000001101477257264500226170ustar00rootroot00000000000000brew "ccache" brew "coreutils" brew "cmake" brew "jq" brew "xcbeautify" blur-filter-obs-plugin-1.1.0/.github/scripts/Build-Windows.ps1000066400000000000000000000043611477257264500242070ustar00rootroot00000000000000[CmdletBinding()] param( [ValidateSet('x64')] [string] $Target = 'x64', [ValidateSet('Debug', 'RelWithDebInfo', 'Release', 'MinSizeRel')] [string] $Configuration = 'RelWithDebInfo' ) $ErrorActionPreference = 'Stop' if ( $DebugPreference -eq 'Continue' ) { $VerbosePreference = 'Continue' $InformationPreference = 'Continue' } if ( $env:CI -eq $null ) { throw "Build-Windows.ps1 requires CI environment" } if ( ! ( [System.Environment]::Is64BitOperatingSystem ) ) { throw "A 64-bit system is required to build the project." } if ( $PSVersionTable.PSVersion -lt '7.2.0' ) { Write-Warning 'The obs-studio PowerShell build script requires PowerShell Core 7. Install or upgrade your PowerShell version: https://aka.ms/pscore6' exit 2 } function Build { trap { Pop-Location -Stack BuildTemp -ErrorAction 'SilentlyContinue' Write-Error $_ Log-Group exit 2 } $ScriptHome = $PSScriptRoot $ProjectRoot = Resolve-Path -Path "$PSScriptRoot/../.." $UtilityFunctions = Get-ChildItem -Path $PSScriptRoot/utils.pwsh/*.ps1 -Recurse foreach($Utility in $UtilityFunctions) { Write-Debug "Loading $($Utility.FullName)" . $Utility.FullName } Push-Location -Stack BuildTemp Ensure-Location $ProjectRoot $CmakeArgs = @('--preset', "windows-ci-${Target}") $CmakeBuildArgs = @('--build') $CmakeInstallArgs = @() if ( $DebugPreference -eq 'Continue' ) { $CmakeArgs += ('--debug-output') $CmakeBuildArgs += ('--verbose') $CmakeInstallArgs += ('--verbose') } $CmakeBuildArgs += @( '--preset', "windows-${Target}" '--config', $Configuration '--parallel' '--', '/consoleLoggerParameters:Summary', '/noLogo' ) $CmakeInstallArgs += @( '--install', "build_${Target}" '--prefix', "${ProjectRoot}/release/${Configuration}" '--config', $Configuration ) Log-Group "Configuring ${ProductName}..." Invoke-External cmake @CmakeArgs Log-Group "Building ${ProductName}..." Invoke-External cmake @CmakeBuildArgs Log-Group "Installing ${ProductName}..." Invoke-External cmake @CmakeInstallArgs Pop-Location -Stack BuildTemp Log-Group } Build blur-filter-obs-plugin-1.1.0/.github/scripts/Package-Windows.ps1000066400000000000000000000037441477257264500245070ustar00rootroot00000000000000[CmdletBinding()] param( [ValidateSet('x64')] [string] $Target = 'x64', [ValidateSet('Debug', 'RelWithDebInfo', 'Release', 'MinSizeRel')] [string] $Configuration = 'RelWithDebInfo' ) $ErrorActionPreference = 'Stop' if ( $DebugPreference -eq 'Continue' ) { $VerbosePreference = 'Continue' $InformationPreference = 'Continue' } if ( $env:CI -eq $null ) { throw "Package-Windows.ps1 requires CI environment" } if ( ! ( [System.Environment]::Is64BitOperatingSystem ) ) { throw "Packaging script requires a 64-bit system to build and run." } if ( $PSVersionTable.PSVersion -lt '7.2.0' ) { Write-Warning 'The packaging script requires PowerShell Core 7. Install or upgrade your PowerShell version: https://aka.ms/pscore6' exit 2 } function Package { trap { Write-Error $_ exit 2 } $ScriptHome = $PSScriptRoot $ProjectRoot = Resolve-Path -Path "$PSScriptRoot/../.." $BuildSpecFile = "${ProjectRoot}/buildspec.json" $UtilityFunctions = Get-ChildItem -Path $PSScriptRoot/utils.pwsh/*.ps1 -Recurse foreach( $Utility in $UtilityFunctions ) { Write-Debug "Loading $($Utility.FullName)" . $Utility.FullName } $BuildSpec = Get-Content -Path ${BuildSpecFile} -Raw | ConvertFrom-Json $ProductName = $BuildSpec.name $ProductVersion = $BuildSpec.version $OutputName = "${ProductName}-${ProductVersion}-windows-${Target}" $RemoveArgs = @{ ErrorAction = 'SilentlyContinue' Path = @( "${ProjectRoot}/release/${ProductName}-*-windows-*.zip" ) } Remove-Item @RemoveArgs Log-Group "Archiving ${ProductName}..." $CompressArgs = @{ Path = (Get-ChildItem -Path "${ProjectRoot}/release/${Configuration}" -Exclude "${OutputName}*.*") CompressionLevel = 'Optimal' DestinationPath = "${ProjectRoot}/release/${OutputName}.zip" Verbose = ($Env:CI -ne $null) } Compress-Archive -Force @CompressArgs Log-Group } Package blur-filter-obs-plugin-1.1.0/.github/scripts/build-macos000077500000000000000000000072331477257264500232210ustar00rootroot00000000000000#!/usr/bin/env zsh builtin emulate -L zsh setopt EXTENDED_GLOB setopt PUSHD_SILENT setopt ERR_EXIT setopt ERR_RETURN setopt NO_UNSET setopt PIPE_FAIL setopt NO_AUTO_PUSHD setopt NO_PUSHD_IGNORE_DUPS setopt FUNCTION_ARGZERO ## Enable for script debugging # setopt WARN_CREATE_GLOBAL # setopt WARN_NESTED_VAR # setopt XTRACE if (( ! ${+CI} )) { print -u2 -PR "%F{1} ✖︎ ${ZSH_ARGZERO:t:r} requires CI environment.%f" exit 1 } autoload -Uz is-at-least && if ! is-at-least 5.9; then print -u2 -PR "${CI:+::error::}%F{1}${funcstack[1]##*/}:%f Running on Zsh version %B${ZSH_VERSION}%b, but Zsh %B5.2%b is the minimum supported version. Upgrade Zsh to fix this issue." exit 1 fi TRAPZERR() { print -u2 -PR "::error::%F{1} ✖︎ script execution error%f" print -PR -e " Callstack: ${(j:\n :)funcfiletrace} " exit 2 } build() { if (( ! ${+SCRIPT_HOME} )) typeset -g SCRIPT_HOME=${ZSH_ARGZERO:A:h} local host_os='macos' local project_root=${SCRIPT_HOME:A:h:h} local buildspec_file=${project_root}/buildspec.json fpath=("${SCRIPT_HOME}/utils.zsh" ${fpath}) autoload -Uz log_group log_info log_error log_output check_macos setup_ccache if [[ ! -r ${buildspec_file} ]] { log_error \ 'No buildspec.json found. Please create a build specification for your project.' return 2 } local -i debug=0 local config='RelWithDebInfo' local -r -a _valid_configs=(Debug RelWithDebInfo Release MinSizeRel) local -i codesign=0 local -a args while (( # )) { case ${1} { -c|--config) if (( # == 1 )) || [[ ${2:0:1} == '-' ]] { log_error "Missing value for option %B${1}%b" log_output ${_usage} exit 2 } ;; } case ${1} { --) shift; args+=($@); break ;; -c|--config) if (( ! ${_valid_configs[(Ie)${2}]} )) { log_error "Invalid value %B${2}%b for option %B${1}%b" exit 2 } config=${2} shift 2 ;; -s|--codesign) codesign=1; shift ;; --debug) debug=1; shift ;; *) log_error "Unknown option: %B${1}%b"; exit 2 ;; } } set -- ${(@)args} check_macos local product_name local product_version read -r product_name product_version <<< \ "$(jq -r '. | {name, version} | join(" ")' ${buildspec_file})" pushd ${project_root} local -a cmake_args=() local -a cmake_build_args=(--build) local -a cmake_install_args=(--install) if (( debug )) cmake_args+=(--debug-output) cmake_args+=(--preset 'macos-ci') typeset -gx NSUnbufferedIO=YES typeset -gx CODESIGN_IDENT="${CODESIGN_IDENT:--}" if (( codesign )) && [[ -z ${CODESIGN_TEAM} ]] { typeset -gx CODESIGN_TEAM="$(print "${CODESIGN_IDENT}" | /usr/bin/sed -En 's/.+\((.+)\)/\1/p')" } log_group "Configuring ${product_name}..." cmake -S ${project_root} ${cmake_args} log_group "Building ${product_name}..." run_xcodebuild() { if (( debug )) { xcodebuild ${@} } else { if [[ ${GITHUB_EVENT_NAME} == push ]] { xcodebuild ${@} 2>&1 | xcbeautify --renderer terminal } else { xcodebuild ${@} 2>&1 | xcbeautify --renderer github-actions } } } local -a build_args=( ONLY_ACTIVE_ARCH=NO -arch arm64 -arch x86_64 -project ${product_name}.xcodeproj -target ${product_name} -destination "generic/platform=macOS,name=Any Mac" -configuration ${config} -parallelizeTargets -hideShellScriptEnvironment build ) pushd build_macos run_xcodebuild ${build_args} popd log_group "Installing ${product_name}..." cmake --install build_macos --config ${config} --prefix "${project_root}/release/${config}" popd log_group } build ${@} blur-filter-obs-plugin-1.1.0/.github/scripts/build-ubuntu000077500000000000000000000152551477257264500234440ustar00rootroot00000000000000#!/usr/bin/env zsh builtin emulate -L zsh setopt EXTENDED_GLOB setopt PUSHD_SILENT setopt ERR_EXIT setopt ERR_RETURN setopt NO_UNSET setopt PIPE_FAIL setopt NO_AUTO_PUSHD setopt NO_PUSHD_IGNORE_DUPS setopt FUNCTION_ARGZERO ## Enable for script debugging # setopt WARN_CREATE_GLOBAL # setopt WARN_NESTED_VAR # setopt XTRACE autoload -Uz is-at-least && if ! is-at-least 5.2; then print -u2 -PR "${CI:+::error::}%F{1}${funcstack[1]##*/}:%f Running on Zsh version %B${ZSH_VERSION}%b, but Zsh %B5.2%b is the minimum supported version. Upgrade Zsh to fix this issue." exit 1 fi TRAPZERR() { if (( ${_loglevel:-3} > 2 )) { print -u2 -PR "${CI:+::error::}%F{1} ✖︎ script execution error%f" print -PR -e " Callstack: ${(j:\n :)funcfiletrace} " } exit 2 } build() { if (( ! ${+SCRIPT_HOME} )) typeset -g SCRIPT_HOME=${ZSH_ARGZERO:A:h} local host_os='ubuntu' local project_root=${SCRIPT_HOME:A:h:h} local buildspec_file=${project_root}/buildspec.json fpath=("${SCRIPT_HOME}/utils.zsh" ${fpath}) autoload -Uz log_group log_info log_error log_output set_loglevel check_ubuntu setup_ccache if [[ ! -r ${buildspec_file} ]] { log_error \ 'No buildspec.json found. Please create a build specification for your project.' return 2 } local -i debug=0 typeset -g -a skips=() local -i verbosity=1 local -r _version='2.0.0' local -r -a _valid_targets=( ubuntu-x86_64 ) local target local config='RelWithDebInfo' local -r -a _valid_configs=(Debug RelWithDebInfo Release MinSizeRel) local -i codesign=0 local -r -a _valid_generators=(Ninja 'Unix Makefiles') local generator='Ninja' local -r _usage_host=" %F{yellow} Additional options for Linux builds%f ----------------------------------------------------------------------------- %B--generator%b Specify build system to generate Available generators: - Ninja - Unix Makefiles" local -i print_config=0 local -r _usage=" Usage: %B${functrace[1]%:*}%b