<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Hey all,<br>
<br>
for claryfication ... I can read write armatures in the GE now?!<br>
This is what I understood from the last mails :)<br>
<br>
My goal is to write a time triggered script which manipulates the
armature.<br>
<br>
Benoit - if so, can you provide us with some sample code?<br>
<br>
BTW: You build works fine on Ubuntu (32Bit) ) 9.04<br>
<br>
<br>
Cheers, Florian<br>
<br>
<br>
Benoit Bolsee wrote:
<blockquote cite="mid:CE4AFF92E2034862B6991B53E33D5D9E@Benoit95"
 type="cite">
  <pre wrap="">Blender 2.5 needs Python 3.1 indeed (at least the GE). 
Regarding Blender module, yes it's gone, you need to switch to the new
RNA and operator API.
You have the documentation (still partial) here :
 <a class="moz-txt-link-freetext" href="http://www.graphicall.org/ftp/ideasman42/html/bpy-module.html">http://www.graphicall.org/ftp/ideasman42/html/bpy-module.html</a>

The principle is that you get reference to the data block you want to
manipulate from the context
(<a class="moz-txt-link-freetext" href="http://www.graphicall.org/ftp/ideasman42/html/bpy.types.Context-class.h">http://www.graphicall.org/ftp/ideasman42/html/bpy.types.Context-class.h</a>
tml): you start from the main and dig through it.

Afaik it's not available in the GE yet.
So in the GE you must stick with GE API only, which hasn't changed.
You will noticed that I implemented proxy classes in the GE to bone,
pose channel, and armatures. So you don't need bpy for that.

I hope this news are not too disappointing ;-)

Regards,
Benoit



  </pre>
  <blockquote type="cite">
    <pre wrap="">-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:robotics-bounces@blender.org">robotics-bounces@blender.org</a> 
[<a class="moz-txt-link-freetext" href="mailto:robotics-bounces@blender.org">mailto:robotics-bounces@blender.org</a>] On Behalf Of Markus Mehrwald
Sent: vendredi 11 septembre 2009 16:04
To: Blender and Robotics
Subject: Re: [Robotics] Python control of armature in the GE


Hi Benoit,

I figured out some other problems now. I got Blender to compile only 
with Pyhton 3.1 but now I cannot use my scripts anymore with 
the error:

Traceback (most recent call last):
   File "Steuerung.py", line 4, in &lt;module&gt;
ImportError: No module named Blender

Do you know what this could be or is there already a 
documentation for 2.5?

Thanks,
Markus

Benoit Bolsee schrieb:
    </pre>
    <blockquote type="cite">
      <pre wrap="">I fixed CMake in the itasc branch. Sorry for the delay.

/benoit

      </pre>
      <blockquote type="cite">
        <pre wrap="">-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:robotics-bounces@blender.org">robotics-bounces@blender.org</a>
[<a class="moz-txt-link-freetext" href="mailto:robotics-bounces@blender.org">mailto:robotics-bounces@blender.org</a>] On Behalf Of Markus Mehrwald
Sent: vendredi 11 septembre 2009 11:21
To: Blender and Robotics
Subject: Re: [Robotics] Python control of armature in the GE


Hi,

I just managed it to compile the branch with the ikplugin. For some
reasons I was not able to compile because of a few errors. I 
think its 
just some little changes in the CMake files. First of all the 
BIK_api.h 
was not found. I did it quick and dirty by copying the full 
path in the 
files where it is needed. The second thing was that obviously 
the libs 
bf_ikplugin and bf_ITASC are not in the list of libs to link 
against. Maybe you did not update the CMakeList or was it a 
problem of my computer?

Regards,
Markus


Benoit Bolsee schrieb:
        </pre>
        <blockquote type="cite">
          <pre wrap="">Hi,
 
I have added support for controlling armatures through
          </pre>
        </blockquote>
        <pre wrap="">Python in the
        </pre>
        <blockquote type="cite">
          <pre wrap="">GE.
This is provided through the new proxy class
          </pre>
        </blockquote>
        <pre wrap="">BL_ArmatureChannel that
        </pre>
        <blockquote type="cite">
          <pre wrap="">corresponds to the pose channel structure. Most attributes match
directly the Blender bPoseChannel structure but I added a 
'joint_rotation' attribute that gives direct access to 
          </pre>
        </blockquote>
        <pre wrap="">joint angles. You
        </pre>
        <blockquote type="cite">
          <pre wrap="">can use this attribute to set the joint angles from
          </pre>
        </blockquote>
        <pre wrap="">external data or
        </pre>
        <blockquote type="cite">
          <pre wrap="">your own calculation and the armature will move according
          </pre>
        </blockquote>
        <pre wrap="">to it. If the
        </pre>
        <blockquote type="cite">
          <pre wrap="">armature is controlled by IK, you can read the joint angles
          </pre>
        </blockquote>
        <pre wrap="">computed by
        </pre>
        <blockquote type="cite">
          <pre wrap="">the algorithm. Full details is provided in the BPY documentation
