This version of NodeBox for OpenGL has been developed by the City In A Bottle team, with funding support from the Flemish Audiovisual Fund (VAF). It's not as fast as anything in native C, but quite a bit faster than the classic NodeBox. NodeBox for OpenGL can be used for simple games, interactive media installations, data visualization and image compositing. The original goal is to implement a small game engine for City In A Bottle. It opens the main application window with n().įrom import Flock It defines a draw() function and attaches it to the canvas, so that it will be drawn each animation frame. It imports the aphics module with the standard set of drawing commands. To get started, try out some examples, or open and edit examples/test.py.īelow is a typical NodeBox script. This will open an application window with the output of your script. The documentation works in conjunction with the examples folder: subjects are touched here and demonstrated in more detail across various examples.įrom the command line, you can run a script with: python example.py (or command-R in TextMate). Users are assumed to have knowledge of Python (functions & classes) and NodeBox (the original docs are more verbose). You can use the IDLE editor bundled with Python. NodeBox for OpenGL does not have a built-in code editor. You'll need a 32-bit Python (version 2.5 or 2.6) and Pyglet to run it. Screenshot: examples/07-filter/03-mirror.py Quick overview It has built-in support for paths, layers, motion tweening, hardware-accelerated image effects, simple physics and interactivity. It is built on Pyglet and adopts the drawing API from NodeBox for Mac OS X ( ). You could however have many mapblocks that have each one of your node and are otherwise filled with air.Īnyway, if it's an artificial, sparsely used node, you shouldn't have to worry too much about performance.NodeBox for OpenGL is a free, cross-platform library for generating 2D animations with Python programming code. Having more than one of the node in a mapblock doesn't increase the tile type count per mapblock. I have to correct myself in how one would benchmark this. Performance is mostly same, but texturing is much easier now and I finally have some normal mesh experience! Sure, probably will that after creating mesh.Īnd did. place many lamps with worldedit and compare fps). But to be sure, you should try it out and do benchmarks (i.e. But if you have something like your lamp and only use one tile (and hence only one material in the mesh), it will probably be faster. cobble stairs), meshes probably won't be faster. So, if you use the same tile on every node face (e.g. And there's always one meshbuffer per mapblock per tile type. Minetest map rendering speed is mostly bottlenecked through the amount of drawcalls. Oh, and if you'll put it on glass or barrier and look from bottom you'll see that bottom part of it's stand is actually containing a lamp inside (*sigh*) I may keep other blocks in my mod nodeboxed (like armchairs which don't have any problems with texturing), but things like table lamp are painful to look at. If I've used model, I could use normal UV-mapping and make the stand steel without making the top part steel as well (which is very ugly and totally unsuitable). There's a screenshot of this table lamp:Īs you can see, I've used wool for both parts of it just because I can't do otherwise (like make that steel look like if it was made from iron (equivalent to MTG's steel)) so it's looking weird. Even if performance is same, texturing objects like table lamp in nodeboxes is VERY difficult. I didn't verify that, but benchmarks from others are telling that models are faster. On the other hand, you could remove some faces you know won't be visible. Have you actually verified that the models are more performant? On the one hand, Minetest can do some culling on nodeboxes that isn't done as easily for models.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |