Cleanup: remove "-noaudio" argument in background mode

This is no longer needed as background mode implies -noaudio.
This commit is contained in:
Campbell Barton 2024-02-14 00:13:38 +11:00
parent 7c90018f23
commit 2119d271e0
53 changed files with 52 additions and 67 deletions

@ -535,7 +535,7 @@ check_spelling_shaders: .FORCE
"$(BLENDER_DIR)/source/"
check_descriptions: .FORCE
@$(BLENDER_BIN) --background -noaudio --factory-startup --python \
@$(BLENDER_BIN) --background --factory-startup --python \
"$(BLENDER_DIR)/tools/check_source/check_descriptions.py"
check_deprecated: .FORCE
@ -598,7 +598,7 @@ format: .FORCE
doc_py: .FORCE
@ASAN_OPTIONS=halt_on_error=0:${ASAN_OPTIONS} \
$(BLENDER_BIN) \
--background -noaudio --factory-startup \
--background --factory-startup \
--python doc/python_api/sphinx_doc_gen.py
@sphinx-build -b html -j $(NPROCS) doc/python_api/sphinx-in doc/python_api/sphinx-out
@echo "docs written into: '$(BLENDER_DIR)/doc/python_api/sphinx-out/index.html'"
@ -609,7 +609,7 @@ doc_doxy: .FORCE
doc_dna: .FORCE
@$(BLENDER_BIN) \
--background -noaudio --factory-startup \
--background --factory-startup \
--python doc/blender_file_format/BlendFileDnaExporter_25.py
@echo "docs written into: '$(BLENDER_DIR)/doc/blender_file_format/dna.html'"

@ -26,7 +26,7 @@ exit /b 1
:detect_blender_done
%BLENDER_BIN% ^
--background -noaudio --factory-startup ^
--background --factory-startup ^
--python %BLENDER_DIR%/doc/python_api/sphinx_doc_gen.py
"%SPHINX_BIN%" -b html %SPHINXOPTS% %O% %SOURCEDIR% %BUILDDIR%

@ -363,15 +363,15 @@ class DNACatalogHTML:
def usage():
print("\nUsage: \n\tblender2.5 --background -noaudio --python BlendFileDnaExporter_25.py [-- [options]]")
print("\nUsage: \n\tblender2.5 --background --python BlendFileDnaExporter_25.py [-- [options]]")
print("Options:")
print("\t--dna-keep-blend: doesn't delete the produced blend file DNA export to html")
print("\t--dna-debug: sets the logging level to DEBUG (lots of additional info)")
print("\t--dna-versioned saves version information in the html and blend filenames")
print("\t--dna-overwrite-css overwrite dna.css, useful when modifying css in the script")
print("Examples:")
print("\tdefault: % blender2.5 --background -noaudio --python BlendFileDnaExporter_25.py")
print("\twith options: % blender2.5 --background -noaudio --python BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug\n")
print("\tdefault: % blender2.5 --background --python BlendFileDnaExporter_25.py")
print("\twith options: % blender2.5 --background --python BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug\n")
######################################################

@ -16,14 +16,14 @@ Below you have the help message with a list of options you can use.
Usage:
blender2.5 --background -noaudio --python BlendFileDnaExporter_25.py [-- [options]]
blender2.5 --background --python BlendFileDnaExporter_25.py [-- [options]]
Options:
--dna-keep-blend: doesn't delete the produced blend file DNA export to html
--dna-debug: sets the logging level to DEBUG (lots of additional info)
--dna-versioned saves version information in the html and blend filenames
--dna-overwrite-css overwrite dna.css, useful when modifying css in the script
Examples:
default: % blender2.5 --background -noaudio --python BlendFileDnaExporter_25.py
with options: % blender2.5 --background -noaudio --python BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug
default: % blender2.5 --background --python BlendFileDnaExporter_25.py
with options: % blender2.5 --background --python BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug

@ -1,7 +1,7 @@
..
This document is appended to the auto generated BMesh API doc to avoid clogging up the C files with details.
to test this run:
./blender.bin -b -noaudio -P doc/python_api/sphinx_doc_gen.py -- \
./blender.bin -b -P doc/python_api/sphinx_doc_gen.py -- \
--partial bmesh* ; cd doc/python_api ; sphinx-build sphinx-in sphinx-out ; cd ../../

