Author Topic: Animation flickering with HD cache  (Read 30258 times)

2013-11-15, 04:57:21

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
Hi guys.

I'm very interested in new to me Corona renderer. I'm doing a little clip of future interior with animated things like robots and furniture. Usually we're using V-Ray for our works but for this clip with lots of animation (usually we're have only people and cars moving in exterior scenes or just people in interiors). I found that Corona is great for animation and started to do animation with it.

During the previsualization I found a little strange thing with flickering the secondary GI named "HD cache" (it's not about the noise, but flickering of whole lighting of secondary GI). As you can see in attached file default settings (top video) of Corona flickering is quite pronounced. Of course I'm started to find the problem. And it was the parameter "Refl glossiness threshold". In default settings it has a value of 0.9. With this value it produces a cleaner image in blurry reflections, but in expense of flickering as I found. I don't know if it's right, but in my tests it is. Then I set "Refl glossiness threshold" to value 0.08 and render animation preview with it. As you can see at bottom video the flickering is much less pronounced in movie then with "Refl glossiness threshold" 0.9, but still there.

May be I'm doing something wrong and you know the way to turn this flickering down?

2013-11-15, 12:11:52
Reply #1

Ondra

  • Administrator
  • Active Users
  • *****
  • Posts: 9048
  • Turning coffee to features since 2009
    • View Profile
reflection glossiness threshod disables HD cache for too specular objects. It seems you have probably disabled it for most of the scene in the second case. You can confirm by comparing the HD success rate % in the statistics in VFB between the two renders. The current best solution is to save and reuse the cache (save/load secondary GI option)
Rendering is magic.How to get minidumps for crashed/frozen 3ds Max | Sorry for short replies, brief responses = more time to develop Corona ;)

2013-11-15, 12:25:17
Reply #2

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
The current best solution is to save and reuse the cache (save/load secondary GI option)

Yea. This seem to work with  fly-through animation without moving elements, but with our animation full of moving subjects and turning lights on and off it is unusable as I see. I've tryed to save HD cache for first frame and reuse it in animation but it feels like all the lights bounces has gone for secondary GI.

In attachment you can see frame with saved HD cache (on left) and with computed during render (on right).

2013-11-15, 12:36:45
Reply #3

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
Keymaster probably forgot to mention saving HDcache only works in scenes with static lights and objects.

I would try reverting HDcache settings back to their defaults, and then increasing position sensitivity to 100, and see if that helps.

HDcache at the moment is unfortunately not flickerfree. So either you have to use Path Tracing as secondary GI, which will increase your rendertimes, or try increasing positional sensitivity of HDcache, or just wait until flickrefree cached secondary solution is implemented. It is very high on priority list.

2013-11-15, 12:41:16
Reply #4

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
Thank You for possible solution. I'll try to check it and reply soon.

2013-11-15, 12:56:29
Reply #5

racoonart

  • Active Users
  • **
  • Posts: 1446
    • View Profile
    • racoon-artworks
or just wait until flickrefree cached secondary solution is implemented. It is very high on priority list.

What's the "technical idea" behind the flickerfree hdcache - how is it supposed to be working?
Any sufficiently advanced bug is indistinguishable from a feature.

2013-11-15, 13:18:45
Reply #6

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
I would try reverting HDcache settings back to their defaults, and then increasing position sensitivity to 100, and see if that helps.

Wow! It seems that it works for this scenario. It doubles rendertimes, but 40 sec of 57 sec of render was the preparation of Secondary GI (HD cache ia mean), so I hope with final render it will be almost no cost (if it will not scales with final quality).

Update:
For the final quality (720p) HD cache was computed in 2:30 min. Super. I'll post final quality report a bit later and full clip in gallery as it will be done.
« Last Edit: 2013-11-15, 13:36:36 by fobus »

2013-11-15, 18:34:29
Reply #7

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Hello fobus

compliments , a great test!

2013-11-16, 16:30:50
Reply #8

michaltimko

  • Active Users
  • **
  • Posts: 305
  • Coronaut (c)
    • View Profile
Keymaster probably forgot to mention saving HDcache only works in scenes with static lights and objects.


