ET_AnimStore
-
EricTRocks
- Moderator
- Posts: 754
- Joined: 25 Nov 2009, 00:41
Re: ET_AnimStore
Also worth mentioning is that you should follow this video first before installing my addon:
http://www.vimeo.com/12097088
http://www.vimeo.com/12097088
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: ET_AnimStore
That's a nice instructional video!!! Should have thought of that myself...
However: if you're using Softimage 2011 Python should be already installed with your Softimage installation. You'd only have to edit the file "Application\python\Lib\site-packages\win32com\client\__init__.py." within your Softimage 2011 installation and edit it in a text editor (like Notepad) according to the following instruction, taken from this XSIBlog entry
"assert UnicodeToString is None, "this is deprecated and will go away"
and ending with the line
"if WrapperClass is None: WrapperClass = CDispatch")
After editing simply save (same name, same location...
Note: There might be more Python installs on your system, make sure to use the one "embedded" in your Softimage 2011 Application folder...
PS - I don't understand why this whole Dispatch stuff wasn't fixed for the internal SI|Python...
However: if you're using Softimage 2011 Python should be already installed with your Softimage installation. You'd only have to edit the file "Application\python\Lib\site-packages\win32com\client\__init__.py." within your Softimage 2011 installation and edit it in a text editor (like Notepad) according to the following instruction, taken from this XSIBlog entry
(Comment means in this case: place a "#" character in front of all the lines, beginning with the lineFind the file called %PYTHONPATH%\Lib\site-packages\win32com\client\__init__.py.
Edit the function called __WrapDispatch.
Comment all the lines inside this function except the last one that starts with return.
"assert UnicodeToString is None, "this is deprecated and will go away"
and ending with the line
"if WrapperClass is None: WrapperClass = CDispatch")
After editing simply save (same name, same location...
Note: There might be more Python installs on your system, make sure to use the one "embedded" in your Softimage 2011 Application folder...
PS - I don't understand why this whole Dispatch stuff wasn't fixed for the internal SI|Python...
Stay safe, sane & healthy!
-
ivemaker
- Posts: 10
- Joined: 12 Feb 2010, 14:24
- Skype: ivemaker
Re: ET_AnimStore
HI eric, in your tools, error with __init__.py, it because, i think, you're wrong hardware render viewport.
i use this code to render viewport and it work nice! And when i use this code I dont edit a __init__.py file
and etc. This code is based on my study of Python.
Cheers
Arthur
i use this code to render viewport and it work nice! And when i use this code I dont edit a __init__.py file
Code: Select all
currFrame = app.ActiveProject.Properties('Play Control').Parameters('Current').Value
oViewportCapture = app.Dictionary.GetObject('ViewportCapture');
app.Dictionary.GetObject("ViewportCapture.Start").Value = currFrame
app.Dictionary.GetObject("ViewportCapture.End").Value = currFrame
app.Dictionary.GetObject("ViewportCapture.Filename").Value = '1.jpg'Cheers
Arthur
-
zossowosso
- Posts: 81
- Joined: 05 Sep 2009, 04:18
Re: ET_AnimStore
hello
i have some trouble
it runs on windows seven 64bit ?
xi 2011 64bit ?
Python26 64 bit ?
python-2.4.4.ia64? (Pywin32)
the plug was installed on workegroup
the python file was edited http://www.vimeo.com/12097088
beacause i had this error
when I the Store pose:
store pose again like it mentioned in the first error:
If I use SI 2011 only the __init__.pyc file in the softimage installation need to be changed, I am wrong?
thank you
sorry for my bad English
i have some trouble
it runs on windows seven 64bit ?
xi 2011 64bit ?
Python26 64 bit ?
python-2.4.4.ia64? (Pywin32)
the plug was installed on workegroup
the python file was edited http://www.vimeo.com/12097088
beacause i had this error
when I the Store pose:
# WARNING : ET_AnimStore_PoseCam was not found and will be imported. Please press store pose again.
# INFO : 4152 - Data loaded from file D:\_3D\XSI\Workgroup\Addons\ET_AnimStore\Application\Plugins\..\..\Data\Models\ET_PoseCam.emdl was created with build number: 7.0.2008.1125 - compatibility version: 700
store pose again like it mentioned in the first error:
Code: Select all
# WARNING : ET_AnimStore_PoseCam was not found and will be imported. Please press store pose again.
# INFO : 4152 - Data loaded from file D:\_3D\XSI\Workgroup\Addons\ET_AnimStore\Application\Plugins\..\..\Data\Models\ET_PoseCam.emdl was created with build number: 7.0.2008.1125 - compatibility version: 700
Application.ImportModel("D:\\_3D\\XSI\\Workgroup\\Addons\\ET_AnimStore\\Application\\Plugins\\..\\..\\Data\\Models\\ET_PoseCam.emdl", "", "", "", "", "", "")
# INFO : ET_AnimStore_PoseCam was found.
Application.ExportAction("Sources.Gerald_Tramblay.PoseName", "D:\\_3D\\XSI\\Projet Blog\\AnimStore\\Character\\Gerald_Tramblay\\Pose\\\\Default\\PoseName\\PoseName.eani")
Application.DeleteObj("Sources.Gerald_Tramblay.PoseName")
Application.CaptureViewport(1, 0)
# ERROR : Could not export viewport capture
# ERROR : Missing an export file, pose directory deleted.If I use SI 2011 only the __init__.pyc file in the softimage installation need to be changed, I am wrong?
thank you
sorry for my bad English
'ERROR : 2011 - Unable to write well in English [CLSID\{F123FC55-ABD9-4D7F-9CDD-7F9D61E71FFE}] : %SUMATRAPATH%\ English.dll not found'
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: ET_AnimStore
Looking at your logged messages, this doesn't look like a Python problem...
Is the viewport the plugin captures from visible?
There's a mention in the video that it must be...
BTW - Editing the " __init__.py" within the Softimage Python install should do the trick, just make sure that "Use Python Installed with Softimage" is checked in the "General Preferences > Scripting Preferences".
;)
Is the viewport the plugin captures from visible?
There's a mention in the video that it must be...
BTW - Editing the " __init__.py" within the Softimage Python install should do the trick, just make sure that "Use Python Installed with Softimage" is checked in the "General Preferences > Scripting Preferences".
;)
Stay safe, sane & healthy!
-
EricTRocks
- Moderator
- Posts: 754
- Joined: 25 Nov 2009, 00:41
Re: ET_AnimStore
I'm sure this works too. However editing the __init__.py is universal and fixes more than just my scripts. Both our methods work, just one works without the __init__.py edit. I'll take your suggestion into consideration on further updates to my plug-in.ivemaker wrote:HI eric, in your tools, error with __init__.py, it because, i think, you're wrong hardware render viewport.
i use this code to render viewport and it work nice! And when i use this code I dont edit a __init__.py fileand etc. This code is based on my study of Python.Code: Select all
currFrame = app.ActiveProject.Properties('Play Control').Parameters('Current').Value oViewportCapture = app.Dictionary.GetObject('ViewportCapture'); app.Dictionary.GetObject("ViewportCapture.Start").Value = currFrame app.Dictionary.GetObject("ViewportCapture.End").Value = currFrame app.Dictionary.GetObject("ViewportCapture.Filename").Value = '1.jpg'
Cheers
Arthur
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: ET_AnimStore
The whole Python Dispatch fix issue still confuses me:
The problem originates
is the good-old mult-dispatch fix still necessary, or not?
The problem originates
However, the Softimage WIKI states the following:due to XSI returning an object with an incorrectly set multi-dispatch interface (quoted from here)
So maybe someone could answer this question once and for all:In versions prior to v6.0 XSI sometimes returned objects with an incorrectly set (as per PythonWin standards) multi-dispatch interface. This problem has been fixed in v6.0. (quoted from here)
is the good-old mult-dispatch fix still necessary, or not?
Stay safe, sane & healthy!
-
EricTRocks
- Moderator
- Posts: 754
- Joined: 25 Nov 2009, 00:41
Re: ET_AnimStore
I believe so. Otherwise people using my plug-in wouldn't have to edit the __init__.py file.Hirazi Blue wrote:The whole Python Dispatch fix issue still confuses me:
The problem originatesHowever, the Softimage WIKI states the following:due to XSI returning an object with an incorrectly set multi-dispatch interface (quoted from here)So maybe someone could answer this question once and for all:In versions prior to v6.0 XSI sometimes returned objects with an incorrectly set (as per PythonWin standards) multi-dispatch interface. This problem has been fixed in v6.0. (quoted from here)
is the good-old mult-dispatch fix still necessary, or not?
-
zossowosso
- Posts: 81
- Joined: 05 Sep 2009, 04:18
Re: ET_AnimStore
Hello everyone
Second attempt I uninstall python (C: \ Python)
I use python I provided with XI edit file __init__.py
I have another error message
When I store pose:
when i inspect pose:
With this change I do not have the same mistakes
I have a folder that is created AnimStore in my project
if I open this folder I see PoseName.htm it's a blank screenshots ??
Thank you in advance
Second attempt I uninstall python (C: \ Python)
I use python I provided with XI edit file __init__.py
I have another error message
When I store pose:
# WARNING : ET_AnimStore_PoseCam was not found and will be imported. Please press store pose again.
# INFO : 4152 - Data loaded from file C:\Users\Megacortex\Autodesk\Softimage_2011\Addons\ET_AnimStore\Application\Plugins\..\..\Data\Models\ET_PoseCam.emdl was created with build number: 7.0.2008.1125 - compatibility version: 700
when i inspect pose:
# ERROR : Erreur de syntaxe - [line 12]
# WARNING : 3000 - Error parsing D:\_3D\XSI\Projet Blog\AnimStore\Character\Biped\Pose\Default\PoseName\PoseName.htm
# ERROR : Fin d'instruction attendue - [line 4]
# ERROR : Property Page Script Logic Error (Erreur de compilation Microsoft VBScript)
# ERROR : [2] (null)
# ERROR : [3] import os
# ERROR : >[4] from win32com.client import constants as c
# ERROR : [5] from win32com.client import Dispatch as d
# ERROR : [6]
# ERROR : Fin d'instruction attendue
With this change I do not have the same mistakes
I have a folder that is created AnimStore in my project
if I open this folder I see PoseName.htm it's a blank screenshots ??
Thank you in advance
'ERROR : 2011 - Unable to write well in English [CLSID\{F123FC55-ABD9-4D7F-9CDD-7F9D61E71FFE}] : %SUMATRAPATH%\ English.dll not found'
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: ET_AnimStore
Looks like your scripting language is set to VBScript... 
Did you check the "Use Python Installed with Softimage" checkbox in the "General Preferences > Scripting Preferences" after uninstalling your " other" Python?
PS - @ Eric: you're right, your plugin doesn't work without the fix...
That still leaves the question unanswered, what is meant with the statement I quoted from the Softimage Wiki...
Did you check the "Use Python Installed with Softimage" checkbox in the "General Preferences > Scripting Preferences" after uninstalling your " other" Python?
PS - @ Eric: you're right, your plugin doesn't work without the fix...
That still leaves the question unanswered, what is meant with the statement I quoted from the Softimage Wiki...
Stay safe, sane & healthy!
-
EricTRocks
- Moderator
- Posts: 754
- Joined: 25 Nov 2009, 00:41
Re: ET_AnimStore
I don't suggest using the factory installed Python that comes with Softimage. If you do and you edit the file within that factory install, you probably need a restart of your system and after restart ensure that Python is listed as a scripting language. You probably need to have Pywin32 is still installed too.zossowosso wrote:Hello everyone
Second attempt I uninstall python (C: \ Python)
I use python I provided with XI edit file __init__.py
I have another error message
When I store pose:
# WARNING : ET_AnimStore_PoseCam was not found and will be imported. Please press store pose again.
# INFO : 4152 - Data loaded from file C:\Users\Megacortex\Autodesk\Softimage_2011\Addons\ET_AnimStore\Application\Plugins\..\..\Data\Models\ET_PoseCam.emdl was created with build number: 7.0.2008.1125 - compatibility version: 700
when i inspect pose:
# ERROR : Erreur de syntaxe - [line 12]
# WARNING : 3000 - Error parsing D:\_3D\XSI\Projet Blog\AnimStore\Character\Biped\Pose\Default\PoseName\PoseName.htm
# ERROR : Fin d'instruction attendue - [line 4]
# ERROR : Property Page Script Logic Error (Erreur de compilation Microsoft VBScript)
# ERROR : [2] (null)
# ERROR : [3] import os
# ERROR : >[4] from win32com.client import constants as c
# ERROR : [5] from win32com.client import Dispatch as d
# ERROR : [6]
# ERROR : Fin d'instruction attendue
With this change I do not have the same mistakes
I have a folder that is created AnimStore in my project
if I open this folder I see PoseName.htm it's a blank screenshots ??
Thank you in advance
Honestly it's in my opinion that you should install Python separately and follow these directions:
http://www.vimeo.com/12097088
Your error is saying that the .htm file is failing to run a VB Script. Funny because the .htm file is supposed to be running a Python script within it. Please follow the video. Also ensure that you are installing the correct version for Windows 7 64-bit:
http://usa.autodesk.com/adsk/servlet/item?siteID=123112&id=14003492
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: ET_AnimStore
As it looks you're not using Softimage 2011 I wouldn't necessarily draw too many conclusions about it. If there's a Python within your Softimage 2011 you can use it and you can edit the necessary file within this "embedded" Python without a problem... I can attest to that... ;)
edit: And I can say: the plugin works (after the fix) so it's nothing to do with the embedded version of Softimage 2011
edit: And I can say: the plugin works (after the fix) so it's nothing to do with the embedded version of Softimage 2011
Stay safe, sane & healthy!
-
zossowosso
- Posts: 81
- Joined: 05 Sep 2009, 04:18
Re: ET_AnimStore
Hello Eric
ok I tried with a fresh installation of python
it's stange beacause if i don't edit the __init__.py file i see your plug
but if I edit I no longer see it
I think I have a problem here I'm sure the plug is correct
I'll try to find the problem thank you again for this attention
ok I tried with a fresh installation of python
it's stange beacause if i don't edit the __init__.py file i see your plug
but if I edit I no longer see it
I think I have a problem here I'm sure the plug is correct
I'll try to find the problem thank you again for this attention
New Error
the way I install
Instructions for installing python on Windows Vista and XP 64bit.
NOTE: All required files are supplied with PythonInstall64.zip
1) Put User Account Control (UAC) to off (Vista only)
http://technet2.microsoft.com/WindowsVista/en/library/0d75f774-8514-4c9e-ac08-4c21f5c6c2d91033.mspx?mfr=true
2) Install VC 2005 and VC 2008 Redist
vcredist_x86.exe
vcredist_x64.exe
3) Install Python 2.6
python-2.6b2.64
NOTE: Python 2.6 version is now required for vista and XP 64, older versions of python cannot be supported.
4) Add the python folder installation (e.g. C:\python26) to the PATH environment variable as the installer won't do it by default.
5) Install pywin32: pywin32-212.win-64-py2.6.exe
# INFO : ET_AnimStore_PoseCam was found.
# ERROR : Traceback (most recent call last):
# File "<Script Block >", line 341, in ET_AnimStore_StorePose_OnClicked
# oPoseTextMesh.Properties["visibility"].viewvis = 1
# File "C:\Python26\lib\site-packages\win32com\gen_py\269C4D8C-E32D-11D3-811D-00A0C9AC19A9x0x1x0\PropertyCollection.py", line 96, in __getitem__
# return self._enum_.__getitem__(index)
# File "C:\Python26\Lib\site-packages\win32com\client\util.py", line 37, in __getitem__
# return self.__GetIndex(index)
# File "C:\Python26\Lib\site-packages\win32com\client\util.py", line 42, in __GetIndex
# if type(index)!=type(0): raise TypeError, "Only integer indexes are supported for enumerators"
# TypeError: Only integer indexes are supported for enumerators
# - [line 340 in C:\Users\Megacortex\Autodesk\Softimage_2011\Addons\ET_AnimStore\Application\Plugins\ET_AnimStore.py]
# ERROR : Property Page Script Logic Error (Python ActiveX Scripting Engine)
# ERROR : [338] else:
# ERROR : [339]
# ERROR : >[340] # Unhide pose text mesh to capture with icon
# ERROR : [341] oPoseTextMesh.Properties["visibility"].viewvis = 1
# ERROR : [342]
# ERROR : [343] oModel = PPG.Inspected(0).Model
# ERROR : Traceback (most recent call last):
# File "<Script Block >", line 341, in ET_AnimStore_StorePose_OnClicked
# oPoseTextMesh.Properties["visibility"].viewvis = 1
# File "C:\Python26\lib\site-packages\win32com\gen_py\269C4D8C-E32D-11D3-811D-00A0C9AC19A9x0x1x0\PropertyCollection.py", line 96, in __getitem__
# return self._enum_.__getitem__(index)
# File "C:\Python26\Lib\site-packages\win32com\client\util.py", line 37, in __getitem__
# return self.__GetIndex(index)
# File "C:\Python26\Lib\site-packages\win32com\client\util.py", line 42, in __GetIndex
# if type(index)!=type(0): raise TypeError, "Only integer indexes are supported for enumerators"
# TypeError: Only integer indexes are supported for enumerators
#
'ERROR : 2011 - Unable to write well in English [CLSID\{F123FC55-ABD9-4D7F-9CDD-7F9D61E71FFE}] : %SUMATRAPATH%\ English.dll not found'
-
EricTRocks
- Moderator
- Posts: 754
- Joined: 25 Nov 2009, 00:41
Re: ET_AnimStore
In your video you don't mention editing the __init__.py file. Did you do this? This is essential!!!! This is where the error is coming from.
Also after you deactivate the factory Python install, restart Softimage.
Also, you have the ET_AnimStore set to capture from viewport A. Viewport A isn't visible. You must have it visible.
Also after you deactivate the factory Python install, restart Softimage.
Also, you have the ET_AnimStore set to capture from viewport A. Viewport A isn't visible. You must have it visible.
-
Hirazi Blue
- Administrator
- Posts: 5113
- Joined: 04 Jun 2009, 10:15
Re: ET_AnimStore
@Eric
I still haven't heard any convincing reason why not to use the Python installed with Softimage 2011.
I assume there is one, please share it with us... ;)
I still haven't heard any convincing reason why not to use the Python installed with Softimage 2011.
I assume there is one, please share it with us... ;)
Stay safe, sane & healthy!
-
EricTRocks
- Moderator
- Posts: 754
- Joined: 25 Nov 2009, 00:41
Re: ET_AnimStore
Personally I don't like editing stuff pre-installed via the Softimage installer. Having users dig around in the installation isn't good. Who knows what could get mucked up and they may need to reinstall from scratch. Guess that is just some weariness I get from working at a studio where Animator's (people who will be using this plug-in) may not be the most technical savvy folks.
With that said I'm changing my code over to Arthur's example to see if I can get away with not having to have users edit that file.
Will post back soon.
With that said I'm changing my code over to Arthur's example to see if I can get away with not having to have users edit that file.
Will post back soon.