From: ousttrue Date: Sat, 19 Jun 2010 04:20:58 +0000 (+0900) Subject: update package. X-Git-Url: http://git.osdn.jp/view?a=commitdiff_plain;h=8093d81853548bc573586ee41f84f26971bc8acb;p=meshio%2Fmeshio.git update package. --- diff --git a/swig/__init__.py b/swig/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/swig/blender/cp.py b/swig/blender/cp.py index 19dbfb9..accde24 100644 --- a/swig/blender/cp.py +++ b/swig/blender/cp.py @@ -1,6 +1,7 @@ import shutil +import os -SWIG="T:/work2/sf/MeshIO/swig" +SWIG="T:/work2/sf/MeshIO/swig/meshio" DST_24=[ "T:/Blender/bf-blender/build2.4git/bin/Release/.blender/scripts", @@ -22,6 +23,7 @@ DST_25=[ "T:/Blender/bf-blender/build2.5/bin/Debug/.blender/scripts/io", "T:/Blender/bf-blender/build2.5git/bin/Release/.blender/scripts/io", "T:/Blender/1340_Release/Release/.blender/scripts/io", + "io", ] def copy24(src): @@ -30,7 +32,6 @@ def copy24(src): dst="%s/%s" % (dst, src) print(dst) shutil.copy(src, dst) - shutil.copy(src, SWIG) def copy25(src): print("copy %s..." % src) @@ -41,11 +42,12 @@ def copy25(src): continue print(dst) shutil.copy(src, dst) - shutil.copy(src, "%s/%s" % (SWIG, MAP_25[src])) if __name__=="__main__": import sys + if not os.path.exists(SWIG): + os.mkdir(SWIG) for v in sys.argv[1:]: copy24(v) copy25(v) diff --git a/swig/blender/pmd_export.py b/swig/blender/pmd_export.py index 567edcf..1d863cc 100644 --- a/swig/blender/pmd_export.py +++ b/swig/blender/pmd_export.py @@ -19,6 +19,7 @@ This script exports a pmd model. 1.0 20100530: implement basic features. 1.1 20100612: integrate 2.4 and 2.5. 1.2 20100616: implement rigid body. +1.3 20100619: fix rigid body, bone weight. """ MMD_SHAPE_GROUP_NAME='_MMD_SHAPE' diff --git a/swig/englishmap.py b/swig/englishmap.py deleted file mode 100644 index a17380e..0000000 --- a/swig/englishmap.py +++ /dev/null @@ -1,241 +0,0 @@ -#!/usr/bin/env python -# coding: utf8 -import sys - -############################################################################### -# 日本語名との変換マップ -############################################################################### -boneMap=[ -("center", "センター", 1), -("upper body", "上半身"), -("neck", "首"), -("head", "頭"), -("eye_L", "左目", 5), -("eye_R", "右目", 5), -("necktie1", "ネクタイ1"), -("necktie2", "ネクタイ2"), -("necktie3", "ネクタイ3"), -("lower body", "下半身"), -("waist accessory", "腰飾り"), -("hair1_L", "左髪1"), -("hair2_L", "左髪2"), -("hair3_L", "左髪3"), -("hair4_L", "左髪4"), -("hair5_L", "左髪5"), -("hair6_L", "左髪6"), -("shoulder_L", "左肩"), -("arm_L", "左腕"), -("arm twist_L", "左腕捩", 8), -("elbow_L", "左ひじ"), -("wrist twist_L", "左手捩", 8), -("wrist_L", "左手首"), -("sleeve_L", "左袖", 1), -("thumb1_L", "左親指1"), -("thumb2_L", "左親指2"), -("fore1_L", "左人指1"), -("fore2_L", "左人指2"), -("fore3_L", "左人指3"), -("middle1_L", "左中指1"), -("middle2_L", "左中指2"), -("middle3_L", "左中指3"), -("third1_L", "左薬指1"), -("third2_L", "左薬指2"), -("third3_L", "左薬指3"), -("little1_L", "左小指1"), -("little2_L", "左小指2"), -("little3_L", "左小指3"), -("front skirt_L", "左スカート前"), -("back skirt_L", "左スカート後"), -("leg_L", "左足"), -("knee_L", "左ひざ"), -("ankle_L", "左足首"), -("hair1_R", "右髪1"), -("hair2_R", "右髪2"), -("hair3_R", "右髪3"), -("hair4_R", "右髪4"), -("hair5_R", "右髪5"), -("hair6_R", "右髪6"), -("shoulder_R", "右肩"), -("arm_R", "右腕"), -("arm twist_R", "右腕捩", 8), -("elbow_R", "右ひじ"), -("wrist twist_R", "右手捩", 8), -("wrist_R", "右手首"), -("sleeve_R", "右袖", 1), -("thumb1_R", "右親指1"), -("thumb2_R", "右親指2"), -("fore1_R", "右人指1"), -("fore2_R", "右人指2"), -("fore3_R", "右人指3"), -("middle1_R", "右中指1"), -("middle2_R", "右中指2"), -("middle3_R", "右中指3"), -("third1_R", "右薬指1"), -("third2_R", "右薬指2"), -("third3_R", "右薬指3"), -("little1_R", "右小指1"), -("little2_R", "右小指2"), -("little3_R", "右小指3"), -("front skirt_R", "右スカート前"), -("back skirt_R", "右スカート後"), -("leg_R", "右足"), -("knee_R", "右ひざ"), -("ankle_R", "右足首"), -("eyes", "両目"), -("front hair1", "前髪1"), -("front hair2", "前髪2"), -("front hair3", "前髪3"), -("eyelight_L", "左目光"), -("eyelight_R", "右目光"), -("necktie3_t", "ネクタイ4"), -("hair6_L_t", "左髪7"), -("hair6_R_t", "右髪7"), -("ankle_L_t", "左つま先"), -("ankle_R_t", "右つま先"), -("necktie IK", "ネクタイIK"), -("hair IK_L", "左髪IK"), -("hair IK_R", "右髪IK"), -("leg IK_L", "左足IK"), -("leg IK_R", "右足IK"), -("toe IK_L", "左つま先IK"), -("toe IK_R", "右つま先IK"), - -("lower body_t", "下半身先"), -("head_t", "頭先"), -("eye_L_t", "左目先"), -("eye_R_t", "右目先"), -("waist accessory_t", "腰飾り先"), - -("sleeve_L_t", "左袖先"), -("wrist_L_t", "左手先"), -("thumb2_L_t", "左親指先"), -("fore3_L_t", "左人差指先"), -("middle3_L_t", "左中指先"), -("third3_L_t", "左薬指先"), -("little3_L_t", "左小指先"), -("front skirt_L_t", "左スカート前先"), -("back skirt_L_t", "左スカート後先"), - -("sleeve_R_t", "右袖先"), -("wrist_R_t", "右手先"), -("thumb2_R_t", "右親指先"), -("fore3_R_t", "右人差指先"), -("middle3_R_t", "右中指先"), -("third3_R_t", "右薬指先"), -("little3_R_t", "右小指先"), -("front skirt_R_t", "右スカート前先"), -("back skirt_R_t", "右スカート後先"), - -("center_t", "センター先"), -("eyes_t", "両目先"), -("necktie IK_t", "ネクタイIK先"), -("hair IK_L_t", "左髪IK先"), -("hair IK_R_t", "右髪IK先"), -("leg IK_L_t", "左足IK先"), -("leg IK_R_t", "右足IK先"), -("toe IK_L_t", "左つま先IK先"), -("toe IK_R_t", "右つま先IK先"), -("front hair1_t", "前髪1先"), -("front hair2_t", "前髪2先"), -("front hair3_t", "前髪3先"), -("eyelight_L_t", "左目光先"), -("eyelight_R_t", "右目光先"), -("arm twist_L_t", "左腕捩先"), -("wrist twist_L_t", "左手捩先"), -("arm twist_R_t", "右腕捩先"), -("wrist twist_R_t", "右手捩先"), -("arm twist1_L", "左腕捩1", 9), -("arm twist2_L", "左腕捩2", 9), -("arm twist3_L", "左腕捩3", 9), -("arm twist1_R", "右腕捩1", 9), -("arm twist2_R", "右腕捩2", 9), -("arm twist3_R", "右腕捩3", 9), -# -("arm twist1_L_t", "左腕捩1先"), -("arm twist2_L_t", "左腕捩2先"), -("arm twist3_L_t", "左腕捩3先"), -("arm twist1_R_t", "右腕捩1先"), -("arm twist2_R_t", "右腕捩2先"), -("arm twist3_R_t", "右腕捩3先"), -] -def getEnglishBoneName(name): - for v in boneMap: - if v[1]==name: - return v[0] - -def getIndexByEnglish(name): - for i, v in enumerate(boneMap): - if v[0]==name: - return i - -def getUnicodeBoneName(name): - for v in boneMap: - if v[0]==name: - return v - -skinMap=[ -("base", "base", 0), -("serious", "真面目", 1), -("sadness", "困る", 1), -("cheerful", "にこり", 1), -("anger", "怒り", 1), -("go up", "上", 1), -("go down", "下", 1), -("blink", "まばたき", 2), -("smile", "笑い", 2), -("wink", "ウィンク", 2), -("wink2", "ウィンク2", 2), -("wink_R", "ウィンク右", 2), -("wink2_R", "ウィンク2右", 2), -("close><", "はぅ", 2), -("calm", "なごみ", 2), -("surprise", "びっくり", 2), -("doubt", "じと目", 2), -("confuse", "なぬ!", 2), -("pupil", "瞳小", 4), -("a", "あ", 3), -("i", "い", 3), -("u", "う", 3), -("o", "お", 3), -("triangle", "▲", 3), -("regret", "∧", 3), -("omega", "ω", 3), -("omegabox", "ω□", 3), -("fool", "はんっ!", 3), -("tongue", "ぺろっ", 4), -("e-", "えー", 3), -("grin", "にやり", 3), -] -def getEnglishSkinName(name): - for v in skinMap: - if v[1]==name: - return v[0] - -def getUnicodeSkinName(name): - for v in skinMap: - if v[0]==name: - return v - -if sys.version_info[0]<3: - print('convert boneMap and skinMap to unicode...') - # python2.x - # unicodeに変換 - for i, l in enumerate(boneMap): - replace=[] - for j, m in enumerate(l): - if j==1: - replace.append(m.decode('utf-8')) - else: - replace.append(m) - boneMap[i]=replace - - for i, l in enumerate(skinMap): - replace=[] - for j, m in enumerate(l): - if j==1: - replace.append(m.decode('utf-8')) - else: - replace.append(m) - skinMap[i]=replace - print('done') - diff --git a/swig/setup.py b/swig/setup.py index e8461cf..9202076 100644 --- a/swig/setup.py +++ b/swig/setup.py @@ -36,13 +36,12 @@ if sys.version_info[0]<3: data_files=[ ('blender24', [ 'blender24/README', - 'bl24.py', - 'mqo_import.py', - 'mqo_export.py', - 'pmd_import.py', - 'pmd_export.py', - 'blender24/vmd_import.py', - ]) + 'blender/bl24.py', + 'blender/mqo_import.py', + 'blender/mqo_export.py', + 'blender/pmd_import.py', + 'blender/pmd_export.py', + ]), ] else: @@ -50,12 +49,14 @@ else: data_files=[ ('blender25', [ 'blender25/README', - 'bl25.py', - 'import_scene_mqo.py', - 'export_scene_mqo.py', - 'import_scene_pmd.py', - 'export_scene_pmd.py', - ]) + ]), + ('blender25/io', [ + 'blender/io/bl25.py', + 'blender/io/import_scene_mqo.py', + 'blender/io/export_scene_mqo.py', + 'blender/io/import_scene_pmd.py', + 'blender/io/export_scene_pmd.py', + ]), ] # スタティックruntime(/MT)とリンクするのでマニフェストが不要だが @@ -63,13 +64,13 @@ else: for i in range(len(ext_modules)+1): try: setup(name="meshio", - version='0.7', + version='0.8', description='polygon mesh io utilities', author='ousttrue', author_email='ousttrue@gmail.com', url='http://sourceforge.jp/projects/meshio/', packages=['meshio'], - package_dir={'meshio': '.'}, + package_dir={'meshio': 'meshio'}, ext_package='meshio', ext_modules=ext_modules, data_files=data_files