Need some idea to make low resource Mini-map #1962
MrWarin
started this conversation in
Ideas/Features for UPBGE 0.3+
Replies: 1 comment
-
|
Finally, I've found a low resource consume Minimap. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Does anyone know an alternative way to create a mini-map?
Right now, I’m trying to use ImageRender to capture an image from a camera and use it as a texture on a plane. But it consumes a lot of resources—probably because it calculates lighting and it's an overlay, which seems unnecessarily heavy.
`def initMinimap(self):
tex = VideoTexture.Texture(self.minimap_plane, 0)
tex.source = VideoTexture.ImageRender(self.object.scene, self.minimap_cam)
tex.source.capsize = [128, 128] # ขนาดภาพที่ render
tex.refresh(True)
self.minimap_plane["MinimapTex"] = tex
def updateMinimap(self):
if "MinimapTex" in self.minimap_plane:
self.minimap_plane['MinimapTex'].refresh(True)`
Look at the logic. it's over than 30%. it's too much.
All I really need is for the texture to move according to the player’s position.
Would it be possible to just move the UV of the texture instead? Is this feasible in UPBGE 0.36?
maybe something to do with transformUV in KX_Mesh. I guess.
I tried using a shader node to track the object’s position with the Texture Coordinate node and map it to an image texture. It can move the texture, but I still haven’t figured out how to send data into the shader node.
Beta Was this translation helpful? Give feedback.
All reactions