Worked for my with loading saved GI even in scene with moving light. (sun moving)
Had no any flickering so far.
Coronaut!(c)2011

Supporting Corona in commercial projects since pre-alpha

2013-11-16, 16:48:13
Reply #9

racoonart

  • Active Users
  • **
  • Posts: 1446
    • View Profile
    • racoon-artworks
Worked for my with loading saved GI even in scene with moving light. (sun moving)
Had no any flickering so far.

Yes, it works, but with outdated lighting information in the secondaries. As soon as your light moved, your primary (pt) bounces are still calculating with the secondaries information of where the sun was before. So if you really push the limits (e.g. a full day circle) you will easily see things getting weird.
« Last Edit: 2013-11-16, 16:52:08 by DeadClown »
Any sufficiently advanced bug is indistinguishable from a feature.

2013-11-16, 17:00:52
Reply #10

michaltimko

  • Active Users
  • **
  • Posts: 305
  • Coronaut (c)
    • View Profile
I had movement from midday to evening in two 5second animations. I saved HD cache (computed 8192) without any issue.
I had few issues with reflections on glossy objects, mostly on edges.
Coronaut!(c)2011

Supporting Corona in commercial projects since pre-alpha

2013-11-16, 17:18:06
Reply #11

racoonart

  • Active Users
  • **
  • Posts: 1446
    • View Profile
    • racoon-artworks
I'm not talking about technical issues. I'm talking about realism. It's like shooting brightly lit people on greenscreen and composing them into a dark night scene. It's just not fitting lighting information. Technically it's still valid but it does not make any sense in respect to realism. It's the same thing in Corona - you can do a lot of nonsense with moving objects, lights and what-not, but you're starting to use simply wrong information as soon as you change something after caching your secondaries.
Any sufficiently advanced bug is indistinguishable from a feature.

2013-11-16, 17:20:14
Reply #12

michaltimko

  • Active Users
  • **
  • Posts: 305
  • Coronaut (c)
    • View Profile
Gotcha...but i dont care abour realism in commercial projects anyway. I just wanted to say that i had no flickering with moving sun.
Moving smaller light sources should be problem of course.
Coronaut!(c)2011

Supporting Corona in commercial projects since pre-alpha

2013-11-16, 19:09:44
Reply #13

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Hello fobus

You can show the setting of all the values ​​of this material in your scene? .. screenshot 
HDRI in environment - Portal - number light (values) .. etc etc !!?

In this curved surface was applied Normal modifiers?

2013-11-16, 21:05:10
Reply #14

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
Hello fobus

You can show the setting of all the values ​​of this material in your scene? .. screenshot 
HDRI in environment - Portal - number light (values) .. etc etc !!?

In this curved surface was applied Normal modifiers?

Of course I can. More of that: I'll share this test scene.
All scene surfasec is real geometry without any normal modifiers. Simple CoronaSky in background. No portals. Just look in attach.

BTW
As I tested this flickering was only presented with blurry reflections materials on surfaces. With standart materials without reflections I hasn't catched it. So my first try to reduce this flickering was to get "Refl glossiness threshold" as low as possible to archive acceptable render times. But this way  was wrong. It reduces the flickering but increases rendertimes for clean image.
« Last Edit: 2013-11-16, 21:13:04 by fobus »

2013-11-16, 21:40:58
Reply #15

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
I believe that directional sensivity of HDcache is what could improve reflection sampling precision of HDcache. But if you have both directional and positional sensitivities of HDcache very high, then precalc. time can grow radically. You should be able to compensate for that on different places, perhaps reducing precomp density and/or HDcache PT samples ;)

2013-11-16, 22:23:54
Reply #16

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
Positional sensivity rised to 100 was really right solution in my situation. So why we need to rise directional sensivity too?

2013-11-16, 23:10:32
Reply #17

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
Positional sensivity rised to 100 was really right solution in my situation. So why we need to rise directional sensivity too?

In case you would have reflective surfaces, HDcache set up to take care of glossy reflections (reflection threshold at default) , and you had some flickering that positional sensitivity would not resolve.

2013-11-17, 01:27:49
Reply #18

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Hello fobus

