Git Product home page Git Product logo

sverchok-extra's Introduction

README

   _____                     __          __         ______     __            
  / ___/   _____  __________/ /_  ____  / /__      / ____/  __/ /__________ _
  \__ \ | / / _ \/ ___/ ___/ __ \/ __ \/ //_/_____/ __/ | |/_/ __/ ___/ __ `/
 ___/ / |/ /  __/ /  / /__/ / / / /_/ / ,< /_____/ /____>  </ /_/ /  / /_/ / 
/____/|___/\___/_/   \___/_/ /_/\____/_/|_|     /_____/_/|_|\__/_/   \__,_/
initialized.

This is an addon for Blender, which was desined to extend he Sverchok addon by features, that could not be included into Sverchok because it would add new dependencies and make installation of Sverchok core too complicated for most usages.

At the moment, all the most interesting and usable stuff is moved into Sverchok addon itself. Sverchok-Extra still contains some nodes that can be interesting in certain applications. Sverchok-Extra will continue to exist as a sandbox, or a nursery, for new Sverchok nodes. If you have an idea for a node, which is too complex to be a scripted node, but too young, or uses some new dependency, and you doubt it will be useful in Sverchok core in it's current state — put it into Sverchok-Extra.

NOTE: Sverchok-Extra contains nodes that are in early development stage; there are many things that can change in future. So, please do not depend on this addon in your production projects yet. But you can already test it and play with it.

The documentation is currently almost absent, partly because of amount of changes that might occur at any time at this stage of development.

Features

At the moment, this addon includes the following nodes for Sverchok:

  • Surface Extra category:
    • Smooth Bivariate Spline (uses SciPy)
    • Implicit Surface Solver / Wrap (no dependencies, experimental node)
    • Surface Curvature Lines (uses SciPy)
  • Field Extra category (please refer to the wiki page about used concept of the field):
    • Vector Field Lines on a Surface (uses SciPy)
  • Data category:
    • Spreadsheet
    • Data Item
  • Matrix Extra category:
    • Project Matrix on Plane
  • Solid Extra category:
    • Solid Waffle
  • Spatial Extra category:
    • Delanuay 3D on Surface
    • Delaunay Mesh - add vertices to existing mesh by use of Delaunay triangulation
  • SDF Primitives category (uses SDF):
    • SDF Box
    • SDF Cylinder
    • ..and many more
  • SDF Operations category (uses SDF):
    • SDF Translate
    • SDF Scale
    • SDF Rotate
    • SDF Orient
    • SDF General Transform
    • SDF Boolean
    • SDF Blend
    • SDF Linear Transition
    • SDF Radial Transition
    • SDF Dilate / Erode
    • SDF Shell
    • SDF Twist
    • SDF Linear Bend
    • SDF Slice
    • SDF Exrtude
    • SDF Extrude To
    • SDF Revolve
    • SDF Generate (specialized version of Marching Cubes)

There will be more.

Installation

At the moment, Sverchok-Extra does not have any specific dependencies, except for Sverchok and it's dependencies. Sverchok-Extra currently can use SciPy, which can be installed as a dependency for Sverchok. Please refer to Sverchok documentation about how to install dependencies.

After you installed all of dependencies you've decided to install, installation of Sverchok-Extra by itself is simple:

  • Download Sverchok-Extra zip archive from GitHub
  • In Blender, go to User Preferences > Addons > install from file > choose zip-archive > activate flag beside Sverchok-Extra.
  • Save preferences, if you want to enable the addon permanently.

LICENSE: GPL-3.

sverchok-extra's People

Contributors

durman avatar nortikin avatar portnov avatar ranska avatar satabol avatar vicdoval avatar zeffii avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sverchok-extra's Issues

Error when trying to enable

When I tick on the flag to enable the add-on I get the following error:

Traceback (most recent call last):
  File "C:\Program Files\Blender Foundation\Blender 2.81\2.81\scripts\modules\addon_utils.py", line 351, in enable
    mod = __import__(module_name)
  File "C:\Users\Alberto\AppData\Roaming\Blender Foundation\Blender\2.81\scripts\addons\sverchok-extra-master\__init__.py", line 24, in <module>
    from sverchok.menu import SverchNodeItem, node_add_operators, SverchNodeCategory, register_node_panels, unregister_node_panels, unregister_node_add_operators, register_extra_category_provider
ImportError: cannot import name 'register_extra_category_provider' from 'sverchok.menu' (C:\Program Files\Blender Foundation\Blender 2.81\2.81\scripts\addons_contrib\sverchok\menu.py)

