Giter VIP home page Giter VIP logo

edgeflow's People

Contributors

benjaminsauder 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  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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

edgeflow's Issues

Error message when trying to use.

Hi,

For a while the add on was working fine, then all of a sudden I am getting this error message:

edge_loops: 27
Traceback (most recent call last):
File "C:\Users\lasse\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\op_set_edge_flow.py", line 114, in invoke
result = super(SetEdgeFlowOP, self).invoke(context)
File "C:\Users\lasse\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\op_set_edge_flow.py", line 68, in invoke
self.edgeloops[obj] = util.get_edgeloops(self.bm[obj], edges)
File "C:\Users\lasse\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\util.py", line 194, in get_edgeloops
edge_loops = compute_edgeloop_data(edge_loops)
File "C:\Users\lasse\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\util.py", line 308, in compute_edgeloop_data
find_control_edgeloop(edgeloops, edge_to_Edgeloop)
File "C:\Users\lasse\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\util.py", line 227, in find_control_edgeloop
edge_ring.append(edge.link_loops[0])
IndexError: BMElemSeq[index]: index 0 out of range

location: :-1

location: :-1

Any ideas?

thanks.

Blender 2.9

Will this need anything more than a bl_info update for 2.9? Happy to help test. :)

Installation issue

Following the installation directions in the readme does not appear to work. The add-on reports no errors, however it does not show up in the add-ons list, and therefore can not be enabled. I am using Blender 2.8, the latest official release as of 08/08/2019. Please advise.

Unable to call Edge Flow from another add-on

Hi, I'm trying to write my own add-on that utilizes your "Edge Flow" addon for blender, and I'm running into issues.

Whenever I try to run:
bpy.ops.mesh.set_edge_flow(tension=180, iterations=1) from my own blender Addon script,

I get this error:

Error: Traceback (most recent call last): File "C:\Users\Neil Moore\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\op_set_edge_flow.py", line 93, in execute self.revert() File "C:\Users\Neil Moore\AppData\Roaming\Blender Foundation\Blender\2.80\scripts\addons\EdgeFlow\op_set_edge_flow.py", line 19, in revert for obj in self.objects: File "c:\Program Files\Blender Foundation\Blender\2.80\scripts\modules\bpy_types.py", line 674, in __getattribute__ return super().__getattribute__(attr) AttributeError: 'SetEdgeFlowOP' object has no attribute 'objects'

So, I tried this instead:

bpy.ops.mesh.set_edge_flow("INVOKE_DEFAULT") <-- This works

However, I lose the ability to set any of the parameters. So, I tried this:

bpy.ops.mesh.set_edge_flow("INVOKE_DEFAULT", tension=-500, iterations=1)

Unfortunately, setting the parameter of "tension" to "-500" simply changes nothing. The parameters appears to be ignored, and default values are chosen.

It would be nice if I could use the edge flow script in my own addon. I'm trying to automate the creation of "loop cuts" and then simultaneously apply edge flow. The addon will be free, and would simply be a companion addon. In other words, I do not want to redistribute your addon with my addon, I simply wish to be able to call the command, and if the addon exists in the user's addons folder, the edge flow will be applied to the selected edges. I will of course, provide credit! :)

Any help would be greatly appreciated!

Feature Request: Get rid of Iteration Max limit

If you open up the op_set_edge_flow.py file, and go to line 84, you'll see:
iterations : IntProperty(name="Iterations", default=1, min=1, max=32)

Can you change max to be soft_max like this:
iterations : IntProperty(name="Iterations", default=1, min=1, soft_max=32)

This will get rid of the hard maximum on the number of iterations. It will allow users to type a number higher than 32, but the slider will still be confined to 32.

The reason I would like this to be changed is because in my addon, I can insert multiple loop cuts, and then apply edge flow to the newly added loops, and the hard limit of 32 iterations prevents the edges from being smoothed correctly. I really need at least 128 iterations.

Before: https://i.imgur.com/CpvTbAQ.jpg
After with 32 iterations: https://i.imgur.com/B4B5vEr.jpg <-- Bad result
After with 128 iterations: https://i.imgur.com/BEOBu9c.jpg <-- Good result

As you can see, when inserting 8 edge loops with 128 iterations, it turns out much better! :)

Edit: I just found a case where I needed 512 iterations to create a perfect result.

Before: https://i.imgur.com/g6HBjwP.png
After with 512 iterations: https://i.imgur.com/g6HBjwP.png

Hopefully you consider!
-Neil

Right-click context keyboard shortcut

Hi,

I use the right-click context menu's shortcut S for subdivide all the time in vert, edge, and face mode. With the edgeflow add-on enabled, the S shortcut key while in context menu is now taken and subdivide is now different keys for vert, edge, face. Is this something that is being specified in the edge flow addon or an automated assignment from a blender setting that I may change? I'm seeing this change in 4.1 with version 0.8 - in blender 3.6.2 with version 0.5 I have no problem. thank you.

set linear bug on blender 2.82a

hi. first of all i love this tool, thanks a lot for sharing this (better than the maya versione imho)
it worked just fine on 2.8, but there is an issue on the set linear tool in 2.82a that crunch all vertices
thanks again
vlc_2020-03-28_16-12-12
vlc_2020-03-28_16-12-25

Functions not present in Edit mode Edge menu

Not sure if there's a simple fix for this but in the latest build of 2.8 the linear and flow functions don't show up in the Edge menu and don't seem to show up when searching either. Probably something in the init.py file that needs updating.

Feature Req: Linear Interpolate Vertex Positions Between 0-1

