ruffle icon indicating copy to clipboard operation
ruffle copied to clipboard

exporter: Allow providing a prng seed to get determinstic images from movies

Open Dinnerbone opened this issue 2 years ago • 3 comments

Hopefully after this change, any differences between two images of a movie will be caused by changes in Ruffle only

Dinnerbone avatar Aug 09 '22 15:08 Dinnerbone

Actually, ruffle-core already has a deterministic feature exactly for this purpose, which is enabled by exporter. It is currently used for mocking time/date, so I suggest to simply use get_current_date_time() instead of chrono::Utc::now() when seeding the PRNG.

relrelb avatar Aug 09 '22 18:08 relrelb

I agree with @relrelb, now that they reminded us, that since there is a feature specifically for the exact same purpose, it makes sense to use that for this too. In that case, the seed can also be a constant magic number even?

torokati44 avatar Aug 09 '22 20:08 torokati44

Great catch. I'll fix this up.

Dinnerbone avatar Aug 09 '22 21:08 Dinnerbone