Skip to content

Commit

Permalink
Update generate_gif to work on older python3
Browse files Browse the repository at this point in the history
  • Loading branch information
scottbez1 committed Jan 14, 2024
1 parent e55986e commit 9147a37
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion 3d/scripts/generate_gif.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,17 @@ def render_frame(i):

def render_flaps(input_file, output_folder, variables):
def render_flap(i):
merged_variables = {}
merged_variables.update(variables)
merged_variables.update({'render_flap_index': i})
openscad.run(
input_file,
os.path.join(output_folder, 'frames', 'frame_%05d.png' % (i)),
output_size = [600,800],
camera_translation = [-5, 0, -9],
camera_rotation = [90, 0, 180],
camera_distance = 500,
variables = variables | {'render_flap_index': i},
variables = merged_variables,
colorscheme = 'Starnight',
)
pool = Pool()
Expand Down

0 comments on commit 9147a37

Please sign in to comment.