Correction for my message:

>> Doesn't the scheduler distribute CPU time between all applications
>> anyway?
>> I don't think we can force it to give us all the CPU.

The Performance hit on this way is absolute minimal/unoticeable.

> ...If there are new rendered frames in the GPU and if the Monitor
> still draws a old one, the new framed will be droped. ...

I wanted to write, that the GPU only sends the new 'frame' if it is
rendered. Otherwise the old one is rendered again. The frame will be
updated at the time when the monitor has done the drawing.

I hope this is more understandable :)

Kamaze schrieb:
> Preamble: I'm absolute tired, so please be torantly to some writing
> mistakes and maybe unstructured parts. *g* :)
> 
> Well, if WZ runs in Fullscreen mode it doesn't really interest if it
> reserves all CPU time. (AFAIK!) But for laptopusers this is bad, because
> (at least on windows) if the CPU has too much to do (means, most cpu
> time isn't reserved for the idle process) the fan begins to run etc...
> 
> But if the game runs in windowed mode, it is nicer if the game 'shares'
> his reserved CPU time. (Sleep(0) / Sleep(1) - I know that Sleep has most
> a resolution about ~10ms but that makes the Taskmanager happy)
> 
>> Doesn't the scheduler distribute CPU time between all applications anyway?
>> I don't think we can force it to give us all the CPU.
> 
> Sure it does, but it does it more friendlier if the sheduler has CPU
> time in the idleprocess.
> 
>> Currently we only request as much as to keep a certain framerate. Which hits 
>> the limits on slow PCs, what I don't think is bad (since why would we like 
>> to 
>> drop the fps even more).
> 
> This is nonesense for me.
> Warzone has (afaik) a framerate independent game logic.
> So it isn't necesarry to limit or try to reach a certain FPS.
> 
> And the SDL-Framerate(...) is failed by design for me. Its absolute none
> sense too. If i would make a app which logics/animation depends on the
> FPS,... i did something wrong.
> 
> And it isn't for vsync. Vsync means to sync the GPU output with the HZ
> from the monitor. Means: The GFX-Cards pushes the frame to draw only to
> the monitor, if it start to draw a new 'frame'. If there are new
> rendered frames in the GPU and if the Monitor still draws a old one, the
> new framed will be droped. Thats the reason why with vsync on the fps
> most slightly decreases. (Imagine, the GPU just dropped a fresh rendered
> frame and a few MS later the monitor has finished to draw the frame, so
> the next frame will be send if it is done)
> 
> If i want to emulate a vsync via Sleep()... the FPS must only drop to
> something < Monitor-HZ. (59 FPS instead of 60) and *all* following
> images will overwrite the ongoing drawing. (This 'cut' effect on movements)
> 
> Vsync has to be done by the driver, in SDL with:
> SDL_GL_SetAttribute(SDL_GL_SWAP_CONTROL, TRUE);
> 
> So, i'm for kicking out this SDL_Framerate() thing (reason above) and
> for sharing CPU time even in fullscreen mode. Sharing the CPU time
> mostly means warzone just use what it needs for a certain calculation.
> And my maybe running BitTorrent programm etc... can run smoothly in the
> background without 'fighting' for CPU-Time.
> 
> I would like to go more in detail with this but i'm absolute tired, so
> please be torantly to some writing mistakes *g* :)
> 
> - Regards, Kamaze
> 
>> The only reason we inserted the delay originaly, was because eg. laptop 
>> users 
>> don't need 100fps, but would like to keep their CPU idle instead. They can 
>> lower the framerate down to 1fps if they want, and that will be exactly what 
>> they get. No more, maybe less.
>> So currently the real only issue is that there is no delay in the mainmenu.
>>
>> Wouldn't it be enough to estimate the time the buffer will bear up and 
>> wakeup 
>> just before it is empty?
>> But you are right, I probably have to think about how to do this best for a 
>> while...
> 

_______________________________________________
Warzone-dev mailing list
Warzone-dev@gna.org
https://mail.gna.org/listinfo/warzone-dev

Reply via email to