[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [2666] branches/geodesic_domes/ geodesic_domes_260/gui_pkhg.py: old gui, not nice,

Peter K.H. Gragert pkhgragert at gmail.com
Sun Nov 27 11:43:52 CET 2011


Revision: 2666
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-extensions&revision=2666
Author:   pkhg
Date:     2011-11-27 10:43:49 +0000 (Sun, 27 Nov 2011)
Log Message:
-----------
old gui, not nice,
replaced by third_domes_panel.py

Removed Paths:
-------------
    branches/geodesic_domes/geodesic_domes_260/gui_pkhg.py

Deleted: branches/geodesic_domes/geodesic_domes_260/gui_pkhg.py
===================================================================
--- branches/geodesic_domes/geodesic_domes_260/gui_pkhg.py	2011-11-27 10:26:23 UTC (rev 2665)
+++ branches/geodesic_domes/geodesic_domes_260/gui_pkhg.py	2011-11-27 10:43:49 UTC (rev 2666)
@@ -1,982 +0,0 @@
-#pkhg new gui 2011-11-02
-import bpy
-import sys
-from geodesic_domes import vefm_259 as vefm_259
-
-from geodesic_domes import forms_259  as forms_259
-from geodesic_domes import geodesic_classes_259 as geodesic_classes_259
-import math
-from math import pi #,cos, sin, sqrt
-from bpy.props import EnumProperty, IntProperty, FloatProperty, StringProperty, BoolProperty
-
-#globals
-created_vefm_mesh_values = None
-last_generated_object = None
-##for Hub
-bpy.types.Scene.make_a_hub = BoolProperty(name = "HUB?", description = "make a HUB out of an selected mesh", default = False)
-
-## for Strut
-bpy.types.Scene.make_a_strut = BoolProperty(name = "STUT?", description = "make a STRUT out of an selected mesh", default = False)
-bpy.types.Scene.strut_max_number_parts = IntProperty(name = "Max nr parts",min=0,max = 1000, description = "Maximum number of v,e,f", default = 100)
-
-##
-bpy.types.Scene.superformula_um = FloatProperty(name = 'um', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  3)
-bpy.types.Scene.superformula_un1 = FloatProperty(name = 'un1', min = 0, soft_min=0.1, soft_max=5,max = 20, default =  1)
-bpy.types.Scene.superformula_un2 = FloatProperty(name = 'un2', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_un3 = FloatProperty(name = 'un3', min = 0,   soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_ua = FloatProperty(name = 'ua', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1.0)
-bpy.types.Scene.superformula_ub = FloatProperty(name = 'ub', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  4.0)
-bpy.types.Scene.superformula_vm = FloatProperty(name = 'vm', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_vn1 = FloatProperty(name = 'vn1', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_vn2 = FloatProperty(name = 'vn2', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_vn3 = FloatProperty(name = 'vn3', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_va = FloatProperty(name = 'va', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_vb = FloatProperty(name = 'vb', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  1)
-bpy.types.Scene.superformula_uact = BoolProperty(name = 'sup u-active',default = False)
-bpy.types.Scene.superformula_vact = BoolProperty(name = 'sup v-active',default = False)
-bpy.types.Scene.superformula_uturn = FloatProperty(name = 'uturn', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  0)
-bpy.types.Scene.superformula_vturn = FloatProperty(name = 'vturn', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  0)
-bpy.types.Scene.superformula_utwist = FloatProperty(name = 'utwist', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  0)
-bpy.types.Scene.superformula_vtwist = FloatProperty(name = 'vtwist', min = 0, soft_min=0.1, soft_max=5,max = 10, default =  0)
-#for Geodesics
-bpy.types.Scene.geodesic_frequency = IntProperty(name="Frequency",min = 1, soft_max=5, max = 10, default = 1,description="number of subdivisions")
-
-bpy.types.Scene.class_one = BoolProperty(
-    name="Class nr 1",
-    description="Class nr 1",
-    default=True)
-
-bpy.types.Scene.class_two = BoolProperty(
-    name="Class nr 2",
-    description="Class nr 2",
-    default=False)
-
-bpy.types.Scene.geodesic_dual = BoolProperty(
-    name="Dual",
-    description="Dual object",
-    default=False)
-
-
-bpy.types.Scene.geodesic_spherical = EnumProperty(
-    name="one of two",
-    description="Choose between spherical or flat ",
-    items=[("0","spherical","Generate spherical"),
-           ("1","flat","Generate flat"),
-              ],
-    default='0')
-
-
-
-bpy.types.Scene.choose_type = EnumProperty(
-    name="Your choice",
-    description="Choose Geodesic, Grid, Cylinder,Parabola, Torus, Sphere, Your mesh",
-    items=[("0","Geodesic","Generate Geodesic"),
-           ("1","Grid","Generate Grid"),
-           ("2","Cylinder","Generate Cylinder"),
-           ("3","Parabola","Generate Parabola"),
-           ("4","Torus","Generate Torus"),
-           ("5","Sphere","Generate Sphere"),
-           ("6","Your mesh","Generate Your Mesh"),
-           ("7","Apply sform","Apply superform parameter"),
-          ],
-    default='0')
-
-bpy.types.Scene.base_type = EnumProperty(
-    name="BaseType",
-    description="Choose between Tetrahedron, Octahedron, Icosahedron ",
-    items=[("0","Tetrahedron","Generate Tetrahedron"),
-           ("1","Octahedron","Generate Octahedron"),
-           ("2","Icosahedron","Generate Icosahedron"),
-          ],
-    default='0')
-
-bpy.types.Scene.orientation = EnumProperty(
-    name="Pointer",
-    description="Choose what type of top ",
-    items=[("0","PointUp","Point up"),
-           ("1","EdgeUp","Edge up"),
-           ("2","FaceUp","Face up"),
-           ],
-    default='0')
-
-def get_chosen_type(context):
-    chosen_type = context.scene.choose_type
-    posible_types = {'0':'Geodesic',
-               '1':'Grid',
-               '2':'Cylinder',
-               '3':'Parabola',
-               '4':'Torus',
-               '5':'Sphere',
-               '6':'Your mesh',
-               '7':'Apply sform',
-                     }
-    result = posible_types[chosen_type]
-#PKHG     print("\n***INFO*** >>>>>chosen type =",result)
-    return result
-
-class Geodesic_Domes_panel(bpy.types.Panel):
-    """show in the UI"""
-    bl_label = "Geodesic Domes"
-    bl_region_type = "TOOLS"
-    bl_space_type = "VIEW_3D"
-
-    def draw(self,context):
-        sce = context.scene
-        layout = self.layout
-        row = layout.row()
-        row.prop(sce,"make_a_hub")
-        row.prop(sce,"make_a_strut")
-        if sce.make_a_hub:
-            col = layout.column()
-            col.operator(AddHub.bl_idname,"make it so")
-        elif sce.make_a_strut:
-            col = layout.column()
-            col.prop(sce,"strut_max_number_parts")
-            col.label("Make Strut it with selected parametes")
-            col.operator(AddStrut.bl_idname,"Try a Strut")
-        else:
-            col = layout.column()
-            col.label(" ")
-            col.label("sform parameters")
-            row = layout.row()
-            row.prop(sce,"superformula_uact")
-            row.prop(sce,"superformula_vact")
-            
-            if sce.superformula_uact:
-                col = layout.column()
-                col.label("choose U parameters")
-                row = layout.row()
-                row.prop(sce,'superformula_um')
-                row.prop(sce,'superformula_un1')
-                row = layout.row()
-                row.prop(sce,'superformula_un2')
-                row.prop(sce,'superformula_un3')
-                row = layout.row()
-                row.prop(sce,'superformula_ua')
-                row.prop(sce,'superformula_ub')
-                row = layout.row()
-                row.prop(sce,'superformula_uturn')
-                row.prop(sce,'superformula_utwist')
-            if sce.superformula_vact:
-                col = layout.column()
-                col.label("choose V parameters")
-                row = layout.row()
-                row.prop(sce,'superformula_vm')
-                row.prop(sce,'superformula_vn1')
-                row = layout.row()
-                row.prop(sce,'superformula_vn2')
-                row.prop(sce,'superformula_vn3')
-                row = layout.row()
-                row.prop(sce,'superformula_va')
-                row.prop(sce,'superformula_vb')
-                row = layout.row()
-                row.prop(sce,'superformula_vturn')
-                row.prop(sce,'superformula_vtwist')
-                #if sce.superformula_uact:
-                #row = layout.row()
-    
-            col = layout.column(align=True)
-            col = layout.column()
-            col.label("Types")
-            col.prop(context.scene,"choose_type")
-            #chosen = int(context.scene.choose_type)
-            tmp =  get_chosen_type(context)
-            if tmp == "Geodesic":
-                row = layout.row()
-#            if context.scene.class_one:
-#                row.label("Class 1 AKTIV")
-#            elif context.scene.class_two:
-#                row.label("Class 2 AKTIVE")
-#            else:
-#                row.label("Make a choice of class!")
-#            row = layout.row()
-#            row.prop(context.scene,"class_one")
-#            row.prop(context.scene,"class_two")
-#            col.label(text="PKHG: Select one")
-
-                col.label(text="object to generate")
-                col.prop(context.scene, "base_type")
-                col.prop(context.scene, "orientation")
-                row.operator(AddGeodesic.bl_idname,"create")
-            elif tmp == 'Torus':
-                row = layout.row()
-                row.operator(AddTorus.bl_idname,"Torus")
-            elif tmp == 'Sphere':
-                row = layout.row()
-                row.operator(AddSphere.bl_idname,"Sphere")
-            elif tmp == 'Parabola':
-                row = layout.row()
-                row.operator(AddParabola.bl_idname,"Parabola")
-            elif tmp == 'Cylinder':
-                row = layout.row()
-                row.operator(AddCylinder.bl_idname,"Cylinder")
-            elif tmp == 'Grid':
-                row = layout.row()
-                row.operator(AddGrid.bl_idname,"Grid")
-            elif tmp == 'Apply sform': #sform apply
-                row = layout.row()
-                row.operator(ApplySform.bl_idname,"Apply superform")
-            elif tmp == 'Your mesh':
-                col.label("***INFO*** YOUR MESH not yet implemented")
-            else:
-                col.label(text="Select one")
-                col.label(text="object to generate")
-                col.label(text="pkhg.")
-
-def get_geodesic_special():
-    get_scene = bpy.context.scene
-    geo_type = ""
-    geo_orientation = ''
-    if get_scene.base_type ==  '0':

@@ Diff output truncated at 10240 characters. @@


More information about the Bf-extensions-cvs mailing list