• Please make sure you are familiar with the forum rules. You can find them here: https://forums.tripwireinteractive.com/index.php?threads/forum-rules.2334636/

Regarding "One Frame Thread Lag"

I have 2 questions/ concerns:

1) if your game thread is consistently faster than your render thread, won't you be in the same situation with OFTL on as off, with the added downside that you are constantly 1 frame behind?

2) I suppose the client side hit detection uses the game thread to determine the game state. But, with OFTL on, won't that mean that it is more difficult to hit people, since you might be looking at a screen that is no longer current with regards to the game thread.
I seem to notice it is harder for me to hit enemies with OFTL on, which supports this.
 
Upvote 0
1) if your game thread is consistently faster than your render thread, won't you be in the same situation with OFTL on as off, with the added downside that you are constantly 1 frame behind?

Think about that again. Hint: The key is to think with parallelism in mind. ;)

2) I suppose the client side hit detection uses the game thread to determine the game state. But, with OFTL on, won't that mean that it is more difficult to hit people, since you might be looking at a screen that is no longer current with regards to the game thread.
I seem to notice it is harder for me to hit enemies with OFTL on, which supports this.

Refer to my first post on this thread.
 
Upvote 0
Think about that again. Hint: The key is to think with parallelism in mind. ;)

I understand that OFTL gives more pararellellism as the 'frame queue' (which has a max length of, as I understand it, only 1 frame) is being filled. However, once the frame queue is full, you are stalling for the N+2'th frame to finish.

How is this situation better than being stalled for the N+1'th frame with OFTL off (even more, it is worse as you are one frame behind)

Correct me if I'm wrong ofcourse:)

I also note that for myself, I gain little to no fps from OFTL, only some input lag.
 
Upvote 0
Ok, for the sake of argument let's assume that your game thread consistently takes 5ms to run and the render thread takes 10ms to run.

If you run with OFTL off, once the render thread has finished rendering the frame (10ms), it has to wait an additional 5ms for the game thread to finish computing the next frame before it can do any work. Since the render thread is not allowed to lag behind (also read as since the game thread is not allowed to work ahead) there is no queued frame. Hence, the effective time to render a frame from the render thread's perspective becomes 15ms.

On the other hand, if you have OFTL enabled, by the time the render thread has finished rendering one frame, it will already have a queued up frame to work on immediately. So the effective render time is now 10ms as opposed to 15ms.

Of course, if the render thread is more than 2 times slower than the game thread, then it will not always have a queued up frame, and as a result OFTL will yield diminishing returns.
 
Upvote 0
If you run with OFTL off, once the render thread has finished rendering the frame (10ms), it has to wait an additional 5ms for the game thread to finish computing the next frame before it can do any work.

The confusion is still not cleared up. In your original post you said, regarding the OFTL off scenario:

"While the Nth frame is being rendered, the game thread can compute your (N+1)th frame in parallel."

This seems in conflict with the quoted sentence above?
 
Upvote 0
If you run with OFTL off, once the render thread has finished rendering the frame (10ms), it has to wait an additional 5ms for the game thread to finish computing the next frame before it can do any work.

This is for the render thread.

"While the Nth frame is being rendered, the game thread can compute your (N+1)th frame in parallel."

This is for the game thread.

The game thread is not dependent on the render thread, and hence can start computing the next frame before the render thread has finished. But the render thread is dependent on the game thread, and cannot begin a frame before the game thread has finished.

Also, I was being very simplistic in my 5ms, 10ms example. I hope you get the idea. You'll just have to put 2 and 2 together. Unfortunately, this is about as much detail I can go into in the forums.
 
Last edited:
Upvote 0
Sometimes pictures say more than words, so here is my understanding of the scenario where game thread = 5ms and render thread = 10ms.
Beyond the initial throughput increase for the game thread, I see no advantage of OFTL. Where is this interpretation wrong?

Note: I realize this is a simplified scenario, but it gets my point across.
In cases where the render thread is sometimes faster and sometimes slower than the game thread, I can imagine there being more benefit.
 

Attachments

  • OFTL.jpg
    OFTL.jpg
    39.2 KB · Views: 0
Last edited:
Upvote 0
Sometimes pictures say more than words, so here is my understanding of the scenario where game thread = 5ms and render thread = 10ms.
Beyond the initial throughput increase for the game thread, I see no advantage of OFTL. Where is this interpretation wrong?

Note: I realize this is a simplified scenario, but it gets my point across.
In cases where the render thread is sometimes faster and sometimes slower than the game thread, I can imagine there being more benifit.

I think that is fairly accurate, except for the part where you are assuming that the render pipeline flows at an even rate.

Each frame is different, and as such takes more or less time to finish rendering. Having that n+1 th game thread I think makes more of a difference when things slow down and speed back up again.
 
Upvote 0
Interesting topic here, but even with all this explanations made here, I still have the same questions.

Is it better for accuracy and mouse responsivity to play with or without OneFrameThreadLag ?

I think to resume, that's the answer that every player wait for :p

I was blown away by the difference I found with OFTL disabled. Mainly in aiming, cross-hairs moved more smooth and seemed to react more quickly to mouse movement. Before turning it off, I was helpless with moving targets as movement for tracking them was choppy and laggy. I wont play with it turned on ever again.
 
Upvote 0
I was blown away by the difference I found with OFTL disabled. Mainly in aiming, cross-hairs moved more smooth and seemed to react more quickly to mouse movement. Before turning it off, I was helpless with moving targets as movement for tracking them was choppy and laggy. I wont play with it turned on ever again.

I simply cannot play with it enabled. I don't have too high of a framerate, I average between 40-50 and although turning it on makes my fps higher. The sole reason why I want a high fps is for responsiveness.

Since turning it on makes the games mouse input feel extremely delayed, I turn it off. On my laptop I rather play at 30fps with it off, than at 40 fps with it on.

Even if the system in theory should work better, it gives a serious bad case of input lag. That you can even be clearly noticed in the main menu without even being in a game.
 
Last edited:
Upvote 0
I simply cannot play with it enabled. I don't have too high of a framerate, I average between 40-50 and although turning it on makes my fps higher. The sole reason why I want a high fps is for responsiveness.

Since turning it on makes the games mouse input feel extremely delayed, I turn it off. On my laptop I rather play at 30fps with it off, than at 40 fps with it on.

Even if the system in theory should work better, it gives a serious bad case of input lag. That you can even be clearly noticed in the main menu without even being in a game.


Thank for this statement I had exactly the same impression on it but unfortunately I already have drop of performance so I cannot play with that off because its worth... but with 10 players it's definitly better !
 
Upvote 0