mirror of
https://github.com/blender/blender
synced 2026-09-29 04:37:17 +03:00
Tests: Disable --cycles-device arguments on non-Cycles tests
This commit reworks the RenderReport base class to avoid adding `--cycles-device` device arguments to non Cycles tests. This reduces some warnings that can show up with EEVEE and Workbench tests that accidentally used these arguments. Pull Request: https://projects.blender.org/blender/blender/pulls/133724
This commit is contained in:
parent
d62c143ab7
commit
ea7d07098b
4 changed files with 38 additions and 30 deletions
|
|
@ -135,10 +135,10 @@ class CyclesReport(render_report.Report):
|
|||
def __init__(self, title, output_dir, oiiotool, device=None, blocklist=[], osl=False):
|
||||
# Split device name in format "<device_type>[-<RT>]" into individual
|
||||
# tokens, setting the RT suffix to an empty string if its not specified.
|
||||
device, suffix = (device.split("-") + [""])[:2]
|
||||
self.device, suffix = (device.split("-") + [""])[:2]
|
||||
self.use_hwrt = (suffix == "RT")
|
||||
|
||||
super().__init__(title, output_dir, oiiotool, device, blocklist)
|
||||
super().__init__(title, output_dir, oiiotool, self.device, blocklist)
|
||||
|
||||
if self.use_hwrt:
|
||||
self.title = self.title + " RT"
|
||||
|
|
@ -151,6 +151,9 @@ class CyclesReport(render_report.Report):
|
|||
def _get_render_arguments(self, arguments_cb, filepath, base_output_filepath):
|
||||
return arguments_cb(filepath, base_output_filepath, self.use_hwrt, self.osl)
|
||||
|
||||
def _get_arguments_suffix(self):
|
||||
return ['--', '--cycles-device', self.device] if self.device else []
|
||||
|
||||
|
||||
def get_arguments(filepath, output_filepath, use_hwrt=False, osl=False):
|
||||
dirname = os.path.dirname(filepath)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue