Logo by Madman - Contribute your own Logo!

END OF AN ERA, FRACTALFORUMS.COM IS CONTINUED ON FRACTALFORUMS.ORG

it was a great time but no longer maintainable by c.Kleinhuis contact him for any data retrieval,
thanks and see you perhaps in 10 years again

this forum will stay online for reference
News: Visit us on facebook
 
*
Welcome, Guest. Please login or register. October 27, 2020, 06:58:01 AM


Login with username, password and session length


The All New FractalForums is now in Public Beta Testing! Visit FractalForums.org and check it out!


Pages: [1]   Go Down
  Print  
Share this topic on DiggShare this topic on FacebookShare this topic on GoogleShare this topic on RedditShare this topic on StumbleUponShare this topic on Twitter
Author Topic: Rendertime - High Performance  (Read 1076 times)
0 Members and 1 Guest are viewing this topic.
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« on: September 15, 2014, 02:42:52 PM »

while working with synthclipse i become more and more interested in the actual rendertime, for making simple performance comparison of tiny optimizations, what about an implementation of a super high performance timer to calculate the rendertime? i am unsure which would suite best for java but i believe there is some kind of high precision timer available in java

because i have a rather fast gpu, it says all the time it takes 0.016 seconds to calculate but i do not really believe what i see wink perhaps it can be even extended to some upper/lower bounds for the render time, and average and most recent wink  angel
Logged

---

divide and conquer - iterate and rule - chaos is No random!
_revers_
Conqueror
*******
Posts: 138



« Reply #1 on: September 15, 2014, 10:57:14 PM »

Actually I'm already using high performance timer (with nano precision) under the hood. Java has build-in support for such timers since 5-th version.

I was assuming that displaying time with ms precision would be sufficient for everyone, but since I'm already using high precision timer, adding configuration option for more digits shoudn't take me much time. I will add this feature in the next release.

Also FPS counter/frame timer already uses an avarage of frame times over some period of time (not every tick is displayed to not overkill the GUI).
Logged
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« Reply #2 on: September 17, 2014, 03:45:56 PM »

what me concerns is that it does not really differ it does not really goes below "0.015s" for example, compare a complex scene to a single color return value they go up if the scene is too complex but it seems to not go below a certain limit but a single color output should render much faster than "0.01s"!!

so it might not be reasonable to display more decimals, but there might be a slight error in the way it is calculated, count time before call to "render" and after "render" there might be some delays counted in that variable better check how it is actually retrieved  alien
« Last Edit: September 17, 2014, 03:47:53 PM by cKleinhuis » Logged

---

divide and conquer - iterate and rule - chaos is No random!
_revers_
Conqueror
*******
Posts: 138



« Reply #3 on: September 18, 2014, 04:43:51 PM »

The time doesn't drop below ~0.015s since it is frame time on CPU side, not GPU frame time. On CPU side there are more things done than just issueing OpenGL draw calls, like event handling, Eclipse GUI handling, sharing time between other threads (Eclipse consists of about 10-20 threads). Moreover GPU part of rendering runs asynchronously in OpenGL, so there is additional GPU-CPU synchronization cost.

There is a way to messure exact time on the GPU by using GL_ARB_timer_query extension. Maybe I will use it in some future version but rather not yet in Synthclipse 0.9.7.
Logged
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« Reply #4 on: September 18, 2014, 05:17:29 PM »

i suspected that it is hard to get the exact rendertime, but since what a shader developer is interested in: does the tiny itsy bitsy changes of code have impact on the performance and how much. in fact i am quite unsure about the actual rendering costs of various shaders, some take reaaally long and bring my card to its limit but some others are extremely gpu friendly, although rendering a hole bunch of stuff, for example the - fractal cartoon - seems to be very efficently implemented perhaps because it doesnt use many branches, so gpu exact rendertime for a fragment shader comes in extreeemly handy!

nevertheless its a versatile and awesome program i am using it nearly every day since i discovered it wink
Logged

---

divide and conquer - iterate and rule - chaos is No random!
_revers_
Conqueror
*******
Posts: 138



« Reply #5 on: September 18, 2014, 05:27:18 PM »

Thanks! smiley So Synthclipse has at least two satisfied users (you and me) wink
Logged
Syntopia
Fractal Molossus
**
Posts: 681



syntopiadk
WWW
« Reply #6 on: September 18, 2014, 09:06:27 PM »

0.016s ~ 60Hz, so this suggest that the frame rate is limited by the screen refresh rate. You probably need to disable VSYNC to measure shader times.
Logged
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« Reply #7 on: September 18, 2014, 09:08:07 PM »

Thanks! smiley So Synthclipse has at least two satisfied users (you and me) wink

lol, out of curiosity have you changed something on the update/recompile method, it seems it takes a little longer to get the new compiled code in the render window, has perhaps something to do with restoring current uniform values
Logged

---

divide and conquer - iterate and rule - chaos is No random!
_revers_
Conqueror
*******
Posts: 138



« Reply #8 on: September 19, 2014, 09:28:27 AM »

To be sure, you unchecked "V-Sync (limited FPS)" (on the Rendering View) when taking frame time measurement? (As suggested by Syntopia)

Well, restoring paramters might be it. Do you have same feeling when "Remember parameters between builds" is unchecked in the Uniform Controls View?
Please also check if selected Buffer size "Same as Viewport" (in the Rendering View) makes difference. It should be a little faster than rendering with custom buffer size, but I don't know if it is really that much.

Have you tested this on Fragx/Stoy shaders or on JSX scritps? JSX scripts are loaded slower since they always destroy and create a new OpenGL context. In the other hand Fragx/Stoy shaders are using always one context.
« Last Edit: September 19, 2014, 09:33:14 AM by _revers_ » Logged
_revers_
Conqueror
*******
Posts: 138



« Reply #9 on: September 19, 2014, 07:38:07 PM »

I've got less capable video card and frame time when rendering simple 2D effect definetely drops below 0.015s, so you probably forgot to turn off the v-sync.



Logged
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« Reply #10 on: September 19, 2014, 08:05:20 PM »

hmm, ok, it seems to be fixed with unchecking the vsinc wink alright
Logged

---

divide and conquer - iterate and rule - chaos is No random!
Pages: [1]   Go Down
  Print  
 
Jump to:  


Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM
Page created in 0.191 seconds with 28 queries. (Pretty URLs adds 0.008s, 2q)