[Bf-extensions-cvs] [340bcc72] master: Curve Tools, Remove Add Curve Simple

meta-androcto noreply at git.blender.org
Thu Mar 16 10:32:13 CET 2017


Commit: 340bcc7292718e8cb749f3b03541c450524c7bb2
Author: meta-androcto
Date:   Thu Mar 16 20:31:47 2017 +1100
Branches: master
https://developer.blender.org/rBAC340bcc7292718e8cb749f3b03541c450524c7bb2

Curve Tools, Remove Add Curve Simple

===================================================================

M	curve_tools/__init__.py
D	curve_tools/add_curve_simple.py

===================================================================

diff --git a/curve_tools/__init__.py b/curve_tools/__init__.py
index 7b660c6d..54fc1094 100644
--- a/curve_tools/__init__.py
+++ b/curve_tools/__init__.py
@@ -25,7 +25,7 @@ from . import Properties
 from . import Operators
 from . import auto_loft
 from . import curve_outline
-from . import add_curve_simple
+
 
 from bpy.types import (
         AddonPreferences,
@@ -179,11 +179,6 @@ class CurvePanel(bpy.types.Panel):
         UTILSDROP = scene.UTUtilsDrop
         layout = self.layout
 
-        # Object Creation
-        box1 = self.layout.box()
-        col = box1.column(align=True)
-        row = col.row(align=True)
-        row.menu("INFO_MT_simple_menu", icon="OBJECT_DATAMODE")
 
         # Z. selection
         boxSelection = self.layout.box()
@@ -393,7 +388,6 @@ def register():
                                     )
     auto_loft.register()
     curve_outline.register()
-    add_curve_simple.register()
     bpy.utils.register_class(Properties.CurveTools2SelectedObject)
     bpy.utils.register_class(CurveAddonPreferences)
     bpy.utils.register_class(CurveTools2Settings)
@@ -434,7 +428,6 @@ def unregister():
 
     auto_loft.unregister()
     curve_outline.unregister()
-    add_curve_simple.unregister()
     bpy.utils.unregister_class(CurveAddonPreferences)
     # bpy.app.handlers.scene_update_pre.remove(SceneUpdatePreHandler)
     bpy.utils.unregister_class(CurvePanel)
diff --git a/curve_tools/add_curve_simple.py b/curve_tools/add_curve_simple.py
deleted file mode 100644
index 507cb58d..00000000
--- a/curve_tools/add_curve_simple.py
+++ /dev/null
@@ -1,1607 +0,0 @@
-# ##### BEGIN GPL LICENSE BLOCK #####
-#
-#  This program is free software; you can redistribute it and / or
-#  modify it under the terms of the GNU General Public License
-#  as published by the Free Software Foundation; either version 2
-#  of the License, or (at your option) any later version.
-#
-#  This program is distributed in the hope that it will be useful,
-#  but WITHOUT ANY WARRANTY; without even the implied warranty of
-#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#  GNU General Public License for more details.
-#
-#  You should have received a copy of the GNU General Public License
-#  along with this program; if not, write to the Free Software Foundation,
-#  Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110 - 1301, USA.
-#
-# ##### END GPL LICENSE BLOCK #####
-
-bl_info = {
-    'name': 'Simple Curve',
-    'author': 'Spivak Vladimir (http://cwolf3d.korostyshev.net)',
-    'version': (1, 5, 2),
-    'blender': (2, 6, 9),
-    'location': 'View3D > Add > Curve',
-    'description': 'Adds Simple Curve',
-    'warning': '',  # used for warning icon and text in addons panel
-    'wiki_url': 'http://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/Curve/Simple_curves',
-    "tracker_url": "https://developer.blender.org/maniphest/task/edit/form/2/",
-    'category': 'Add Curve'}
-
-
-# ------------------------------------------------------------
-#### import modules
-import bpy
-from bpy.props import *
-from mathutils import *
-from math import *
-from bpy_extras.object_utils import *
-from random import *
-
-# ------------------------------------------------------------
-# Point:
-
-
-def SimplePoint():
-    newpoints = []
-
-    newpoints.append([0.0, 0.0, 0.0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Line:
-
-
-def SimpleLine(c1=[0.0, 0.0, 0.0], c2=[2.0, 2.0, 2.0]):
-    newpoints = []
-
-    c3 = Vector(c2) - Vector(c1)
-    newpoints.append([0.0, 0.0, 0.0])
-    newpoints.append([c3[0], c3[1], c3[2]])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Angle:
-
-
-def SimpleAngle(length=1.0, angle=45.0):
-    newpoints = []
-
-    angle = radians(angle)
-    newpoints.append([length, 0.0, 0.0])
-    newpoints.append([0.0, 0.0, 0.0])
-    newpoints.append([length * cos(angle), length * sin(angle), 0.0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Distance:
-
-
-def SimpleDistance(length=1.0, center=True):
-    newpoints = []
-
-    if center:
-        newpoints.append([-length / 2, 0.0, 0.0])
-        newpoints.append([length / 2, 0.0, 0.0])
-    else:
-        newpoints.append([0.0, 0.0, 0.0])
-        newpoints.append([length, 0.0, 0.0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Circle:
-
-
-def SimpleCircle(sides=4, radius=1.0):
-    newpoints = []
-
-    angle = radians(360) / sides
-    newpoints.append([radius, 0, 0])
-    j = 1
-    while j < sides:
-        t = angle * j
-        x = cos(t) * radius
-        y = sin(t) * radius
-        newpoints.append([x, y, 0])
-        j += 1
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Ellipse:
-
-
-def SimpleEllipse(a=2.0, b=1.0):
-    newpoints = []
-
-    newpoints.append([a, 0.0, 0.0])
-    newpoints.append([0.0, b, 0.0])
-    newpoints.append([-a, 0.0, 0.0])
-    newpoints.append([0.0, -b, 0.0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Arc:
-
-
-def SimpleArc(sides=0, radius=1.0, startangle=0.0, endangle=45.0):
-    newpoints = []
-
-    startangle = radians(startangle)
-    endangle = radians(endangle)
-    sides += 1
-
-    angle = (endangle - startangle) / sides
-    x = cos(startangle) * radius
-    y = sin(startangle) * radius
-    newpoints.append([x, y, 0])
-    j = 1
-    while j < sides:
-        t = angle * j
-        x = cos(t + startangle) * radius
-        y = sin(t + startangle) * radius
-        newpoints.append([x, y, 0])
-        j += 1
-    x = cos(endangle) * radius
-    y = sin(endangle) * radius
-    newpoints.append([x, y, 0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Sector:
-
-
-def SimpleSector(sides=0, radius=1.0, startangle=0.0, endangle=45.0):
-    newpoints = []
-
-    startangle = radians(startangle)
-    endangle = radians(endangle)
-    sides += 1
-
-    newpoints.append([0, 0, 0])
-    angle = (endangle - startangle) / sides
-    x = cos(startangle) * radius
-    y = sin(startangle) * radius
-    newpoints.append([x, y, 0])
-    j = 1
-    while j < sides:
-        t = angle * j
-        x = cos(t + startangle) * radius
-        y = sin(t + startangle) * radius
-        newpoints.append([x, y, 0])
-        j += 1
-    x = cos(endangle) * radius
-    y = sin(endangle) * radius
-    newpoints.append([x, y, 0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Segment:
-
-
-def SimpleSegment(sides=0, a=2.0, b=1.0, startangle=0.0, endangle=45.0):
-    newpoints = []
-
-    startangle = radians(startangle)
-    endangle = radians(endangle)
-    sides += 1
-
-    angle = (endangle - startangle) / sides
-    x = cos(startangle) * a
-    y = sin(startangle) * a
-    newpoints.append([x, y, 0])
-    j = 1
-    while j < sides:
-        t = angle * j
-        x = cos(t + startangle) * a
-        y = sin(t + startangle) * a
-        newpoints.append([x, y, 0])
-        j += 1
-    x = cos(endangle) * a
-    y = sin(endangle) * a
-    newpoints.append([x, y, 0])
-
-    x = cos(endangle) * b
-    y = sin(endangle) * b
-    newpoints.append([x, y, 0])
-    j = sides
-    while j > 0:
-        t = angle * j
-        x = cos(t + startangle) * b
-        y = sin(t + startangle) * b
-        newpoints.append([x, y, 0])
-        j -= 1
-    x = cos(startangle) * b
-    y = sin(startangle) * b
-    newpoints.append([x, y, 0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Rectangle:
-
-
-def SimpleRectangle(width=2.0, length=2.0, rounded=0.0, center=True):
-    newpoints = []
-
-    r = rounded / 2
-
-    if center:
-        x = width / 2
-        y = length / 2
-        if rounded != 0.0:
-            newpoints.append([-x + r, y, 0.0])
-            newpoints.append([x - r, y, 0.0])
-            newpoints.append([x, y - r, 0.0])
-            newpoints.append([x, -y + r, 0.0])
-            newpoints.append([x - r, -y, 0.0])
-            newpoints.append([-x + r, -y, 0.0])
-            newpoints.append([-x, -y + r, 0.0])
-            newpoints.append([-x, y - r, 0.0])
-        else:
-            newpoints.append([-x, y, 0.0])
-            newpoints.append([x, y, 0.0])
-            newpoints.append([x, -y, 0.0])
-            newpoints.append([-x, -y, 0.0])
-
-    else:
-        x = width
-        y = length
-        if rounded != 0.0:
-            newpoints.append([r, y, 0.0])
-            newpoints.append([x - r, y, 0.0])
-            newpoints.append([x, y - r, 0.0])
-            newpoints.append([x, r, 0.0])
-            newpoints.append([x - r, 0.0, 0.0])
-            newpoints.append([r, 0.0, 0.0])
-            newpoints.append([0.0, r, 0.0])
-            newpoints.append([0.0, y - r, 0.0])
-        else:
-            newpoints.append([0.0, 0.0, 0.0])
-            newpoints.append([0.0, y, 0.0])
-            newpoints.append([x, y, 0.0])
-            newpoints.append([x, 0.0, 0.0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Rhomb:
-
-
-def SimpleRhomb(width=2.0, length=2.0, center=True):
-    newpoints = []
-    x = width / 2
-    y = length / 2
-
-    if center:
-        newpoints.append([-x, 0.0, 0.0])
-        newpoints.append([0.0, y, 0.0])
-        newpoints.append([x, 0.0, 0.0])
-        newpoints.append([0.0, -y, 0.0])
-    else:
-        newpoints.append([x, 0.0, 0.0])
-        newpoints.append([0.0, y, 0.0])
-        newpoints.append([x, length, 0.0])
-        newpoints.append([width, y, 0.0])
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Polygon:
-
-
-def SimplePolygon(sides=3, radius=1.0):
-    newpoints = []
-    angle = radians(360.0) / sides
-    j = 0
-
-    while j < sides:
-        t = angle * j
-        x = sin(t) * radius
-        y = cos(t) * radius
-        newpoints.append([x, y, 0.0])
-        j += 1
-
-    return newpoints
-
-# ------------------------------------------------------------
-# Polygon_ab:
-
-
-def SimpleP

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-extensions-cvs mailing list