included in the packages below. Download them if you want 
          </pre>
        </blockquote>
        <pre wrap="">to know more
        </pre>
        <blockquote type="cite">
          <pre wrap="">about it.
 
Other fix in this build is correct matrix operation with 
          </pre>
        </blockquote>
      </blockquote>
    </blockquote>
    <pre wrap="">MathUtils:
    </pre>
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap=""><a class="moz-txt-link-freetext" href="http://lists.blender.org/pipermail/bf-blender-cvs/2009-Septemb">http://lists.blender.org/pipermail/bf-blender-cvs/2009-Septemb</a>
er/022245.html
        </pre>
        <blockquote type="cite">
          <pre wrap=""> 
For those who want to experiment, I made two builds on graphicall:
 
Linux:

          </pre>
        </blockquote>
        <pre wrap=""><a class="moz-txt-link-freetext" href="http://graphicall.org/builds/builds/showbuild">http://graphicall.org/builds/builds/showbuild</a>.&gt;
        </pre>
      </blockquote>
      <pre wrap="">php?action=show&amp;id=1082
      </pre>
      <blockquote type="cite">
        <pre wrap="">&lt;<a class="moz-txt-link-freetext" href="http://graphicall.org/builds/builds/showbuild.php?action=show">http://graphicall.org/builds/builds/showbuild.php?action=show</a>
        </pre>
      </blockquote>
      <pre wrap="">&amp;id=1082&gt;
      </pre>
      <blockquote type="cite">
        <pre wrap="">Windows:

        </pre>
      </blockquote>
    </blockquote>
    <pre wrap=""><a class="moz-txt-link-freetext" href="http://graphicall.org/builds/builds/showbuild">http://graphicall.org/builds/builds/showbuild</a>.&gt;
    </pre>
  </blockquote>
  <pre wrap=""><!---->php?action=show&amp;id=1080 
  </pre>
  <blockquote type="cite">
    <pre wrap=""><a class="moz-txt-link-rfc2396E" href="http://graphicall.org/builds/builds/showbuild">&lt;http://graphicall.org/builds/builds/showbuild&gt;</a>
    </pre>
  </blockquote>
  <pre wrap=""><!---->.php?action=show&amp;id=1080
  </pre>
  <blockquote type="cite">
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap=""> 
If your system is not in this list, you can check out the itasc 
branch and compile. For those interested in the 
        </pre>
      </blockquote>
    </blockquote>
    <pre wrap="">implementation, look 
    </pre>
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap="">at the BL_ArmatureChannel.cpp module in 
        </pre>
      </blockquote>
    </blockquote>
    <pre wrap="">source/gameengine/converter. 
    </pre>
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap="">If
        </pre>
      </blockquote>
      <pre wrap="">you
      </pre>
      <blockquote type="cite">
        <pre wrap="">have some ideas to extend the API, you are welcome to make your own
additions and send me the diff, I will review and commit 
        </pre>
      </blockquote>
    </blockquote>
    <pre wrap="">them to SVN.
    </pre>
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap=""> 
The itasc branch will be merged with 2.5 in the coming 
        </pre>
      </blockquote>
    </blockquote>
    <pre wrap="">days, it would
    </pre>
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap="">be
nice to get some feedback before I start the merge.
 
/benoit.
 



        </pre>
      </blockquote>
    </blockquote>
    <pre wrap="">---------------------------------------------------------------------
    </pre>
    <blockquote type="cite">
      <blockquote type="cite">
        <pre wrap="">-
--

_______________________________________________
Robotics mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Robotics@blender.org">Robotics@blender.org</a>
<a class="moz-txt-link-freetext" href="http://lists.blender.org/mailman/listinfo/robotics">http://lists.blender.org/mailman/listinfo/robotics</a>
        </pre>
      </blockquote>
    </blockquote>
    <pre wrap="">_______________________________________________
Robotics mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Robotics@blender.org">Robotics@blender.org</a>
<a class="moz-txt-link-freetext" href="http://lists.blender.org/mailman/listinfo/robotics">http://lists.blender.org/mailman/listinfo/robotics</a>

    </pre>
  </blockquote>
  <pre wrap=""><!---->
_______________________________________________
Robotics mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Robotics@blender.org">Robotics@blender.org</a>
<a class="moz-txt-link-freetext" href="http://lists.blender.org/mailman/listinfo/robotics">http://lists.blender.org/mailman/listinfo/robotics</a>

  </pre>
</blockquote>
<br>
</body>
</html>