|
|
|
02-11-2020, 02:44 PM
|
#41
|
Human being with feelings
Join Date: Jun 2018
Posts: 375
|
60 Hz would be very nice indeed.
Something I've noticed in the latest pre-releases (can't speak for the stable versions) is that the play cursor in the Arranger view moves much smoother than the cursor in the MIDI Editor. It's pretty clear if you zoom in a bit and let it play.
__________________
☐ Area Selection
|
|
|
02-15-2020, 03:28 PM
|
#42
|
Human being with feelings
Join Date: May 2017
Location: Leipzig
Posts: 6,630
|
Quote:
Originally Posted by puddi
60 Hz would be very nice indeed.
Something I've noticed in the latest pre-releases (can't speak for the stable versions) is that the play cursor in the Arranger view moves much smoother than the cursor in the MIDI Editor. It's pretty clear if you zoom in a bit and let it play.
|
Yeah, they have overhauled a lot in Reaper's UI-behavior on pre-6-versions of Reaper, with the smoother updating of the playcursor being one of them, if I remember correctly.
|
|
|
09-05-2020, 07:44 PM
|
#43
|
Human being with feelings
Join Date: May 2017
Location: Leipzig
Posts: 6,630
|
Bumparoooyoohoo
|
|
|
10-07-2020, 11:24 AM
|
#44
|
Human being with feelings
Join Date: May 2017
Location: Leipzig
Posts: 6,630
|
Ok, after some tests by CFillion and me in this thread:
https://forum.cockos.com/showthread.php?t=216679
it seems like my suggestion would not necessarily help boosting scripts.
Currently Reaper seems to update states(like GetPlayPosition) of its functions 30 times per second, which means, before a next GUI-update/all-defer-scripts-run-cycle.
My idea would work only, if it would be updated before every script/defer-cycle is run, to benefit from being scheduled more often within such a GUI-update/all-defer-scripts-run-cycle but I'm not sure, if this would eat up too many ressources.
Looks like 60 fps refresh-rate would need a bigger overhaul on the devs-side, so I wouldn't expect that from coming any time soon...
(not mentioning the gui-redraw itself, which I don't know much about)
|
|
|
10-07-2020, 01:53 PM
|
#45
|
Human being with feelings
Join Date: Jan 2014
Location: Ontario, Canada
Posts: 1,619
|
Even without comprehensive support from state APIs, there's value from a GUI responsiveness perspective. But, yeah, full benefit would come from broader internal support.
|
|
|
10-07-2020, 02:47 PM
|
#46
|
Human being with feelings
Join Date: May 2017
Location: Leipzig
Posts: 6,630
|
Gui-refresh itself seems to be tied to the same mechanism. It seems like the current refresh-timer is a core thing in Reaper, so changing it could lead to all things falling apart, at least gui and extension related.
If the devs manage to tackle this one without breaking anything, they'll grow even further to godlike-status.
|
|
|
12-31-2020, 11:27 PM
|
#47
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
+1
|
|
|
09-13-2021, 02:54 PM
|
#48
|
Human being with feelings
Join Date: Dec 2015
Posts: 172
|
+1
|
|
|
03-27-2022, 10:10 AM
|
#49
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,336
|
Still not possible to change refresh rate?
|
|
|
03-27-2022, 01:11 PM
|
#50
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
Only JSFX can.
Justin, I think, said they might do it sometime so hopes is up, this would be FANTASTIC
|
|
|
03-27-2022, 01:31 PM
|
#51
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,336
|
Quote:
Originally Posted by daniellumertz
Only JSFX can.
Justin, I think, said they might do it sometime so hopes is up, this would be FANTASTIC
|
So sad... Actually I'd like to be able to decrease refresh rate.
|
|
|
03-28-2022, 05:49 AM
|
#52
|
Human being with feelings
Join Date: Apr 2013
Location: France
Posts: 9,902
|
decrease is possible in gfx, you just need to call gx.update only if necessary, or you can call only after a certain time interval by registering ime in each defer loop
|
|
|
03-28-2022, 06:23 AM
|
#53
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,336
|
Quote:
Originally Posted by X-Raym
decrease is possible in gfx, you just need to call gx.update only if necessary, or you can call only after a certain time interval by registering ime in each defer loop
|
The problem is I've removed gfx.update and it is updated using other functions like gfx.rect, gfx.set, gfx.setfont, gfx.drawstr. I've tried reducing a number of calls by
PHP Code:
if math.ceil(reaper.time_precise()*10)/10 % 0.5 == 0 then
, but in this case buttons (the GUI has buttons) aren't highlighted neither they don't react to mouse clicks. Maybe I'll try again updating GUI only when the mouse is moved, but previously some things didn't work, so I need more conditions.
Hm, so you are suggesting use for example reaper.time_precise(), write its value to a new variable and when the difference between reaper.time_precise() and this new variable is bigger than X, update the GUI? Pretty nice idea, thanks! I already use something like this for showing tooltips.
|
|
|
03-28-2022, 12:25 PM
|
#54
|
Human being with feelings
Join Date: Apr 2013
Location: France
Posts: 9,902
|
@vitalker
indeed to take care of hover for button can require some adjustement about what to put in the functions called at slower speed.
Most if my script doesnt have this 'slow' mode, as reper is efficient enough to redraw GUI at normal speed even with complex functions in most cases
But are you sure ReaImgui wouldnt be better in your case ?
|
|
|
03-28-2022, 12:34 PM
|
#55
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,336
|
Quote:
Originally Posted by X-Raym
@vitalker
indeed to take care of hover for button can require some adjustement about what to put in the functions called at slower speed.
Most if my script doesnt have this 'slow' mode, as reper is efficient enough to redraw GUI at normal speed even with complex functions in most cases
But are you sure ReaImgui wouldnt be better in your case ?
|
The issue here is the GUI costs me almost 14% of CPU, that's why I want to improve it. Reaper is redrawing everything very fast, that's the problem.
It would be too much of unwanted learning and a new dependency, which I want to avoid. Currently I am using heavy-modified GUI from daniellumertz, which is a fork of eugen2777's (R.I.P.) GUI.
https://forum.cockos.com/showpost.ph...&postcount=101
|
|
|
03-28-2022, 04:13 PM
|
#56
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
Quote:
Originally Posted by vitalker
The issue here is the GUI costs me almost 14% of CPU, that's why I want to improve it. Reaper is redrawing everything very fast, that's the problem.
It would be too much of unwanted learning and a new dependency, which I want to avoid. Currently I am using heavy-modified GUI from daniellumertz, which is a fork of eugen2777's (R.I.P.) GUI.
https://forum.cockos.com/showpost.ph...&postcount=101
|
GFX GUI are much slower than IMGUI, if your concern is resource you should change to imgui. My demo script with just some sliders buttons and layers increase CPU usage in like 2% here. The ImGUI demo with all tabs open here dont take 1%, I dont know if they actually use GPU.
That being said. I wonder what are you doing to make a GUI that consumes 14%. How much CPU increase you notice in my demo? Aren't you calling some demanding function ? I find very hard that that is the GUI increasing that much CPU, unless you made a MEGA-ULTRA GUI.
Also if you concern is time learning a framework I think you should go to IMGUI seriously you can learn in one day or two the basics things and start using it. Much more easier than that fork.
About the dependency, well, I would say that most people will have it soon. And people that install scripts normally don't mind installing an extension.
That being said I really like the aesthetic of eugen library, so cool ! I would use it sometime just for that looking hahaha.
|
|
|
03-28-2022, 05:02 PM
|
#57
|
Human being with feelings
Join Date: Apr 2013
Location: France
Posts: 9,902
|
@vitalker
Maybe you have a bottleneck somewhere
On my own fork of Eugen script I use in my premium scripts, bottleneck was font resizing. When I figured it out it was about 15 times more quick :P
Anyway here we are definitely starting to do offtopic, cause this is just code optimization, not a missing thing,
Maybe open a thread with your script, let other inspect your code etc
|
|
|
03-29-2022, 12:35 AM
|
#58
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,336
|
Quote:
Originally Posted by daniellumertz
GFX GUI are much slower than IMGUI, if your concern is resource you should change to imgui. My demo script with just some sliders buttons and layers increase CPU usage in like 2% here. The ImGUI demo with all tabs open here dont take 1%, I dont know if they actually use GPU.
That being said. I wonder what are you doing to make a GUI that consumes 14%. How much CPU increase you notice in my demo? Aren't you calling some demanding function ? I find very hard that that is the GUI increasing that much CPU, unless you made a MEGA-ULTRA GUI.
Also if you concern is time learning a framework I think you should go to IMGUI seriously you can learn in one day or two the basics things and start using it. Much more easier than that fork.
About the dependency, well, I would say that most people will have it soon. And people that install scripts normally don't mind installing an extension.
That being said I really like the aesthetic of eugen library, so cool ! I would use it sometime just for that looking hahaha.
|
Interesting, didn't know. Well maybe it depends on CPU. I don't know dedicated GPU, so that's probably the reason.
I do nothing . It has some buttons and a few droplists, but here is an interesting thing: when I allow it to update only every 0.1 seconds, the usage decreases to 5%.
Okay, thanks. Then I'll try imGUI. I hope I'll remake it really fast, because the script took so much time.
Maybe you're right about installing the extension.
Yeah, it looks pretty good, but I don't use a lot of different elements, so imGUI should cover all my needs. Thanks again!
|
|
|
03-29-2022, 12:46 AM
|
#59
|
Human being with feelings
Join Date: Dec 2012
Posts: 13,336
|
Quote:
Originally Posted by X-Raym
@vitalker
Maybe you have a bottleneck somewhere
On my own fork of Eugen script I use in my premium scripts, bottleneck was font resizing. When I figured it out it was about 15 times more quick :P
Anyway here we are definitely starting to do offtopic, cause this is just code optimization, not a missing thing,
Maybe open a thread with your script, let other inspect your code etc
|
Could be fonts, yeah. I don't know how to disable it, so maybe imGUI would be a better solution anyway.
Offtopic, but setting refresh rate would be still very cool.
|
|
|
03-29-2022, 05:12 AM
|
#60
|
Human being with feelings
Join Date: Jan 2014
Location: Ontario, Canada
Posts: 1,619
|
I'm interested in this for REAPER Toolkit (another GUI for Lua) as it supports animations, the most utilitarian of which is smooth scroll, and that would definitely benefit from a faster refresh. I'd just dial back the GUI update rate when not animating to conserve CPU.
|
|
|
04-10-2022, 04:19 PM
|
#61
|
Human being with feelings
Join Date: May 2015
Location: Québec, Canada
Posts: 4,970
|
Made a quick proof of concept:
https://gist.github.com/cfillion/d4d...9a97edadf4bff9
some binaries at https://cfillion.ca/files/reaper/60fps/
This changes the rate of REAPER's "misc" timer to 60 Hz. That timer is responsible for many many internal things, running deferred scripts and extension timer callbacks being only two of them. Some things may break as a side effect, so no guarantees! Also it's still a low-priority Win32 timer so the firing rate remains approximate.
EDIT: Added a high-resolution mode that replaces the Win32 timer with a multimedia timer (reaper_60fps_hires.dll). (This is way overkill, but it'll reach that 60FPS no matter what!)
Last edited by cfillion; 04-11-2022 at 10:11 AM.
|
|
|
04-10-2022, 05:02 PM
|
#62
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
hey cf thanks for making this extension test drive!
I notice (looking in imgui FPS) with your dll and the fps caps at 40FPS.
And with 1000/120 in the .cpp it caps at 60
Also notice something strange concerning monitors and FPS looking via IMGUI. When maind Dear Imgui Demo is in the same window than the Metric/Debugger the FPS decreases
(not bug reports just want to leave observation for further investigation)
EDIT:
More investigation
A fps counter script
Code:
function print(...)
local t = {}
for i, v in ipairs( { ... } ) do
t[i] = tostring( v )
end
reaper.ShowConsoleMsg( table.concat( t, "\n" ) .. "\n" )
end
start = reaper.time_precise()
fps = 1
function loop()
local now = reaper.time_precise()
if now - start >= 1 then
print('FPS IS '..fps)
fps = 1
start = reaper.time_precise()
end
fps = fps + 1
reaper.defer(loop)
end
loop()
it seems it is the Metric window that makes the fps go lower, so test is better done with separate scripts (?)
Last edited by daniellumertz; 04-10-2022 at 05:14 PM.
|
|
|
04-11-2022, 01:14 PM
|
#63
|
Human being with feelings
Join Date: Apr 2013
Location: France
Posts: 9,902
|
@cfillion
The hi rez just freeze reaper somehow for me (make it extra extra slow) the other version I didn't noticed diff on my reateab hero script :S
Thanks for experimenting
|
|
|
04-11-2022, 01:28 PM
|
#64
|
Human being with feelings
Join Date: Jan 2014
Location: Ontario, Canada
Posts: 1,619
|
Cool PoC, Christian. Scrolling viewports in rtk is appreciably smoother. The smoother refresh rate exacerbates the GUI refresh slowness when the MIDI editor is open -- this is a long standing REAPERism, but it's much more noticeable when normal operation happens at 60fps
|
|
|
07-02-2022, 08:49 PM
|
#65
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
sad bumping =)
|
|
|
02-18-2023, 04:51 AM
|
#66
|
Human being with feelings
Join Date: Jul 2010
Location: Slovakia
Posts: 2,588
|
Bump.
|
|
|
03-06-2023, 04:03 PM
|
#67
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
more options of defer would be really great for script running live ! (some would really appreciate more than 60fps if feasible )
|
|
|
11-19-2023, 12:25 AM
|
#68
|
Human being with feelings
Join Date: Dec 2015
Posts: 172
|
+1 for 60fps option.
|
|
|
02-08-2024, 08:10 PM
|
#69
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 2,011
|
umpalumpa bumpalumpa
|
|
|
04-09-2024, 11:07 PM
|
#70
|
Human being with feelings
Join Date: Apr 2022
Posts: 204
|
+1 60 or more fps, please
|
|
|
Thread Tools |
|
Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -7. The time now is 05:17 PM.
|