I haven't installed all the dependencies of sverchok-extra because I am interested to try just a couple of nodes at the moment but I don't think that this is related.

I am using Blender 2.81a.

Icons

Nodes which are to be moved to Sverchok have to have specific icons

No issue.

Just wanted to say Thank you. For all you and Nikitron and all the developers and contributors to Sverchok, Sverchok Extra are contributing to these awesome tools.

I've used it since Blender 2.7x.

Awesome tools.

Your work, your help, your patience and persistence is MUCH appreciated.

Thank. you.

Very much.

SDF Python Module Traceback Issue

After installing the SDF python module enabling sverchok-extra gives a traceback but removing it solves this problem.

Blender Version: 3.6.9 LTS

Install from sverchok and Update dependencies

Two proposals:

1 A feature to Install Sverchok-Extra from Sverchok Prefences panel (one button to install and maybe another to go to the sv-extra preferences)

2 An option "check for updates" and update (for add-on and for dependencies) from the Sverchok-extra panel

Sverchok Extra cannot start (after commit 3059d50)

After 3059d50 (""Voronoi on Mesh" node.", 2020-11-16), Sverchok Extra cannot start and throws an error:

Sverchok addon is not available. Sverchok-Extra will not work. 2020-11-22 15:56:13,536 [INFO] sverchok_extra.dependencies: Pygalmesh package is not available. Corresponding nodes will not be available Traceback (most recent call last): File "D:\BlenderBin\blender-2.90.1-windows64\2.90\scripts\modules\addon_utils.py", line 351, in enable mod = __import__(module_name) File "C:\Users\rendetto\AppData\Roaming\Blender Foundation\Blender\2.90\scripts\addons\sverchok-extra-master\__init__.py", line 71, in <module> imported_modules = [icons] + make_node_list() File "C:\Users\rendetto\AppData\Roaming\Blender Foundation\Blender\2.90\scripts\addons\sverchok-extra-master\__init__.py", line 67, in make_node_list module = importlib.import_module(f".{module_name}", base_name) File "D:\BlenderBin\blender-2.90.1-windows64\2.90\python\lib\importlib\__init__.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "C:\Users\rendetto\AppData\Roaming\Blender Foundation\Blender\2.90\scripts\addons\sverchok-extra-master\nodes\spatial\voronoi_on_mesh.py", line 28, in <module> from sverchok.utils.sv_bmesh_utils import recalc_normals ImportError: cannot import name 'recalc_normals' from 'sverchok.utils.sv_bmesh_utils' (C:\Users\rendetto\AppData\Roaming\Blender Foundation\Blender\2.90\scripts\addons\sverchok-master\utils\sv_bmesh_utils.py)

Ortho Project On Surface not working

I guess the ortho_project_curve() call needs an update according to the new input values.

In geom.py (line 105) the assignment "projection = ortho_project_curve(src_point, curve, init_samples)" looks outdated.

Thanks

adding more SDF primitives

I have written a few SDF primitives for my own usage and just realized that SDF had been incorporated into Sverchok-Extra. I may not be familiar enough with how the Sverchok node tree is structure, is there a way to add my custom nodes to the list of primitives?

Error Upon Activation.

Activating sverchok-extra in Blender 2.93.4 Gives this error.

Traceback (most recent call last):
File "C:\Program Files\Blender Foundation\Blender 2.93\2.93\scripts\modules\addon_utils.py", line 351, in enable
mod = import(module_name)
File "C:\Users\LeonC\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master_init_.py", line 124, in
imported_modules = [icons] + make_node_list()
File "C:\Users\LeonC\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master_init_.py", line 120, in make_node_list
module = importlib.import_module(f".{module_name}", base_name)
File "C:\Program Files\Blender Foundation\Blender 2.93\2.93\python\lib\importlib_init_.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "C:\Users\LeonC\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master\nodes\sdf\sdf_generate.py", line 19, in
class SvExSdfGenerateNode(bpy.types.Node, SverchCustomTreeNode):
File "C:\Users\LeonC\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master\nodes\sdf\sdf_generate.py", line 82, in SvExSdfGenerateNode
default = sdf.mesh.BATCH_SIZE,
AttributeError: 'NoneType' object has no attribute 'mesh'

Code movement

  • Classes are to be moved from sverchok_extra.* to sverchok.utils.*
  • nodes to be moved

No Marching Squares or Quads to Nurbs

From examples in the Gallery, some require the "Marching Squares" node, others require the "Quads to Nurbs" node.

