Post Reply 
 
Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Possible Frameskip range 0.1-0.9?
07-24-2013, 03:02 AM
Post: #1
Possible Frameskip range 0.1-0.9?
Current frameskip causing the screen flickering while in game. It did improve speed on android generally.

I tried edit the ppsspp.ini changing from 1 to 0.1, but when run ppsspp, the frameskip value is 0. I would like to experiment, what would frameskip 0.1-0.9 effect could be? Any thought?
Find all posts by this user
Quote this message in a reply
07-24-2013, 04:47 AM (This post was last modified: 07-24-2013 04:50 AM by Rhymes.)
Post: #2
RE: Possible Frameskip range 0.1-0.9?
I don't think it will solve screen flickering completely.
I had been playing a bit with frameskip algorithm in the source code level before. More speed I got, more flickering I received.
I tried to find a way to reuse a frame twice to eliminate flickering. This may help or not, but I didn't have much time, and it is much more complex than I thought.

From what I thought, 0.1-0.9 just produced less screen flickering and less speed improve.
Other than that, developers declared frameskip variable as an int. So, if you change frameskip in ppsspp.ini to 0.1, you will get 0.
Find all posts by this user
Quote this message in a reply
07-24-2013, 05:05 AM
Post: #3
RE: Possible Frameskip range 0.1-0.9?
Less screen flickering and less speed improve is acceptable with me.
Can you point me which code is controlling the frameskip algorithm? Thank you.
Find all posts by this user
Quote this message in a reply
07-24-2013, 05:34 AM
Post: #4
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 05:05 AM)cyclonmaster Wrote:  Less screen flickering and less speed improve is acceptable with me.
Can you point me which code is controlling the frameskip algorithm? Thank you.
I was wondering about that as well. Changing int of frameskipping to float may help.
Find all posts by this user
Quote this message in a reply
07-24-2013, 05:44 AM (This post was last modified: 07-24-2013 05:47 AM by Rhymes.)
Post: #5
RE: Possible Frameskip range 0.1-0.9?
It is in scdDisplay.cpp

But there are more than that to be changed, ex. framskip variable was not declared there. I suggest using IDE and tools to find it quickly.
I just modified, tested it a bit, so I can't help you much. You better ask developers. My skill is lag behind Henrik at least 10 years. Rolleyes
Find all posts by this user
Quote this message in a reply
07-24-2013, 09:51 AM
Post: #6
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 05:44 AM)Rhymes Wrote:  It is in scdDisplay.cpp

But there are more than that to be changed, ex. framskip variable was not declared there. I suggest using IDE and tools to find it quickly.
I just modified, tested it a bit, so I can't help you much. You better ask developers. My skill is lag behind Henrik at least 10 years. Rolleyes
I think variable is declared in scdDisplay.h if I'm not wrong. What have you tested so far?
Find all posts by this user
Quote this message in a reply
07-24-2013, 10:25 AM
Post: #7
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 09:51 AM)Danyal Zia Wrote:  
(07-24-2013 05:44 AM)Rhymes Wrote:  It is in scdDisplay.cpp

But there are more than that to be changed, ex. framskip variable was not declared there. I suggest using IDE and tools to find it quickly.
I just modified, tested it a bit, so I can't help you much. You better ask developers. My skill is lag behind Henrik at least 10 years. Rolleyes
I think variable is declared in scdDisplay.h if I'm not wrong. What have you tested so far?

I judged from the name. It is the global variable named g_Config.iFrameSkip that is in another file.
It is took from config you set in emulator.

I did not mess up this variable. My main goal was render twice per frame. hleEnterVblank is the main function I tested.
Find all posts by this user
Quote this message in a reply
07-24-2013, 11:16 AM
Post: #8
RE: Possible Frameskip range 0.1-0.9?
My question is,what 0.1 mean
1 is one frame(you could call it one image),so what 0.1 will mean...how will you skip less than one frame\image

Wouldn't be better(if possible)the frame skipping to work like this:
Skipping is set to 1 for example and and ppsspp display the frames like this...display a frame and stay on that frame until the next frame is ready to be displayed(I think that's how pcsx2 frame skipping feature worked way back and it was much more usable than now).

I think buffered rendering helps avoiding flickering but on some games it have another negative effect while frame skipping is enabled.

The way I understand it(I could be wrong),on some game ppsspp displays a black screen instead of the skipped frames...so don't change the displayed frame until the next is ready to be displayed(this may cause stuttering but I'm not sure...just suggesting)

Using PPSSPP on Windows 7 x64 SP1
i7 4771 3.5Ghz,GTX750TI,16GB RAM

Batch iso <=> cso converter
http://forums.ppsspp.org/showthread.php?tid=5384
Save Game\States Manager
http://forums.ppsspp.org/showthread.php?tid=5516
Find all posts by this user
Quote this message in a reply
07-24-2013, 11:38 AM (This post was last modified: 07-24-2013 11:43 AM by Rhymes.)
Post: #9
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 11:16 AM)vsub_ Wrote:  My question is,what 0.1 mean
1 is one frame(you could call it one image),so what 0.1 will mean...how will you skip less than one frame\image

Wouldn't be better(if possible)the frame skipping to work like this:
Skipping is set to 1 for example and and ppsspp display the frames like this...display a frame and stay on that frame until the next frame is ready to be displayed(I think that's how pcsx2 frame skipping feature worked way back and it was much more usable than now).

I think buffered rendering helps avoiding flickering but on some games it have another negative effect while frame skipping is enabled.

The way I understand it(I could be wrong),on some game ppsspp displays a black screen instead of the skipped frames...so don't change the displayed frame until the next is ready to be displayed(this may cause stuttering but I'm not sure...just suggesting)

