Categories
teaching

Objets connectés / Raspberry Pi + Python

workshop de 4 jours donné à imal cet été, du 30 juillet au 2 août

repository: https://gitlab.com/frankiezafe/pyhon-iot

wiki: https://wiki.imal.org/workshop/objets-connectés-raspbery-pi-python

au programme: webserver & pyton, un peu de video processing (évidemment) et un passage rapide dans pygame

Categories
Uncategorized

Generation of a 3d grid of cells each…

Generation of a 3d grid of cells, each one of the cells knows who are the surrounding ones. This to speed up searching around the current cell.

To generate a unique id for each one of the surrounding cell, and quickly find the current cell in the surrounding cell, i used a python that generates a list of enum and a map of opposition. Therefore, when I create a new cell in the grid, its very fast to register it into all the existing ones.

Categories
Uncategorized

Buildings generation is on its way A texture…

Buildings generation is on its way.

A texture controlling the border of the building has been tuned via a python script. Based on a source image:

the script generate this:

The brightness is changing gradually and is controlled by the source image pixels. This avoids the basic gradient.

Categories
Uncategorized

Documentation about how to prepare meshes structure materials…

Documentation about how to prepare meshes (structure, materials, etc.) usable by bullet in polymorph engine.

>> https://bitbucket.org/polymorphteam/pe.2.0/wiki/blender-bullet-primitives

The documentation of the project is not yet ready, as you might see if you surf a bit in the wiki…

polymorph-physics-primitives-im

Categories
Uncategorized

Two python scripts to help work in blender…

Two python scripts to help work in blender:

  • one script, material-generator-for-physics.py, generate a bunch of “ogre-bullet” material, with correct prefixes;
  • second one, material-from-physics.py, applies these materials on selected objects depending on the type of rigidbody attached.

This process must be done before joining all the objects into 1 mesh and exporting it for ogre.

screen-mat-generation

Scripts are available in PE.2.0 assets folder.

Categories
Uncategorized

Algorithmic object creation The work started yesterday wit…

Algorithmic object creation.

The work started yesterday wit @balt starts to fall into place. All vertices are generated at the right location and in a logical order (see right part of the image), making it possible to construct the faces “easily”. But it’s anyway a hell of +, -, * and % 🙂

Selection_662