User Tag List

Results 1 to 5 of 5

Thread: Force the screen to update?

  1. #1
    Clicker Fusion 2.5

    Join Date
    Feb 2014
    Location
    Sweden
    Posts
    61
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question Force the screen to update?

    From what I understand, the screen is redrawn at the end of the event list. But is there a way to force the screen to update from an event? The reason I'm asking is because I want to use a fastloop and the Screen Capture object to capture an area with some Actives, re-position the Actives and repeat, so that I will get, say, five different pictures with the Actives in different positions. However, since I don't know of a way to force the screen to update, I end up with five duplicates of the same picture, with all the Actives in their original position. Does anyone have a solution for this, or do I have to find a way to split up the screen capture process over several frames? My project uses Direct3D 9, if that makes any difference.

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,336
    Mentioned
    9 Post(s)
    Tagged
    0 Thread(s)
    I think you're out of luck here using fastloops. The Screen Capture object only captures what's actually drawn to the screen, so you can't really use it in fastloops, as fastloops runs between screen updates. The framerate controls how often the screen is drawn, and you can't force the screen to update faster than the framerate. What you can do however is to make the framerate very high, say 500 frames a second, or as fast as the computer manages. That would give you 500 opportunities to capture the screen each second. If you capture the first 5 screen updates, all would be displayed on screen, but since the human eye can only register 60 frames per second, no one would be able to see more than one. I have tested it and it do work!

  3. #3
    Clicker Fusion 2.5

    Join Date
    Feb 2014
    Location
    Sweden
    Posts
    61
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Popcorn View Post
    I think you're out of luck here using fastloops. The Screen Capture object only captures what's actually drawn to the screen, so you can't really use it in fastloops, as fastloops runs between screen updates. The framerate controls how often the screen is drawn, and you can't force the screen to update faster than the framerate. What you can do however is to make the framerate very high, say 500 frames a second, or as fast as the computer manages. That would give you 500 opportunities to capture the screen each second. If you capture the first 5 screen updates, all would be displayed on screen, but since the human eye can only register 60 frames per second, no one would be able to see more than one. I have tested it and it do work!
    Thanks, yeah it's not a perfect solution but a good workaround. I've finally managed to almost get it right - I had a lot of problems with the screen capture lagging behind one frame since the Capture Frame caused a singificant framerate drop. For some reason this only happens you choose Capture Frame. Using Capture Screen is somewhat faster and Capture Active Window is super fast in comparison, but then the Area coordinates get completely messed up. Do you have any idea why this is, and if there's any workaround?

  4. #4
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,336
    Mentioned
    9 Post(s)
    Tagged
    0 Thread(s)
    No sorry, I haven't used the screen capture object that much. Perhaps it's something for the Bug tracker, once it is back up..

  5. #5
    Clicker Fusion 2.5

    Join Date
    Feb 2014
    Location
    Sweden
    Posts
    61
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I figured out a workaround:
    I used the method described in this thread https://community.clickteam.com/threads/55349-Top-Left-corner-of-client-area-relative-to-screento get the top-left coordinates of the client area, and subtracted the coordinates of the application window, which I got from the window control object. I then added these values (the difference between the client area and the application window top X/Y) to the Area Origin, and set the Screen Capture object to Capture Active Window. Works perfectly.

Similar Threads

  1. After Level Score Update Screen
    By DokieMaster in forum Fusion 2.5
    Replies: 1
    Last Post: 9th February 2017, 02:06 PM
  2. Windows 10 Update prevents full screen
    By DaveC in forum Fusion 2.5
    Replies: 1
    Last Post: 1st October 2016, 09:12 AM
  3. Replies: 3
    Last Post: 16th August 2016, 03:46 PM
  4. Replies: 8
    Last Post: 25th March 2015, 08:47 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •