If you have a problem or need to report a bug please email : support@dsprobotics.com
There are 3 sections to this support area:
DOWNLOADS: access to product manuals, support files and drivers
HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects
USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here
NEW REGISTRATIONS - please contact us if you wish to register on the forum
Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright
is there a way to get a trigger that confirms...
6 posts
• Page 1 of 1
is there a way to get a trigger that confirms...
Is there a way to get a trigger that confirms, that gui element was refreshed/redrawed? Something sent from somewhere after successful redraw. It's for operations on hidden elements, and it can't be done with timers.
(FS304)
(FS304)
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
Feel free to donate. Thank you for your contribution.
- tester
- Posts: 1786
- Joined: Wed Jan 18, 2012 10:52 pm
- Location: Poland, internet
Re: is there a way to get a trigger that confirms...
Off the top of my head, you could route whatever triggers are going to the redraw prim to wherever else you need it and just use a trigger switch with the Editor Open prim to block the triggers if the window is closed.
Not sure if that's good enough for what you're trying to accomplish.
Not sure if that's good enough for what you're trying to accomplish.
- Perfect Human Interface
- Posts: 643
- Joined: Sun Mar 10, 2013 7:32 pm
Re: is there a way to get a trigger that confirms...
i use this:
it send an trig every time the portion of view is refreshed.
- Code: Select all
def draw v
output 0, nil
end
it send an trig every time the portion of view is refreshed.
- Tronic
- Posts: 539
- Joined: Wed Dec 21, 2011 12:59 pm
Re: is there a way to get a trigger that confirms...
Tronic - you just saved my project, thanks.
PHI - I mean something like this (schematic).
Basically, the scenario is like this. Some amount of data is calculated in the background, and a dynamic sized image (a sort of color map) is created from that calculated data. Now - using stock prims to save custom bmp like that is tricky. First - data must be calculated, second - (invisible to user but still present) image must be created from these data, and after all portions of that image are present on the invisible display - bitmap can be saved. But without trigger that confirms, that the image was refreshed - how the saving trigger can know, when to take a snapshot? One way to workaround this - is to use trigger collector from data nodes, and delay after that - in the hope, that all operations will be done before it fires.
The triggers (set in simple order) to area redraw and then to saving the bitmap - seem to not wait until redraw is complete, so it's good that ruby can tell on "v" node, that the image is created. Hopefully this will work fine, but I will check it tomorrow.
PHI - I mean something like this (schematic).
Basically, the scenario is like this. Some amount of data is calculated in the background, and a dynamic sized image (a sort of color map) is created from that calculated data. Now - using stock prims to save custom bmp like that is tricky. First - data must be calculated, second - (invisible to user but still present) image must be created from these data, and after all portions of that image are present on the invisible display - bitmap can be saved. But without trigger that confirms, that the image was refreshed - how the saving trigger can know, when to take a snapshot? One way to workaround this - is to use trigger collector from data nodes, and delay after that - in the hope, that all operations will be done before it fires.
The triggers (set in simple order) to area redraw and then to saving the bitmap - seem to not wait until redraw is complete, so it's good that ruby can tell on "v" node, that the image is created. Hopefully this will work fine, but I will check it tomorrow.
- Attachments
-
- refrr.fsm
- (1.04 KiB) Downloaded 743 times
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
Feel free to donate. Thank you for your contribution.
- tester
- Posts: 1786
- Joined: Wed Jan 18, 2012 10:52 pm
- Location: Poland, internet
Re: is there a way to get a trigger that confirms...
when I can is always a pleasure to help
- Tronic
- Posts: 539
- Joined: Wed Dec 21, 2011 12:59 pm
Re: is there a way to get a trigger that confirms...
It appears, that although solution is interesting and theoretically proper - it seems to not work in real life circumstances (while area is refreshed - otherwise it would not produce a picture - mgui isn't triggering; but the problem may be more complex - including ruby itself and it's excessive processing stuff). Getting back to work around. Longer delay should do, I guess...
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
Feel free to donate. Thank you for your contribution.
- tester
- Posts: 1786
- Joined: Wed Jan 18, 2012 10:52 pm
- Location: Poland, internet
6 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 68 guests