The council has suggested Rawalanche is correct.


You need to check the values ​​of Level and glossiness both for reflection and for the refraction (1 to 0.89/0.98)

HD Chace
Position sensitivity 100 does not help anything!
Max Record 99999 - vanishes (default is ok or values ​​between 300 and 2500 - always depends on the circumstances )

A touch of Ray Tracing 28/32

I took an example from your slot material "Corona Glass win"
the yellow arrow indicates that the material you produce more or less noise (from personal experience)


Waiting for your comparison to check for changes.

Professional model, perfect in construction

Regards
Raf

2013-11-17, 06:52:34
Reply #19

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
In case you would have reflective surfaces, HDcache set up to take care of glossy reflections (reflection threshold at default) , and you had some flickering that positional sensitivity would not resolve.

Unfortunately I can't really understood what this settings do (Positional/directional sensivity). In online interactive help they described as is. But as I've tested Positional sensivity set to 100 resovled flickering in this case. May be some flickering was left, but I can't see it in animation so I think it's no matter.

You need to check the values ​​of Level and glossiness both for reflection and for the refraction (1 to 0.89/0.98)

HD Chace
Position sensitivity 100 does not help anything!
Max Record 99999 - vanishes (default is ok or values ​​between 300 and 2500 - always depends on the circumstances )

A touch of Ray Tracing 28/32

I took an example from your slot material "Corona Glass win"
the yellow arrow indicates that the material you produce more or less noise (from personal experience)

Sorry, but I didn't undersrtood what do You mean A touch of Ray Tracing 28/32 .

Glossiness from 1 to 0.89/0.98 is a good idea and I'll try to check this in near future.
Position sensivity 100 is not Holy Grail of course, but it really helps me to produce flicker free render with lower rendertimes in this case.
Max Record 9999 is recommended setting by online documentation. Why and what this means - I don't know :(

Final animation is rendering and after some post I'll share it in gallery. I've chacked it in progress and it seems that the flickering is gone.

2013-11-17, 09:41:30
Reply #20

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
Online documentation is outdated in case of HDcache, sorry about that...  100k for the max. records is recommended value now ;)

2013-11-17, 09:51:43
Reply #21

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
100k for the max. records is recommended value now ;)

And what problems may it brings if I set it to 9999?

2013-11-17, 10:55:44
Reply #22

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
Unnecessarily long precalc time as well as RAM consumption.

2013-11-17, 12:24:40
Reply #23

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Good morning

ray tracing ( reference image )

comparation " only HD cache " version original with modification HD cache - reduction noise

2013-11-17, 12:38:41
Reply #24

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Hello fobus

I acted only on HD Cache
Should arrange the materials in the reflection (glossiness)

Regards
Raf

2013-11-17, 15:06:20
Reply #25

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
ray tracing ( reference image )
comparation " only HD cache " version original with modification HD cache - reduction noise

I acted only on HD Cache
Should arrange the materials in the reflection (glossiness)

Sorry, but I didn't clearly understood what do You changed in HD cache. And I can be wrong but I see a bit of flickering in animation.

2013-11-17, 17:11:45
Reply #26

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile

[/quote]
Sorry, but I didn't clearly understood what do You changed in HD cache. And I can be wrong but I see a bit of flickering in animation.
[/quote]

Hello fobus

I hope to make myself understood!

I changed one of many values ​​of HD Cache "only HD cache", including the position sensitivity from 100 to 15
a demonstration of what is written above in the previous post, that the value 100 does not help!

This test resulted in a reduction of the noise that generates flicker in the animation  "Reduction" (see the file .gif)


1- on the materials I have not changed anything, but you should change the value of glossiness (see previous post) .. in the scene

2 - I wait for your change to reflect and come to a conclusion, because it is a subject that interests me


Thanks
Raf

2013-11-17, 20:03:28
Reply #27

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
I changed one of many values ​​of HD Cache "only HD cache", including the position sensitivity from 100 to 15
a demonstration of what is written above in the previous post, that the value 100 does not help!

This test resulted in a reduction of the noise that generates flicker in the animation  "Reduction" (see the file .gif)

As I see in Your Future-INT-CAM_.mov the flickering is presented. And if You really did not changed anything but  "the position sensitivity from 100 to 15" than it is another confirmation of usefulness of this setting. Tomorrow morning I'll try to test this settings in this test scene to show it again. But I have an animation rendered with final quality and it has no flickering with help of position sensivity set to 100 instead of 20 defaults.

2013-11-17, 20:12:57
Reply #28

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Perfect fobus

so check it and try to understand better!

2013-11-18, 00:59:25
Reply #29

poko

  • Active Users
  • **
  • Posts: 73
    • View Profile
Some tests with your scene.
Best.

2013-11-18, 10:36:21
Reply #30

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
to poko:
I don't care about the noise it this tests. And again: for real animation save and load secondary GI will not work as we need.

And the test:
I've rendered 4 clips with different settings of HD cache. First one (default) rendered with default settings of Corona (except Exposure comp -3.5EV) with HD cache as secondary GI engine.
The second one (PS100) - with position sensivity rised up to 100 with all settings from previous clip.
The third (DS50_PS100) - with direction sensivity rised up to 50 with all settings from previous clip.
And the fourth (PD0.25_PTS64_DS50_PS100) - with precomp density lowered to 0.25 and PT samples lowered to 64 with all settings from previous clip.

The results is:
Default settings - Huge flickering, low rendertimes, low noise.
Second try - low flickering, low to mid rendertimes, low noise.
Third try - See no flickering, huge rendertimes, mid to high noise.
fourth try - See no flickering, huge rendertimes (a tiny bit smaller than third try), mid to high noise.

2013-11-18, 11:14:34
Reply #31

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
It is extremely weird that noise patter as well as HDcache changes over time when camera, objects and lighting are stationary. That should never ever happen....

If it does, then it is some extremely huge bug...

2013-11-18, 12:50:24
Reply #32

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
It is extremely weird that noise patter as well as HDcache changes over time when camera, objects and lighting are stationary. That should never ever happen....

If it does, then it is some extremely huge bug...

I have only an public Alpha v5 version of Corona so may be this was fixed already. Anyway hera are this scene with defaults settings.

2013-11-18, 13:48:43
Reply #33

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Some tests with your scene.
Best.

Hello poko, nice work.

kindly, could you post the values ​​of the image number 6?


Thank you very much
Raf

2013-11-18, 14:05:57
Reply #34

poko

  • Active Users
  • **
  • Posts: 73
    • View Profile
Hi Rafpug.

PT-32
MSI-20
HD-1024
Cash is pre-calculated every frame, load and render.
This is the same test as v5. just in post reduce noise.
Strange is that in my test (compare to Fobus test) I don't have flickering problem, just noise.
Best.
PO

2013-11-18, 19:31:39
Reply #35

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
Cash is pre-calculated every frame, load and render.
This is the same test as v5. just in post reduce noise.
Strange is that in my test (compare to Fobus test) I don't have flickering problem, just noise.

Don't You think that in Your setup HD cache was saved for one frame only (the last one rendered in pre-calc pass)? Therу is no option for saving HD cache for animation or I'm missed somthing? I think You have no flickering because You have HD cache pre-calculated. But there is no way for this method for real animation if you have animated characters, lights etc.

2013-11-18, 20:19:32
Reply #36

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
Cash is pre-calculated every frame, load and render.
This is the same test as v5. just in post reduce noise.
Strange is that in my test (compare to Fobus test) I don't have flickering problem, just noise.

Don't You think that in Your setup HD cache was saved for one frame only (the last one rendered in pre-calc pass)? Therу is no option for saving HD cache for animation or I'm missed somthing? I think You have no flickering because You have HD cache pre-calculated. But there is no way for this method for real animation if you have animated characters, lights etc.

There are a few "experts" on this forum with need to contribute to any discussion at all cost regardless of if they actually understand the topic. ;)


2013-11-19, 15:58:28
Reply #38

poko

  • Active Users
  • **
  • Posts: 73
    • View Profile
Hi Rawalanche.
I want to find no flickering solution.
I just make some tests with attached scene hope can help.
I'm new in Corona and I'm not doing "viz" like almost all "experts" here.
So for me more important is rendering animation, fast, no flickering, etc.

2013-11-20, 12:12:03
Reply #39

poko

  • Active Users
  • **
  • Posts: 73
    • View Profile
Cash is pre-calculated every frame, load and render.
This is the same test as v5. just in post reduce noise.
Strange is that in my test (compare to Fobus test) I don't have flickering problem, just noise.

Don't You think that in Your setup HD cache was saved for one frame only (the last one rendered in pre-calc pass)? Therу is no option for saving HD cache for animation or I'm missed somthing? I think You have no flickering because You have HD cache pre-calculated. But there is no way for this method for real animation if you have animated characters, lights etc.

Ok I see. Now I see that is just one frame cached. Thanks a lot;)
Btw.
Nice render, something different design then I daily see.
How you manage no flickering and noise remove?
Is helping change PS to 100 as Rawalanche suggest?
Best.
PO

2013-11-20, 14:53:47
Reply #40

fobus

  • Active Users
  • **
  • Posts: 388
    • View Profile
to poko:

Thank You.
Flickering is presented, but a tiny bit. This is the result of using PS 100. Noise is still there too. I set Corona to render 60 passes with 24 PT samples each. This way one frame was rendered in 50 minutes on i-7 2600k at 720p.

2013-11-20, 18:58:14
Reply #41

poko

  • Active Users
  • **
  • Posts: 73
    • View Profile
Hi Fobus.
Thanks for feedback.
I need to try your way.
But 50 min. for frame is way to long. Hope next version can speed up this.
Thx for patience:).
« Last Edit: 2013-11-20, 19:14:08 by poko »

2013-11-21, 00:46:36
Reply #42

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Hi Rafpug.

PT-32
MSI-20
HD-1024
Cash is pre-calculated every frame, load and render.
This is the same test as v5. just in post reduce noise.
Strange is that in my test (compare to Fobus test) I don't have flickering problem, just noise.
Best.
PO

Hello poko,
a topic that has me very intrigued

on the internet I found this :
Once the prepass has been completed you will need to specify the amount of blending between the irradiance maps. So before you render, you will need to decide on how many irradiance maps you wish to blend. This is because it effects your animation timeline range. For example, if you have a blend of 2, this means it will blend 2 frames before and 2 frames after. In order to render frame 5, it will blend frames 3,4,5,6,7. Frame 6 will blend frames 4,5,6,7,8 and so on.

Increasing the number of blending frames reduces the chances of flickering, but this will also increase render times. If you increase the value too much, the result will be over smoothed you will lose detail. That said, frame 0 needs to have frames before it in order to blend correctly. Otherwise frame 0 will have less frames to blend than others, causing irregularities. Set your animation starting frame to –2, this will allow frame 0 to blend –2,-1,0,1,2. Repeat this for your last frame, if you animation ends at 100, set the animation finishing frame to 102.


Have you ever tried this solution?
Such a thing is feasible with CoronaRenderer?

Regard
Raf

2013-11-21, 13:25:06
Reply #43

poko

  • Active Users
  • **
  • Posts: 73
    • View Profile
Hi Rafpug.
Yes for some animation I do like you says in Vray or Final Render.
Here this example how:
http://help.chaosgroup.com/vray/help/150SP1/tutorials_imap2.htm
t=1206

Here in Corona I think is not working this way yet.
So why I did the tests for.
Maybe I'm wrong, and this working well in Corona, but saved file is the same size when you cache one frame or every 2 or 3 frames. So like Fobus noticed:
"Don't You think that in Your setup HD cache was saved for one frame only (the last one rendered in pre-calc pass)? Therу is no option for saving HD cache for animation or I'm missed somthing? I think You have no flickering because You have HD cache pre-calculated. But there is no way for this method for real animation if you have animated characters, lights etc."
« Last Edit: 2013-11-21, 14:08:28 by poko »

2013-11-23, 18:21:39
Reply #44

rafpug

  • Active Users
  • **
  • Posts: 722
    • View Profile
Hello poko
thanks for the examples!

What is the pre-calculation of the HD Cache for animation?
There is a procedure to perform?

thank
Raf