I've mentioned this before. It looks like everything that needs to be there is there, via pip install and pip list.

Sverchok-Extra doesn't install. A good amount of the dependencies are in Sverchok (as noted).

These two aren't showing up.

Maybe they're works in progress? Maybe a rest of the story?

Anything I can try.

Using Blender 2.90 - MacBook Pro, Catalina if that helps.

No separator line between my nodes and sverchok-extra

I have been modelling my Topologic nodes on sverchok extra and I just noticed that in the Shift-A menu, there is no separation between the sverchok-extra nodes and the Topologic nodes. I am suspecting somehow they are being read into the same category? If so, where should I look to make sure there is a separator line between the two packages? Thank you
Screenshot from 2021-02-11 11-20-27

TODO

  • Minimal surface node: option to do not generate any mesh (only output Surface); make it the default one.
  • Node(s) to generate "bending" VectorField from a) RbfSurface, b) NURBS surface, c) NURBS curve.
  • Differential operators for scalar and vector fields: gradient, divergence, Laplace, rotor.
  • "Marching squares" node that operates on textures. Implemented as "Image Field" node, that turns Image datablock into either Scalar Field or Vector Field. Marching Squares can be applied to any scalar field.

Gallery

Here are some examples of what is possible with Sverchok-Extra.
Some of this is possible to achieve with plain Sverchok, but with much more nodes; or with Sverchok plus scripted nodes. In Sverchok-Extra, it becomes relatively easy.

Screenshot_20200119_151547

marching_squares_1

Won't Install (Any version Blender?)

I've tried installing it from the sverchok_extra_master zip file. Renaming it to sverchok_master. Renaming Sverchok to sverchok_bak and renaming sverchok_extra_master to sverchok. Under 2.83.5, 2.9.0 (final), and 2.79.

Here's one error I get:

SVE_Iinstall_error_JPG

I'd really love to use it. But, so far, stuck.

error upon activation (linux, python 3.9, blender 3.0)

I get this error upon activation:

Traceback (most recent call last):
File "/usr/share/blender/3.0/scripts/modules/addon_utils.py", line 351, in enable
mod = import(module_name)
File "/home/sinasta/.config/blender/3.0/scripts/addons/sverchok-extra-master/init.py", line 120, in
imported_modules = [icons] + make_node_list()
File "/home/sinasta/.config/blender/3.0/scripts/addons/sverchok-extra-master/init.py", line 116, in make_node_list
module = importlib.import_module(f".{module_name}", base_name)
File "/usr/lib/python3.9/importlib/init.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "/home/sinasta/.config/blender/3.0/scripts/addons/sverchok-extra-master/nodes/sdf/estimate_bounds.py", line 11, in
from sverchok_extra.utils.sdf import *
File "/home/sinasta/.config/blender/3.0/scripts/addons/sverchok-extra-master/utils/sdf.py", line 113, in
ease.linear,
NameError: name 'ease' is not defined

is there any dependency i need to install?

Sverchok Extra add-on cannot start (blender-2.93.2)

When trying to enable the add-on I got an error:

Traceback (most recent call last):
File "D:\BlenderBin\blender-2.93.2-candidate+v293.9e64fd461ac3-windows.amd64-release\2.93\scripts\modules\addon_utils.py", line 351, in enable mod = __import__(module_name)
File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master\__init__.py", line 78, in <module> imported_modules = [icons] + make_node_list()
File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master\__init__.py", line 74, in make_node_list module = importlib.import_module(f".{module_name}", base_name)
File "D:\BlenderBin\blender-2.93.2-candidate+v293.9e64fd461ac3-windows.amd64-release\2.93\python\lib\importlib\__init__.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level)
File "C:\Users\User\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-extra-master\nodes\surface\triangular_mesh.py", line 7, in <module> from sverchok.core.update_system import process_from_node
ImportError: cannot import name 'process_from_node' from 'sverchok.core.update_system' (C:\Users\User\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\sverchok-master\core\update_system.py)