From what I understanding (only apply to ppsspp). 0.1 mean every 10 frames skip 1. At 1 frameskip you will get double VPS if not limited by GPU/CPU.
This only happen when VPS lower than 60. If you have 60 VPS already, frameskip has no effect.

Your thought is what I mean.
Render twice per frame maybe confuse all of you. I used wrong words. I mean do not update next frame. keep old frame, then render third, skip forth, and so on. In the other words, Replace black buffer with old frame.

This will make game look better than get black buffer frame and increase VPS.
I think developer already implemented this. But only frameskip function is not enough. It link to display to screen function/fbo too, maybe much more. That why some games work and others don't. Much harder than theory.
Find all posts by this user
Quote this message in a reply
07-24-2013, 11:49 AM
Post: #10
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 11:38 AM)Rhymes Wrote:  Your thought is what I mean.
Render twice per frame maybe confuse all of you. I used wrong words. I mean do not update next frame. keep old frame, then render third, skip forth, and so on. In the other words, Replace black buffer with old frame.

Hmm,I guess I didn't understand you but it looks like we are talking about the same thing.

Using PPSSPP on Windows 7 x64 SP1
i7 4771 3.5Ghz,GTX750TI,16GB RAM

Batch iso <=> cso converter
http://forums.ppsspp.org/showthread.php?tid=5384
Save Game\States Manager
http://forums.ppsspp.org/showthread.php?tid=5516
Find all posts by this user
Quote this message in a reply
07-24-2013, 05:45 PM (This post was last modified: 07-24-2013 06:59 PM by Danyal Zia.)
Post: #11
RE: Possible Frameskip range 0.1-0.9?
Just done changing "int iFrameSkip" to "float iFrameSkip" in config.h and now ppsspp.ini is showing float values in Frameskip. Though, I have doubt about it's functionality, since it's behavior is declared in sceDisplay.cpp which needs tweaking to work with float values, I guess. Also, it breaks the UI of frameskipping badly which needs tweaking in MenuScreens.cpp but that's not mandatory for now though.

It's working flawlessly! I've tested WWE Smackdown vs Raw 2011 and GTA VCS which shows black screen flickering in non-buffered rendering mode with frameskipping (both even and odd), But now it seems to working perfectly in FrameSkip = 4.500000, You rock cyclonmaster for giving a good idea! All I have to do now is to tweak MenuScreens.cpp for UI of frameskipping. Should add "-0.5" and "+0.5" now.
Find all posts by this user
Quote this message in a reply
07-24-2013, 07:17 PM
Post: #12
RE: Possible Frameskip range 0.1-0.9?
Please do a git pull request when you get this working,can't wait to use frameskipping efficiently Smile
Find all posts by this user
Quote this message in a reply
07-24-2013, 10:29 PM (This post was last modified: 07-24-2013 10:58 PM by cyclonmaster.)
Post: #13
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 05:45 PM)Danyal Zia Wrote:  Just done changing "int iFrameSkip" to "float iFrameSkip" in config.h and now ppsspp.ini is showing float values in Frameskip. Though, I have doubt about it's functionality, since it's behavior is declared in sceDisplay.cpp which needs tweaking to work with float values, I guess. Also, it breaks the UI of frameskipping badly which needs tweaking in MenuScreens.cpp but that's not mandatory for now though.

It's working flawlessly! I've tested WWE Smackdown vs Raw 2011 and GTA VCS which shows black screen flickering in non-buffered rendering mode with frameskipping (both even and odd), But now it seems to working perfectly in FrameSkip = 4.500000, You rock cyclonmaster for giving a good idea! All I have to do now is to tweak MenuScreens.cpp for UI of frameskipping. Should add "-0.5" and "+0.5" now.

Wah! so fast. I'm still looking at the code. Big Grin
btw, instead of "-0.5" and "+0.5", would it be better to use "-0.1" and "+0.1" ?
Find all posts by this user
Quote this message in a reply
07-25-2013, 03:53 AM (This post was last modified: 07-25-2013 03:54 AM by Danyal Zia.)
Post: #14
RE: Possible Frameskip range 0.1-0.9?
(07-24-2013 10:29 PM)cyclonmaster Wrote:  Wah! so fast. I'm still looking at the code. Big Grin
btw, instead of "-0.5" and "+0.5", would it be better to use "-0.1" and "+0.1" ?

Well... the problem is that the code really doesn't make sense that's why it won't merge with master even if it's working. It was just an experiment. But, if you want to try it just change "int iFrameSkip" to "float iFrameSkip" in config.h and build the solution. You'll have to change frameskip manually in ppsspp.ini though.
Find all posts by this user
Quote this message in a reply
08-01-2013, 12:02 AM
Post: #15
RE: Possible Frameskip range 0.1-0.9?
(07-25-2013 03:53 AM)Danyal Zia Wrote:  
(07-24-2013 10:29 PM)cyclonmaster Wrote:  Wah! so fast. I'm still looking at the code. Big Grin
btw, instead of "-0.5" and "+0.5", would it be better to use "-0.1" and "+0.1" ?

Well... the problem is that the code really doesn't make sense that's why it won't merge with master even if it's working. It was just an experiment. But, if you want to try it just change "int iFrameSkip" to "float iFrameSkip" in config.h and build the solution. You'll have to change frameskip manually in ppsspp.ini though.

hey, sounds good the idea of ​​this
https://github.com/hrydgard/ppsspp/issues/3025

you can put your version of that work here plsssss

or can not?
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump: