蜂鳥の一滴《3》JunOpenGLInterface

蜂鳥の一滴:Jun for Python への道記事一覧
《3滴目》 JunOpenGLInterface

《著》小粒ちゃん、滴《監修》小泉ひよ子とタマゴ倶楽部
♪2009/04/23

■ 概要

ソースコードを自動生成するには、ctypes.CFunctionType を手掛かりに…

■ 関連記事

Tkinter vs. PyOpenGL

基本イメージにある ScheduledWindow の傘下は Tkinter で、
JunOpenGL... の傘下は PyOpenGL で…という棲み分けになっています。


将来は、Swing/Jython or WPF/IronPython という拡張も
その視野に入れたいものです。


... zap ...
暫定版として、workspace.py には、

<body package="Jun-OpenGL-Support" selector="glClearColor:with:with:with:">
glClearColor: red with: green with: blue with: alpha
    <C: void glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)>
    ^self externalAccessFailedWith: _errorCode

などのモジュールを列挙してあるだけで、その後

>>> print(PyoUtils.defs(glClearColor))
## --------
def glClearColor(self, red, green, blue, alpha):
    """
glClearColor( GLclampf(red), GLclampf(green), GLclampf(blue), GLclampf(alpha) ) -> None
    """
    print("... glClearColor #1.0")
    return glClearColor(red, green, blue, alpha)
>>> 

対話モードで、その動作を確認しています。


将来は、Workspace/Inspector を開いて、
コードを選択して、Do it/Print it/Inspect it としたいものです。

Last updated♪09/05/05