Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to stretch the animation to cover entire screen ? #10

Closed
Shruthi48 opened this issue Aug 11, 2021 · 6 comments
Closed

How to stretch the animation to cover entire screen ? #10

Shruthi48 opened this issue Aug 11, 2021 · 6 comments

Comments

@Shruthi48
Copy link

Shruthi48 commented Aug 11, 2021

Hi ,

At the moment the animation is visible only on part of the screen , how can I stretch it to show the animation on the entire screen ?

Screenshot 2021-08-11 at 7 28 47 PM

@nickcam
Copy link
Owner

nickcam commented Aug 11, 2021

That's odd. There's a element that should resize to the size of the screen, this is where the particles are drawn. Go into your browser debugging tools and make sure the canvas is sized correctly, ie: the width and height style properties are being set correctly.

If they're not, should be pretty easy to find where they're getting set and why they're not updating. I can't remember exactly where that's happening sorry.

@Shruthi48
Copy link
Author

The canvas width and height is getting set properly but I wasn't able to figure out why isn't the animation drawn on entire canvas. The issue is in the demo url - http://animatedenvironmentlayer.azurewebsites.net/index.html

@nickcam
Copy link
Owner

nickcam commented Aug 12, 2021

Oh right, I don't get the problem when I view the demo page. I've tried it in Chrome and Firefox. What browser are you using?

@Shruthi48
Copy link
Author

Shruthi48 commented Aug 12, 2021

I'm using chrome , its the same when I open it on safari

Screenshot 2021-08-12 at 2 50 48 PM

firefox too
Screenshot 2021-08-12 at 3 09 06 PM

@sanketkardile
Copy link

@Shruthi48 did you solved this issue?

@nickcam
Copy link
Owner

nickcam commented Mar 29, 2023

This was related to window.devicePixelRatio being greater than 1. Have catered for this in the latest commit.

@nickcam nickcam closed this as completed Mar 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants