improve docs, make clear different APIs and static/dynamic
This commit is contained in:
parent
47c4d0d1b4
commit
9e17046408
49 changed files with 5467 additions and 17850 deletions
|
@ -3,9 +3,7 @@ This shows how to use the CFFI static (API) binding. It should be fast and code
|
|||
C code.
|
||||
"""
|
||||
|
||||
import raylib as rl
|
||||
from raylib import ffi
|
||||
from raylib.colors import *
|
||||
from raylib import ffi, rl, colors
|
||||
|
||||
rl.InitWindow(800, 450, b"Raylib dynamic binding test")
|
||||
rl.SetTargetFPS(60)
|
||||
|
@ -24,11 +22,11 @@ rl.SetCameraMode(camera[0], rl.CAMERA_ORBITAL)
|
|||
while not rl.WindowShouldClose():
|
||||
rl.UpdateCamera(camera)
|
||||
rl.BeginDrawing()
|
||||
rl.ClearBackground(RAYWHITE)
|
||||
rl.ClearBackground(colors.RAYWHITE)
|
||||
rl.BeginMode3D(camera[0])
|
||||
rl.DrawModel(model, (-8.0, 0.0, -8.0), 1.0, RED)
|
||||
rl.DrawModel(model, (-8.0, 0.0, -8.0), 1.0, colors.RED)
|
||||
rl.DrawGrid(20, 1.0)
|
||||
rl.EndMode3D()
|
||||
rl.DrawText(b"This mesh should be textured", 190, 200, 20, VIOLET)
|
||||
rl.DrawText(b"This mesh should be textured", 190, 200, 20, colors.VIOLET)
|
||||
rl.EndDrawing()
|
||||
rl.CloseWindow()
|
||||
|
|
Reference in a new issue