Updated GLFWMapRendering (markdown)

Xavier Niochaut 2020-08-12 23:18:52 +02:00
parent 2b0a1cd4e2
commit 7503a503c8

@ -21,6 +21,7 @@ You must be aware that this creates a new GLFW context and a new window. It is p
## Instantaneous rendering
*This type of rendering should be done if you plan on rarely updating the map.*
Start by calling `GLFWCapableBuffer#changeRenderingThreadToCurrent()` to bind the rendering context to the current thread.
Then call `GLFWCapableBuffer#render(Runnable)` to render your content. This will call the `Runnable` argument, swap the invisible window buffer, extract the framebuffer pixels and convert to map colors.
The map colors are available via `Framebuffer#toMapColors()` if you do not use `Framebuffer#preparePacket`.