Initial implementation of blender benchmark addon
Just some glue logic to query progress and results from benchmark. Needed to move files around, so oth standalone and addon are happy.
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
import re
|
||||
|
||||
from foundation import util
|
||||
from . import util
|
||||
|
||||
|
||||
class Stats:
|
||||
def __init__(self):
|
||||
# Pepare some regex for parsing
|
||||
self.re_path_tracing = re.compile(
|
||||
".*Rendered ([0-9]+)/([0-9]+) Tiles" +
|
||||
".*(Rendered|Path Tracing Tile) ([0-9]+)/([0-9]+)( Tiles)?" +
|
||||
"(, Sample ([0-9]+)\/([0-9]+))?$")
|
||||
self.re_total_render_time = re.compile(
|
||||
".*Total render time: ([0-9]+(\.[0-9]+)?)")
|
||||
@@ -35,8 +35,8 @@ class Stats:
|
||||
# Current tile progress.
|
||||
match = self.re_path_tracing.match(line)
|
||||
if match:
|
||||
self.current_tiles = int(match.group(1))
|
||||
self.total_tiles = int(match.group(2))
|
||||
self.current_tiles = int(match.group(2))
|
||||
self.total_tiles = int(match.group(3))
|
||||
# Total render time.
|
||||
match = self.re_total_render_time.match(line)
|
||||
if match:
|
||||
|
Reference in New Issue
Block a user