Skip to main content

A user friendly (I guess) Lib for games

Project description

pyGL is an Python Graphical Librairy for python You can do anything you want with it

DOCUMENTATION

  • Import the lib
  • After do this method :

app = Window("App name", width, height)

  • Do a while loop
  • After use the method

app.clearScreen()

  • You can set your max FPS by doing

app.setMaxFPS(maxFPS)

  • You can add a background color, you need todo

app.setBackgroundColor(color)

  • At the end you need todo an app.loop()

DRAWING/Position

  • In this Engine you have Vector2 and Transform; contains two Vector2 Object, One is Position and the other is Scale
  • Drawing a basic line is Simple :

app.DrawLine(pos1 : Vector2, pos 2 : Vector2, color, linewidth, outline)

  • Drawing a you have two methods; fast and slow
  • SLOW :

app.drawRect(Transform, color)

  • FAST :

app.fdr(x,y,w,h,c)

MOVING A TRANSFORM/SCALING

  • you can use Transfom for Moving and Scaling or just Moving by a presise axis
  • Moving

transform.Translate(movX,movY)

//Recommended : do an transform.Update()

  • Scaling

transform.Scale(scaleX,scaleY)

//Recommended : do an transform.Update()

  • Fixed Movement / Scaling

transform.x or y = VALUE OR tranform.position.x or y = VAULE

transform.w or h = VALUE OR transform.scale.x or y = VALUE

Constant usefull

Object -> an array stock all of the transform of the objects (width, height, x, y)

#Drawing Images

  • To print images you need to get them / load
  • Loading

Image = app.LoadImage(Path)

  • Print the Image

app.DisplayImage(Image, x, y)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyGL - SukyLaplante-1.1.tar.gz (14.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyGL_SukyLaplante-1.1-py3-none-any.whl (14.1 kB view details)

Uploaded Python 3

File details

Details for the file pyGL - SukyLaplante-1.1.tar.gz.

File metadata

  • Download URL: pyGL - SukyLaplante-1.1.tar.gz
  • Upload date:
  • Size: 14.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for pyGL - SukyLaplante-1.1.tar.gz
Algorithm Hash digest
SHA256 79d77006e2b73933a151774090dded8b2fe474201f4e66bd9617da35ce8fcc29
MD5 b501a27befb023090db3312e31e78007
BLAKE2b-256 567b3af842c8b0e13848617e4004cdb50ce1445f9d93c29f11ef4ed746cf6bc8

See more details on using hashes here.

File details

Details for the file pyGL_SukyLaplante-1.1-py3-none-any.whl.

File metadata

  • Download URL: pyGL_SukyLaplante-1.1-py3-none-any.whl
  • Upload date:
  • Size: 14.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1

File hashes

Hashes for pyGL_SukyLaplante-1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 22bd6cc3a0960d4c8f853e3c0fdddcbee3d0a8844ec28027230189d4dff9d304
MD5 605d8e5f9bed18a212919949fa17e02c
BLAKE2b-256 ddec413f000656f7070131262c602d6fc3208675735a9a39c8f66ddd3a8f1ccf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page