Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
What do you use RenderTarget for? — Gideros Forum

What do you use RenderTarget for?

edited August 2016 in General questions
I know this is too common question, but after google and search in forum threads, I still can not understand clearly what is render target use for? And how it resolved your "problem" ? How to use it to boost our game performance?
I am waiting explain from you here :D , thank you so much!
Coming soon

Comments

  • totebototebo Member
    edited August 2016 Accepted Answer
    RenderTarget is a magic thing which lets you copy the visible pixels of any sprite. This is useful for screenshots, especially now when you can also save the RenderTarget to disk as an image.

    It has to some degree been replaced by setClip(), which now lets you crop a sprite. This was my main use for RenderTarget before setClip() was added.
    My Gideros games: www.totebo.com
    +1 -1 (+1 / -0 )Share on Facebook
  • piepie Member
    edited August 2016 Accepted Answer
    As totebo said, I was using it to "setClip" before setClip() was available, now I use it to apply shaders; with the new feature to save the rendertarget as png I use it also to "prepare" textures (remove background from textures exported by spriteilluminator by code&web which export a background even if the source sprites have alpha borders)
    Another use I do of it is a basic lighting/fog of war (http://giderosmobile.com/forum/discussion/5879/basic-view-range-lighting-effect/p1)

    I'm planning to use it to create texturepacks on the run, and to save screenshots too, but I have not investigated those uses yet :)

    +1 -1 (+1 / -0 )Share on Facebook
  • hgy29hgy29 Maintainer
    Accepted Answer
    I use RenderTarget for dynamic texture creation: I draw complex shape on them once and the result is displayed multiple times as bitmap.
    Som examples I wrote also use it for multiple pass rendering (ex: bloom shader).
    Lately I've been using it for capturing live video from camera device (snap shot) and saving that for later upload to a server.
    +1 -1 (+1 / -0 )Share on Facebook
  • antixantix Member
    Accepted Answer
    RenderTargets are great and like @pie I want to use them to create special TexturePacks. I tried once and found a bug that got fixed recently so I'll look into that soon.

    RenderTarget would be way more powerful if you could use it as a real texture, which can use wrap. Wrap is such a powerful part of textures I think.
    +1 -1 (+1 / -0 )Share on Facebook
  • hgy29hgy29 Maintainer
    RenderTarget would be way more powerful if you could use it as a real texture, which can use wrap.
    And it is so simple to add this to Gideros! Maybe in 2016.9 then :)

  • Cool, maybe I'll still be here by then ;)
  • SinisterSoftSinisterSoft Maintainer
    Accepted Answer
    I use rendertexture in the soon to be release new version of Bacteria to do a pixel fade over time effect (by not clearing the texture fully each frame) and also a bloom effect (a simple bloom shader attached to the sprite that points to the render texture).

    You can see the result here:
    http://www.sinistersoft.com/bacteria/gideros.html

    The actual sprites are path2D objects.
    Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!).
    https://deluxepixel.com
    +1 -1 (+1 / -0 )Share on Facebook
  • @SinisterSoft pretty cool man :)

    Likes: SinisterSoft

    +1 -1 (+1 / -0 )Share on Facebook
  • Thank you so much guys!
    Coming soon
  • edited August 2016
    Duplicated post
    Coming soon
Sign In or Register to comment.