Skip to content

Commit

Permalink
Merge pull request #25 from miu200521358/work_5.01_cython3
Browse files Browse the repository at this point in the history
ver5.01.01
  • Loading branch information
miu200521358 authored Dec 19, 2020
2 parents 5a68c8e + 92f52dc commit 78a4bb8
Show file tree
Hide file tree
Showing 13 changed files with 404 additions and 31 deletions.
14 changes: 7 additions & 7 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"request": "launch",
"program": "${workspaceFolder}/src/executor.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
// "--motion_path", "E:/MMD/MikuMikuDance_v926x64/Work/202001_sizing/肩/折岸みつ肩2.vmd",
Expand Down Expand Up @@ -166,7 +166,7 @@
"request": "launch",
"program": "${workspaceFolder}/src/executor_smooth.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
// "--motion_path", "E:/MMD/MikuMikuDance_v926x64/Work/201805_auto/misozi/kenbu/kenbu3_20190429_205936/kenbu3_json_20190429_205936_idx01/あにまさ式ミクボーン_20190429_210136_h0.0_z1.0_s1_p0.5_r3.0_reduce.vmd",
Expand Down Expand Up @@ -203,7 +203,7 @@
"request": "launch",
"program": "${workspaceFolder}/src/blend_pmx.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
"--pmx_path", "D:/MMD/MikuMikuDance_v926x64/UserFile/Model/VOCALOID/初音ミク/Tda式デフォ服ミク_ver1.1 金子卵黄/Tda式初音ミク_デフォ服ver.pmx",
Expand All @@ -219,7 +219,7 @@
"request": "launch",
"program": "${workspaceFolder}/src/executor.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
"--verbose", "20",
Expand All @@ -232,7 +232,7 @@
"request": "launch",
"program": "${workspaceFolder}/../motion_supporter/src/executor.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
"--verbose", "10",
Expand All @@ -245,7 +245,7 @@
"request": "launch",
"program": "${workspaceFolder}/src/thread.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
"--verbose", "20",
Expand All @@ -258,7 +258,7 @@
"request": "launch",
"program": "${file}",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}",
"python": "${command:python.interpreterPath}",
"stopOnEntry": false,
"args": [
]
Expand Down
8 changes: 6 additions & 2 deletions archive/Readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

�@�uVMD�T�C�W���O�@���[�J���Łv

�@�@ver5.01
�@�@ver5.01.01

�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@�@miu200521358

Expand Down Expand Up @@ -44,7 +44,7 @@ https://seiga.nicovideo.jp/seiga/im9755721
���@�����t�@�C��
----------------------------------------------------------------

�@�EVMDSizing_5.01_64bit.exe�@�@�@�c�@�c�[���{�́iver5.00���64bit�ł݂̂ł��j
�@�EVMDSizing_5.01.01_64bit.exe�@�@�@�c�@�c�[���{�́iver5.00���64bit�ł݂̂ł��j
�@�EReadme.txt�@�@�@�@�@�@�@�@�@�@�c�@���h�~
�@�EVMD�T�C�W���OWiki�@�@�@�@�@�@ �c�@Wiki�ւ̃����N
�@�E�R���e���c�c���[�p�É�@�@�@�@�c�@�R���e���c�c���[�p�É�ւ̃����N
Expand All @@ -69,6 +69,7 @@ https://seiga.nicovideo.jp/seiga/im9755721

�E���O����ł́Av4�̍��̂悤�ɁA�o��VMD�t�@�C���p�X�Ɠ����Ƃ���Ƀ��O�t�@�C�����o�͂��܂��B

�E�t�@�C�������́A�uhistory.json�v��exe�Ɠ����K�w�ɔz�u���鎖�ŃR�s�[�”\�ł��B

----------------------------------------------------------------
���@�T�C�W���O�@�\
Expand Down Expand Up @@ -396,6 +397,9 @@ https://github.com/miu200521358/vmd_sizing
���@����
----------------------------------------------------------------

ver5.01.01�@�i2020/12/20�j
�@�@�EBugfix: �����l�T�C�W���O�Ń��[�t�u���̏㏑������Ɏ��s����ꍇ���������̂��C��

ver5.01�@�i2020/11/21�j
�@�@�E�����̍������i��30%�X�s�[�h�A�b�v�j
�@�@�E�i���X�e�[�^�X�\���@�\�lj�
Expand Down
2 changes: 1 addition & 1 deletion src/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
from service.SizingService import SizingService
from utils.MException import SizingException

VERSION_NAME = "ver5.01"
VERSION_NAME = "ver5.01.01"

# 指数表記なし、有効小数点桁数6、30を超えると省略あり、一行の文字数200
np.set_printoptions(suppress=True, precision=6, threshold=30, linewidth=200)
Expand Down
4 changes: 2 additions & 2 deletions src/form/worker/SizingWorkerThread.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,8 @@ def thread_event(self):
if self.frame.arm_panel_ctrl.arm_process_flg_avoidance.GetValue() > 0:
self.frame.file_panel_ctrl.tree_process_dict[proccess_key]["接触回避"] = False

morph_list, morph_seted = self.frame.morph_panel_ctrl.get_morph_list(file_set.set_no, self.frame.file_panel_ctrl.file_set.motion_vmd_file_ctrl.data.digest, \
self.frame.file_panel_ctrl.file_set.org_model_file_ctrl.data.digest, self.frame.file_panel_ctrl.file_set.rep_model_file_ctrl.data.digest) # noqa
morph_list, morph_seted = self.frame.morph_panel_ctrl.get_morph_list(file_set.set_no, file_set.motion_vmd_file_ctrl.data.digest, \
file_set.org_model_file_ctrl.data.digest, file_set.rep_model_file_ctrl.data.digest) # noqa
if morph_seted:
total_process += 1 # モーフ置換
self.frame.file_panel_ctrl.tree_process_dict[proccess_key]["モーフ置換"] = False
Expand Down
1 change: 1 addition & 0 deletions src/mmd/PmxData.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ cdef class PmxModel:
cdef public dict bones
cdef public dict bone_indexes
cdef public dict morphs
cdef public dict morph_indexes
cdef public dict display_slots
cdef public dict rigidbodies
cdef public dict rigidbody_indexes
Expand Down
4 changes: 3 additions & 1 deletion src/mmd/PmxData.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -918,6 +918,8 @@ cdef class PmxModel:
self.bone_indexes = {}
# モーフデータ(順番保持)
self.morphs = {}
# モーフINDEXデータ(キー:モーフINDEX、値:モーフ名)
self.morph_indexes = {}
# 表示枠データ
self.display_slots = {}
# 剛体データ
Expand Down Expand Up @@ -1096,7 +1098,7 @@ cdef class PmxModel:
start_type_bone = target_bone_name[1:]

# 自分をリンクに登録
links.append(self.bones[target_bone_name].copy())
links.append(self.bones[target_bone_name])

parent_name = None
if is_defined:
Expand Down
3 changes: 2 additions & 1 deletion src/mmd/PmxReader.py
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,6 @@ def read_data(self):
pmx.bone_indexes[leg_center_bone.index] = leg_center_bone.name

logger.test("len(bones): %s", len(pmx.bones))
logger.test("bone_indexes: %s", pmx.bone_indexes.items())

logger.info("-- PMX ボーン読み込み完了")

Expand Down Expand Up @@ -617,6 +616,8 @@ def read_data(self):

# モーフのINDEXは、先頭から順番に設定
morph.index = morph_idx
# インデックス逆引きも登録
pmx.morph_indexes[morph.index] = morph.name

if morph.panel not in morphs_by_panel.keys():
# ないと思うが念のためパネル情報がなければ追加
Expand Down
20 changes: 20 additions & 0 deletions src/mmd/VmdData.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,14 @@ cdef class VmdBoneFrame:
cdef public bint read
cdef public str avoidance

cdef class VmdMorphFrame:
cdef public str name
cdef public bytes bname
cdef public int fno
cdef public float ratio
cdef public bint key
cdef public bint read

cdef class VmdMotion:
cdef public str path
cdef public str signature
Expand Down Expand Up @@ -90,6 +98,18 @@ cdef class VmdMotion:

cdef reset_interpolation_parts(self, str target_bone_name, VmdBoneFrame bf, list bzs, list x1_idxs, list y1_idxs, list x2_idxs, list y2_idxs)

cdef c_regist_full_mf(self, int data_set_no, list morph_name_list, int offset, bint is_key)

cdef c_regist_mf(self, VmdMorphFrame mf, str morph_name, int fno)

cdef VmdMorphFrame c_calc_mf(self, str morph_name, int fno, bint is_key, bint is_read)

cdef c_smooth_filter_mf(self, int data_set_no, str morph_name, int loop, dict config, int start_fno, int end_fno, bint is_show_log)

cdef c_remove_unnecessary_mf(self, int data_set_no, str morph_name, double offset, double diff_limit, int r_start_fno, int r_end_fno, bint is_show_log, bint is_force)

cdef reduce_morph_frame(self, str morph_name, list fnos, int head, int tail, float threshold)

cpdef bint is_active_bones(self, str bone_name)


Expand Down
Loading

0 comments on commit 78a4bb8

Please sign in to comment.