@ -7,7 +7,7 @@ API dump in RST files
---------------------
Run this script from Blender's root path once you have compiled Blender
blender --background --factory-startup -noaudio --python doc/python_api/sphinx_doc_gen.py
blender --background --factory-startup --python doc/python_api/sphinx_doc_gen.py
This will generate python files in doc/python_api/sphinx-in/
providing ./blender is or links to the blender executable
@ -239,12 +239,12 @@ BPY_LOGGER.setLevel(logging.DEBUG)
"""
# for quick rebuilds
rm -rf /b/doc/python_api/sphinx-* && \
./blender -b -noaudio --factory-startup -P doc/python_api/sphinx_doc_gen.py && \
./blender -b --factory-startup -P doc/python_api/sphinx_doc_gen.py && \
sphinx-build doc/python_api/sphinx-in doc/python_api/sphinx-out
or
./blender -b -noaudio --factory-startup -P doc/python_api/sphinx_doc_gen.py -- -f -B
./blender -b --factory-startup -P doc/python_api/sphinx_doc_gen.py -- -f -B
"""
# Switch for quick testing so doc-builds don't take so long.

@ -76,7 +76,7 @@ for blend in icons_blend:
output_dir = os.path.join(BASEDIR, "icons")
files_old = set(names_and_time_from_path(output_dir))
cmd = (
blender_bin, "--background", "--factory-startup", "-noaudio",
blender_bin, "--background", "--factory-startup",
blend,
"--python", os.path.join(BASEDIR, "blender_icons_geom.py"),
"--",

@ -71,7 +71,7 @@ datatoc_icon_split_py = os.path.join(BASEDIR, "..", "..", "source", "blender", "
# create .dat pixmaps (which are stored in git)
cmd = (
blender_bin, "--background", "--factory-startup", "-noaudio",
blender_bin, "--background", "--factory-startup",
"--python", datatoc_icon_split_py, "--",
"--image=" + os.path.join(BASEDIR, "blender_icons16.png"),
"--output=" + os.path.join(BASEDIR, "blender_icons16"),
@ -85,7 +85,7 @@ cmd = (
run(cmd, env=env)
cmd = (
blender_bin, "--background", "--factory-startup", "-noaudio",
blender_bin, "--background", "--factory-startup",
"--python", datatoc_icon_split_py, "--",
"--image=" + os.path.join(BASEDIR, "blender_icons32.png"),
"--output=" + os.path.join(BASEDIR, "blender_icons32"),

@ -105,7 +105,6 @@ class WM_OT_previews_batch_generate(Operator):
bpy.app.binary_path,
"--background",
"--factory-startup",
"-noaudio",
]
if self.use_trusted:
cmd.append("--enable-autoexec")
@ -215,7 +214,6 @@ class WM_OT_previews_batch_clear(Operator):
bpy.app.binary_path,
"--background",
"--factory-startup",
"-noaudio",
]
if self.use_trusted:
cmd.append("--enable-autoexec")

@ -8,7 +8,7 @@ This script dices up PNG into small files to store in version control.
Example:
./blender.bin \
--background -noaudio \
--background \
--python ./release/datafiles/icon_dice.py -- \
--image=./release/datafiles/blender_icons16.png \
--output=./release/datafiles/blender_icons16

@ -11,7 +11,7 @@ Typical line in the input file (elements in [] are optional).
[comment *] ToolSettings.snap_align_rotation -> use_snap_align_rotation: boolean [Align rotation with the snapping target]
Geterate output format from blender run this:
./blender.bin --background -noaudio --python ./scripts/modules/rna_info.py 2> source/blender/makesrna/rna_cleanup/out.txt
./blender.bin --background --python ./scripts/modules/rna_info.py 2> source/blender/makesrna/rna_cleanup/out.txt
"""

@ -53,7 +53,7 @@ endif()
# Standard Blender arguments for running tests.
# Specify exit code so that if a Python script error happens, the test fails.
set(TEST_BLENDER_EXE_PARAMS --background -noaudio --factory-startup --debug-memory --debug-exit-on-error --python-exit-code 1)
set(TEST_BLENDER_EXE_PARAMS --background --factory-startup --debug-memory --debug-exit-on-error --python-exit-code 1)
# Python CTests
if(WITH_BLENDER AND WITH_PYTHON AND NOT WITH_PYTHON_MODULE)

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
"""
./blender.bin --background -noaudio --factory-startup --python tests/python/bl_alembic_io_test.py -- --testdir /path/to/lib/tests/alembic
./blender.bin --background --factory-startup --python tests/python/bl_alembic_io_test.py -- --testdir /path/to/lib/tests/alembic
"""
import math

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
"""
blender -b -noaudio --factory-startup --python tests/python/bl_animation_armature.py
blender -b --factory-startup --python tests/python/bl_animation_armature.py
"""
import unittest

@ -9,7 +9,7 @@ import sys
from rna_prop_ui import rna_idprop_quote_path
"""
blender -b -noaudio --factory-startup --python tests/python/bl_animation_drivers.py -- --testdir /path/to/lib/tests/animation
blender -b --factory-startup --python tests/python/bl_animation_drivers.py -- --testdir /path/to/lib/tests/animation
"""

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
"""
blender -b -noaudio --factory-startup --python tests/python/bl_animation_fcurves.py -- --testdir /path/to/lib/tests/animation
blender -b --factory-startup --python tests/python/bl_animation_fcurves.py -- --testdir /path/to/lib/tests/animation
"""
import pathlib

@ -9,7 +9,7 @@ import sys
from math import radians
"""
blender -b -noaudio --factory-startup --python tests/python/bl_animation_keyframing.py -- --testdir /path/to/lib/tests/animation
blender -b --factory-startup --python tests/python/bl_animation_keyframing.py -- --testdir /path/to/lib/tests/animation
"""

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_blendfile_io.py
# ./blender.bin --background --python tests/python/bl_blendfile_io.py
import bpy
import os
import sys

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_blendfile_liblink.py
# ./blender.bin --background --python tests/python/bl_blendfile_liblink.py
import bpy
import os
import sys

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_blendfile_library_overrides.py -- --output-dir=/tmp/
# ./blender.bin --background --python tests/python/bl_blendfile_library_overrides.py -- --output-dir=/tmp/
import pathlib
import bpy
import sys

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_blendfile_versioning.py ..
# ./blender.bin --background --python tests/python/bl_blendfile_versioning.py ..
import bpy
import os
import sys

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
"""
./blender.bin --background -noaudio --factory-startup --python tests/python/bl_constraints.py -- --testdir /path/to/lib/tests/constraints
./blender.bin --background --factory-startup --python tests/python/bl_constraints.py -- --testdir /path/to/lib/tests/constraints
"""
import pathlib

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_id_management.py -- --verbose
# ./blender.bin --background --python tests/python/bl_id_management.py -- --verbose
import bpy
import unittest
import random

@ -15,7 +15,6 @@ def get_arguments(filepath, output_filepath):
args = [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: GPL-2.0-or-later
# ./blender.bin --background -noaudio --factory-startup --python tests/python/bl_keymap_validate.py
# ./blender.bin --background --factory-startup --python tests/python/bl_keymap_validate.py
#
"""

@ -5,7 +5,7 @@
# simple script to enable all addons, and disable
"""
./blender.bin --background -noaudio --factory-startup --python tests/python/bl_load_addons.py
./blender.bin --background --factory-startup --python tests/python/bl_load_addons.py
"""
import bpy

@ -5,7 +5,7 @@
# simple script to enable all addons, and disable
"""
./blender.bin --background -noaudio --factory-startup --python tests/python/bl_load_py_modules.py
./blender.bin --background --factory-startup --python tests/python/bl_load_py_modules.py
"""
import bpy

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: GPL-2.0-or-later
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_bpy_driver_secure_eval.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_bpy_driver_secure_eval.py -- --verbose
import bpy
import unittest
import builtins

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_bpy_path.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_bpy_path.py -- --verbose
import unittest

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_bpy_utils_units.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_bpy_utils_units.py -- --verbose
import unittest
from bpy.utils import units

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_idprop.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_idprop.py -- --verbose
import bpy
import idprop
import unittest

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: GPL-2.0-or-later
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_idprop_datablock.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_idprop_datablock.py -- --verbose
import contextlib
import inspect

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_mathutils.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_mathutils.py -- --verbose
import unittest
from mathutils import Matrix, Vector, Quaternion, Euler
from mathutils import kdtree, geometry

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_prop_array.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_prop_array.py -- --verbose
import bpy
from bpy.props import (
BoolVectorProperty,

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --python tests/python/bl_pyapi_text.py -- --verbose
# ./blender.bin --background --python tests/python/bl_pyapi_text.py -- --verbose
import bpy
import unittest

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
"""
blender -b -noaudio --factory-startup --python tests/python/bl_rigging_symmetrize.py -- --testdir /path/to/lib/tests/animation
blender -b --factory-startup --python tests/python/bl_rigging_symmetrize.py -- --testdir /path/to/lib/tests/animation
"""
import pathlib

@ -2,7 +2,7 @@
#
# SPDX-License-Identifier: Apache-2.0
# ./blender.bin --background -noaudio --factory-startup --python tests/python/bl_rna_defaults.py
# ./blender.bin --background --factory-startup --python tests/python/bl_rna_defaults.py
import bpy

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
# Use for validating our manual interlinking.
# ./blender.bin --background -noaudio --python tests/python/bl_rna_manual_reference.py
# ./blender.bin --background --python tests/python/bl_rna_manual_reference.py
#
# 1) test_data() -- ensure the data we have is correct format
# 2) test_lookup_coverage() -- ensure that we have lookups for _every_ RNA path and all patterns are used.

@ -4,7 +4,7 @@
# run this script in the game engine.
# or on the command line with...
# ./blender.bin --background -noaudio --python tests/python/bl_rst_completeness.py
# ./blender.bin --background --python tests/python/bl_rst_completeness.py
'''
filepath = "/src/blender/tests/python/bl_rst_completeness.py"
exec(compile(open(filepath).read(), filepath, 'exec'))

@ -23,12 +23,12 @@ execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${TEST_OUT_DIR})
# all calls to blender use this
if(APPLE)
if(${CMAKE_GENERATOR} MATCHES "Xcode")
set(TEST_BLENDER_EXE_PARAMS --background -noaudio --factory-startup --debug-memory --debug-exit-on-error)
set(TEST_BLENDER_EXE_PARAMS --background --factory-startup --debug-memory --debug-exit-on-error)
else()
set(TEST_BLENDER_EXE_PARAMS --background -noaudio --factory-startup --debug-memory --debug-exit-on-error --env-system-scripts ${CMAKE_SOURCE_DIR}/scripts)
set(TEST_BLENDER_EXE_PARAMS --background --factory-startup --debug-memory --debug-exit-on-error --env-system-scripts ${CMAKE_SOURCE_DIR}/scripts)
endif()
else()
set(TEST_BLENDER_EXE_PARAMS --background -noaudio --factory-startup --debug-memory --debug-exit-on-error --env-system-scripts ${CMAKE_SOURCE_DIR}/scripts)
set(TEST_BLENDER_EXE_PARAMS --background --factory-startup --debug-memory --debug-exit-on-error --env-system-scripts ${CMAKE_SOURCE_DIR}/scripts)
endif()
# for testing with valgrind prefix: valgrind --track-origins=yes --error-limit=no

@ -19,7 +19,6 @@ except ImportError:
def get_arguments(filepath, output_filepath):
return [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -23,7 +23,6 @@ ENABLE_REALTIME_COMPOSITOR_SCRIPT = "import bpy; " \
def get_arguments(filepath, output_filepath):
return [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -68,7 +68,6 @@ def get_arguments(filepath, output_filepath):
args = [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -84,7 +84,6 @@ def get_gpu_device_type(blender):
# TODO: This always fails.
command = [
blender,
"-noaudio",
"--background",
"--factory-startup",
"--python",
@ -104,7 +103,6 @@ def get_gpu_device_type(blender):
def get_arguments(filepath, output_filepath):
return [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -103,7 +103,6 @@ if inside_blender:
def get_gpu_device_type(blender):
command = [
blender,
"-noaudio",
"--background",
"--factory-startup",
"--python",
@ -123,7 +122,6 @@ def get_gpu_device_type(blender):
def get_arguments(filepath, output_filepath):
return [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -60,7 +60,6 @@ class AbstractBlenderRunnerTest(unittest.TestCase):
command = [
self.blender,
'--background',
'-noaudio',
'--factory-startup',
'--enable-autoexec',
'--debug-memory',

@ -3,7 +3,7 @@
# SPDX-License-Identifier: GPL-2.0-or-later
# Used for generating API diffs between releases
# ./blender.bin --background -noaudio --python tests/python/rna_info_dump.py
# ./blender.bin --background --python tests/python/rna_info_dump.py
import bpy

@ -15,7 +15,6 @@ def get_arguments(filepath, output_filepath):
args = [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -38,7 +38,6 @@ if inside_blender:
def get_arguments(filepath, output_filepath):
return [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -17,7 +17,7 @@ execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${TEST_OUT_DIR})
# endif()
# for testing with valgrind prefix: valgrind --track-origins=yes --error-limit=no
set(TEST_BLENDER_EXE $<TARGET_FILE:blender> --background -noaudio --factory-startup --debug-memory --debug-exit-on-error --env-system-scripts ${CMAKE_SOURCE_DIR}/scripts)
set(TEST_BLENDER_EXE $<TARGET_FILE:blender> --background --factory-startup --debug-memory --debug-exit-on-error --env-system-scripts ${CMAKE_SOURCE_DIR}/scripts)
# ------------------------------------------------------------------------------

@ -37,7 +37,6 @@ if inside_blender:
def get_arguments(filepath, output_filepath):
return [
"--background",
"-noaudio",
"--factory-startup",
"--enable-autoexec",
"--debug-memory",

@ -6,7 +6,7 @@
"""
this script updates XML themes once new settings are added
./blender.bin --background -noaudio --python tools/check_source/check_descriptions.py
./blender.bin --background --python tools/check_source/check_descriptions.py
"""
import bpy

@ -136,7 +136,6 @@ def benchmarkFile(blender, blendfile, stats):
# Configure command for the current file.
command = (blender,
"--background",
"-noaudio",
"--factory-startup",
blendfile,
"--engine", "CYCLES",