FBA The Creator

The True Multiplatform PC / PocketPC Opensource Development Tool - Read Only Mode - Kept only for historical purposes - Thank you all ;)
It is currently Sat Jun 10, 2023 6:53 am

All times are UTC




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Get Color of the point
PostPosted: Thu Aug 14, 2008 11:55 am 
Offline

Joined: Thu Aug 14, 2008 11:10 am
Posts: 8
I try to write my first game "XONIX" on your's really super languge.

But problem is that it's impossible to get color of point of the screen i mean of Default render target that is the screen!

I mean--->
I know that it possible to get color of any image imagecolor(handle, x, y, red, green, blue)
but how can i get color of a any point i need of Default render target that is the screen?

the function i sugesst can look's like this: targetcolor(handle,x,y) or pointcolor(handle,x,y)

this function will be very useful.


Top
   
PostPosted: Sat Aug 16, 2008 6:34 am 
Offline
Feejo Member
Feejo Member
User avatar

Joined: Fri Mar 28, 2008 8:07 am
Posts: 64
Location: Italy
Arnold wrote:
I try to write my first game "XONIX" on your's really super languge.

But problem is that it's impossible to get color of point of the screen i mean of Default render target that is the screen!

I mean--->
I know that it possible to get color of any image imagecolor(handle, x, y, red, green, blue)
but how can i get color of a any point i need of Default render target that is the screen?

the function i sugesst can look's like this: targetcolor(handle,x,y) or pointcolor(handle,x,y)

this function will be very useful.


You are right, there's not such a function (at least in the current documentation).
I suppose is an easy task to accomplish for the author to extend the existent imagecolor that, called with a NIL handle argument, retrieve the color of default render target.

In the meantime, as a workaround, I suggest to create a backbuffer with the screen size, set this buffer as default target, get the imagecolor you need against this image and finally, blit that on screen.

This tecnique is explained in example project #18 Particles and buffer coming with FBA.

_________________
Regards,

umbiomar
umbiomar@gmail.com


Top
   
PostPosted: Mon Aug 18, 2008 7:28 am 
Offline

Joined: Thu Aug 14, 2008 11:10 am
Posts: 8
Thanks
I DID IT.
It's OK Now
Now i still writing Xonix.

Arnold


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Limited