File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import os
22from enum import Enum
33from functools import partial
4- from typing import Dict
4+ from typing import Dict , Union
55from musicalgestures ._video import MgVideo
66from musicalgestures ._utils import ffmpeg_cmd , get_length , generate_outfilename
77
@@ -96,7 +96,7 @@ class Mg360Video(MgVideo):
9696 def __init__ (
9797 self ,
9898 filename : str ,
99- projection : str | Projection ,
99+ projection : Union [ str , Projection ] ,
100100 camera : str = None ,
101101 ** kwargs ,
102102 ):
@@ -122,7 +122,7 @@ def __init__(
122122
123123 def convert_projection (
124124 self ,
125- target_projection : Projection | str ,
125+ target_projection : Union [ Projection , str ] ,
126126 options : Dict [str , str ] = None ,
127127 print_cmd : bool = False ,
128128 ):
@@ -174,7 +174,7 @@ def convert_projection(
174174 self .filename = output_name
175175 self .projection = target_projection
176176
177- def _parse_projection (self , projection : str | Projection ):
177+ def _parse_projection (self , projection : Union [ str , Projection ] ):
178178 """
179179 Parse projection type.
180180 Args:
You can’t perform that action at this time.
0 commit comments