Is it posiible to use an image as a progressbar by trimming it according to time?
Varying the xscale and yscale doesn’t trim the image…So is there a way to do it(as in the image)?
Is it posiible to use an image as a progressbar by trimming it according to time?
Varying the xscale and yscale doesn’t trim the image…So is there a way to do it(as in the image)?
Just off my head, not tested, you could use an image mask or a display container, provided they can be adjusted in realtime, which I assume you are after.
May be use two images for red and green parts. Then scale it separately. Also consider different type of progress bar.
ldurniat
@Idurniat beat me to it. I would draw two display.newRect()s or display.newImageRect()s on top of each other. For the top one, set the yScale to 0 and over time increase the yScale until it completely covers the bottom image.
Rob
Thanks…!
Just off my head, not tested, you could use an image mask or a display container, provided they can be adjusted in realtime, which I assume you are after.
May be use two images for red and green parts. Then scale it separately. Also consider different type of progress bar.
ldurniat
@Idurniat beat me to it. I would draw two display.newRect()s or display.newImageRect()s on top of each other. For the top one, set the yScale to 0 and over time increase the yScale until it completely covers the bottom image.
Rob
Thanks…!