![Screenshot_20200119_234920](https://user-images.githubusercontent.com/284644/72687091-a31e0c80-3b1c-11ea-8e43-0ca2f031e959.png)

![Screenshot_20200119_234920](https://user-

images.githubusercontent.com/284644/72687091-a31e0c80-3b1c-11ea-8e43-0ca2f031e959.png)

sphere_tangent_noise_1

Originally posted by @portnov in #1 (comment)

As best I can make out, I've got all the nodes. I can't be sure of the input of some nodes, there's more than one possibility (the Inverse option, one example.

Is there a gist I can try for this, just to see if / where a mistake is?

Thanx

If this helps:

https://pasteall.org/media/b/5/b5bfb34bc2eb14ea5046f0d54f04e65c.blend

PyMCubes didn't install

Everything else did as directed.

hometp@hometp-ThinkPad-W530 ~ $ /home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/bin/python3.7m -m pip install -U PyMCubes

Collecting PyMCubes
Using cached PyMCubes-0.0.12.tar.gz (12 kB)
Building wheels for collected packages: PyMCubes
Building wheel for PyMCubes (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: /home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/bin/python3.7m -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-cbc8axsz/PyMCubes/setup.py'"'"'; file='"'"'/tmp/pip-install-cbc8axsz/PyMCubes/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-913_1mdh
cwd: /tmp/pip-install-cbc8axsz/PyMCubes/
Complete output (19 lines):
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.7
creating build/lib.linux-x86_64-3.7/mcubes
copying mcubes/exporter.py -> build/lib.linux-x86_64-3.7/mcubes
copying mcubes/init.py -> build/lib.linux-x86_64-3.7/mcubes
running build_ext
building 'mcubes._mcubes' extension
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/mcubes
creating build/temp.linux-x86_64-3.7/mcubes/src
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -I/home/sergey/Developer/build_linux/deps/Release/sqlite/include -I/home/sergey/Developer/build_linux/deps/Release/bzip2/include -I/home/sergey/Developer/build_linux/deps/Release/lzma/include -I/home/sergey/Developer/build_linux/deps/Release/zlib/include -fPIC -fPIC -Imcubes/src -I/home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/lib/python3.7/site-packages/numpy/core/include -I/home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/include/python3.7m -c mcubes/src/_mcubes.cpp -o build/temp.linux-x86_64-3.7/mcubes/src/_mcubes.o -std=c++11 -Wall
mcubes/src/_mcubes.cpp:35:10: fatal error: Python.h: No such file or directory
#include "Python.h"
^~~~~~~~~~
compilation terminated.
error: command 'gcc' failed with exit status 1

ERROR: Failed building wheel for PyMCubes
Running setup.py clean for PyMCubes
Failed to build PyMCubes
Installing collected packages: PyMCubes
Running setup.py install for PyMCubes ... error
ERROR: Command errored out with exit status 1:
command: /home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/bin/python3.7m -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-cbc8axsz/PyMCubes/setup.py'"'"'; file='"'"'/tmp/pip-install-cbc8axsz/PyMCubes/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-l7ioj6k3/install-record.txt --single-version-externally-managed --compile --install-headers /home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/include/python3.7m/PyMCubes
cwd: /tmp/pip-install-cbc8axsz/PyMCubes/
Complete output (19 lines):
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.7
creating build/lib.linux-x86_64-3.7/mcubes
copying mcubes/exporter.py -> build/lib.linux-x86_64-3.7/mcubes
copying mcubes/init.py -> build/lib.linux-x86_64-3.7/mcubes
running build_ext
building 'mcubes._mcubes' extension
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/mcubes
creating build/temp.linux-x86_64-3.7/mcubes/src
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -I/home/sergey/Developer/build_linux/deps/Release/sqlite/include -I/home/sergey/Developer/build_linux/deps/Release/bzip2/include -I/home/sergey/Developer/build_linux/deps/Release/lzma/include -I/home/sergey/Developer/build_linux/deps/Release/zlib/include -fPIC -fPIC -Imcubes/src -I/home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/lib/python3.7/site-packages/numpy/core/include -I/home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/include/python3.7m -c mcubes/src/_mcubes.cpp -o build/temp.linux-x86_64-3.7/mcubes/src/_mcubes.o -std=c++11 -Wall
mcubes/src/_mcubes.cpp:35:10: fatal error: Python.h: No such file or directory
#include "Python.h"
^~~~~~~~~~
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/bin/python3.7m -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-cbc8axsz/PyMCubes/setup.py'"'"'; file='"'"'/tmp/pip-install-cbc8axsz/PyMCubes/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-l7ioj6k3/install-record.txt --single-version-externally-managed --compile --install-headers /home/hometp/Downloads/Blender/282/final/blender-2.82-linux64/2.82/python/include/python3.7m/PyMCubes Check the logs for full command output.

Fail on reload event

After reload.scripts sverchok-extra does not load
[ERROR] root: Can't obtain logging preferences, it's too early. Stack:

Documentation

  • Describe terms for Curve, Surface
  • Move article about Fields to .rst
  • Documentation for nodes (at least for those which are to be moved for Sverchok)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.