Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make range to output np.array - always #4351

Merged
merged 3 commits into from
Sep 14, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 3 additions & 8 deletions nodes/vector/interpolation_mk3.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@

def make_range(number, end_point):
if number in {0, 1, 2} or number < 0:
return [0.0]
return np.linspace(0.0, 1.0, num=number, endpoint=end_point).tolist()
return np.array([0.0])
return np.linspace(0.0, 1.0, num=number, endpoint=end_point)



Expand Down Expand Up @@ -170,9 +170,4 @@ def process_data(self, params):
return verts_out, tanget_out, norm_tanget_out


def register():
bpy.utils.register_class(SvInterpolationNodeMK3)


def unregister():
bpy.utils.unregister_class(SvInterpolationNodeMK3)
register, unregister = bpy.utils.register_classes_factory([SvInterpolationNodeMK3])