Hi, just a simple feature request. Sometimes even just 1 iteration can produce a very drastic result depending on the usage scenario.

The ability to drag a slider from 0-1 (or 0% to 100%) to interpolate the original vertex positions with the final positions would be very useful! :)

If implemented, I recommend 100% as the default value, so that the addon does not cause any compatibility issues with my Edge Curve Plus addon.

Thanks for your consideration! :)

Respect Hard Edge Mode.

Hi There!

Thx for this great update.
I have small feature request which could improve the Addon so much.
It would be great to add a feature where the operation respects the Hard Edges. So we could get nice Edge-flow in areas like the attached image. (red marking = hard edge)
Now I ahve to add a temporary extra loop to the tip of the edges so I can Edge-flow the loops before the tip. and after the Operation, I have to Delete it.

All the Best, and thx for this great plugin.

image

Running operators when no objects are selected

Both "set flow" and "set linear" operators won't work if there were no selected object prior to entering edit mode. To reproduce it

  1. select editable mesh object in object mode
  2. deselect all objects
  3. press tab to enter edit mode
  4. run "set linear" operator on edges

blender will throw error, because of this line
self.objects = set(context.selected_editable_objects)
in this scenario context.selected_editable_objects list is empty, so self.objects would be empty too
I fixed it by changing 40 line in op_set_edge_flow.py to
self.objects = set(context.selected_editable_objects) if context.selected_editable_objects else set([context.object])

New feature: Blend from start and/or end point

I have added a new feature to blend from either the start or end point (or both) which is very convenient when working with edge loops which span across a surface with different features. Currently the adjusted edge loop will be placed at the center between it's surrounding loops. But sometimes the start or end point of the loop needs to stay put to preserve the surface feature in this area. And adjusting loop positions can be quite tedious when done manually.

I already tried to contact you via Twitter because posting this new feature seems to draw much attention.

For now I forked your project to provide a custom version to the public because this new feature is extremely helpful.
I just didn't want to skip over your head and let you know. The project has been quiet for some time and I don't know if you plan to develop this tool further. It's a real time saver. Thank you very much for it.

please rename the menu to something else

Hello,

love your addon. The only issue I have with it is that it adds "Set Flow" to the context menu, which highlights the first letter (S). This takes away the shortcut from "Subdivide" in Edge mode (making "i" the highlighted letter in "Subdivide").

This is an issue because I like to just right-click and press "S" to subdivide. With EdgeFlow addon installed, subdividing is done with "S" in face mode, but with "i" in edge mode, breaking consistency.

I always rename "Set Flow" to just "Flow" after installing the addon to keep my "S" key for subdividing, but it would be nice to just have that working consistently just after installing/updating the addon.

functions not showing up in Edge menu

Tried latest "release" zip, as well as manually pulled latest code from repo, and am not seeing either option in my Edge menu.

Peek2020-11-0513-51

Looking forward to trying this out.

Blender 3.0 issues(NEVERMIND)

NEVERMIND! FIGURED IT OUT

in 3.0 Blender, edge flow is having an issue. When I select the edge I want edgeflow to mimic, it takes the edge I had selected and moves the edge about a third the distance into the meshes center as well scales it down. I am doing this on a perfect cylinder. I created a new cube and select an edge and applied edgeflow, and still does the same thing.

Sometime it stops working.

Something down the line brakes the tool.

To make it work again:

  1. Deselect edges
  2. I have to leave edit mode
  3. select an other object.
  4. jump in edit mode.
  5. select something
  6. leve edit mode
  7. Select the first object
  8. go in edit mode
  9. select again the edges
  10. NOW IT WORKS

I wonder if anybody facing the same issue.

Hope my issue submission makes the tool even more ososm.

All the best.

Unexpected result

Hi, I have tested the addon and in a specific situation it doesnt work. Please see the picture to see the problem.

It looks like that calculation is not ok when there is an extreme angle.

Cheers
Tomas

image

SyntaxError: invalid syntax in 2.79

Traceback (most recent call last):
File "C:\Program Files\Blender Foundation\Blender\2.79\scripts\modules\addon_utils.py", line 331, in enable
mod = import(module_name)
File "C:\Users\alekv\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\EdgeFlow-master_init_.py", line 25, in
from . import (
File "C:\Users\alekv\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\EdgeFlow-master\op_set_edge_flow.py", line 83
tension : IntProperty(name="Tension", default=180, min=-500, max=500)
^
SyntaxError: invalid syntax

Mix "wobbles"

I think this is easier to just show than explain.

blender_nXQD9Utf5b.mp4

Affects both Set Flow and Set Curve.
Also small suggestion while we're here, since mix already exists for these two tools, it would be nice to have it on the rest.

Utilize built-in BMLoop data structure

Instead of manually getting the edge loop by repurposing the selection code, wouldn't it be simpler to use the built-in BMLoop object?

e = bm.edges[0] # edge at the start of the edge loop

# get BMLoop that points to the right direction
for loop in e.link_loops:
    if len(loop.vert.link_edges) == 4:
        break

# stop when reach the end of the edge loop
while len(loop.vert.link_edges) == 4:

    # jump between BMLoops to the next BMLoop we need
    loop = loop.link_loop_prev.link_loop_radial_prev.link_loop_prev

    # following edge in the edge loop
    e_next = loop.edge

Source: Mikhail Rachinskiy on Stack Exchange

He does say:

This example code works only with manifold geometry where all face normals facing one direction.

I'm not sure whether his comment means that it only works with manifold geometry or if that's simply a requirement when working with manifold geometry.

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.