with fast scroll, twentmax animations shot with scrollmagic do not work correctly - animation

I have a problem, I am making a page with fullpage.js, I am launching animations with tweenLite every time I reach a section with Scrollmagic.
The problem is the following:
If I move in the normal order of the sections, one by one, the animations come out correctly, but when I jump, from the first section to the last one for example, the animations do not complement each other correctly everything gets decontrolled, I leave the sample of the page, so you can better understand what is happening.
Is there any optimal way to do this process, thanks in advance for the help.
http://pagina.gestionahora.co/

Related

why is computeBoundingBox() working differently if switching to another browser tab during loading?

I’m working on a complex project in threejs.
Trying to cut the corner:
I have to load an obj, create some pivot point to use as parent of the mesh inside this obj, let the user move and rotate the pivots.
It takes somewhere about 10 to 15 seconds to load due to its complexity.
My problem is that it is working flawlessly if I load the page and don’t change the focus, but if I change the browser tab or collapse the browser window I got a very specific problem:
geometry.computeBoundingBox() gives different results.
Is there someone who can help me figure out what’s happening?
To help you better understand the situation: at loading time I have to rotate the obj to -90° on the X axis (inverting Y and Z as a consequence); I think it’s relevant because the boundingBox calculation somehow inverts Y and Z and changes its min and max also, but as I said only if I switch tab or collapse the browser.
p.s. No matter the OS nor the browser. It’s a super consistent bug
Ok, I somehow solved the issue, but take it with a grain of salt:
the problem can be tracked back to the execution stack of javascript:
the first function computes the bounding box, the second uses this computation, but if the first function is somehow slower to execute, the second could not have what it needs.
What I did is to force javascript to execute functions in a given order and only when the previous is finished.
The problem occurred only when changing the tab because browsers optimize resources of non visible tabs, but the code I wrote was anyway too much entropic to work properly.
I hope what I found will be understandable and useful to someone else in future.

How "stream" a part of my screen to another part

So I have two big monitors. So I want to "stream" a small important part of the right monitor to the left. I have a specific part like 100x200pixels to the right of my screen I want to show at the very left.
I can do this but in a very ineffektive way by getting the bitmap from the right and displaying it in a gui to the left, then putting it in a loop where I create and destroy the gui showing an updated bitmap every 5 seconds. But this causes flickering and seems like a bad solution.
What is a better way to do this?
One thing that may help and reduce flicker is to use GuiControl. In your loop, instead of recreating the GUI each time, just update the picture control's contents.
GuiControl ,, picture_control_name , %A_Desktop%\updated_pic.bmp

Can't get GSAP to return to initial state

... and I've scoured the web for answers.
I boiled down the problem as much as I could in this jsfiddle:
https://jsfiddle.net/tko8rk5j/14/
There are 2 button, you click Go then Boost.
I'm trying to get the whole svg back to its initial position after the end of the Boost animation, so you can play the same sequence again and again.
I attempted various solutions suggested in other posts:
// tl.pause(0);
// tl.restart();
// tl.remove();
I also tried using the repeating TimeLineMax, but that just repeats the first animation sequence after the first click on Go button.
I'm not quite sure about what you're ultimately trying to do (which could greatly influence how I'd recommend building this effect), but here's a fork that I believe delivers the result you were asking for:
https://jsfiddle.net/2q1qrvty/7/
Your code was jumping back to the beginning before your animation even had a chance to run at all. Plus it was re-using the same timeline and constantly adding to it which isn't very efficient.
To make it go back to the beginning and stop as soon as it's done, just use an onComplete callback, like:
tl.eventCallback("onComplete", function() {
tl.pause(0);
});
There are a bunch of other ways to do this, but I don't want to overwhelm you :)
You may have better luck asking your questions in the dedicated GSAP forums at https://greensock.com/forums/
Happy tweening!

d3 Line graph animation not consistent cross-browser

I am working on animating a line graph using d3.js, and have been closely following this example. The code I have written works just like the example...but the bug I am trying to fix is one that is also unfixed in this example. (So going forward, just follow that link to see the bug for yourself)
In Chrome and IE10, the chart works just as it is supposed to. However, in Firefox, the line does not just draw itself from left to right. Instead, the page loads with the line already displayed, then the line erases itself from left to right, and then finally draws itself (again) from left to right like it should have done in the first place.
Also notice that the line drawing is twice as fast on firefox as the other browsers - this means that the issue is with the transition itself: the transition of the stroke-dashoffset property is handled differently by firefox and the other browsers. Specifically, if we remove the transition from the equation, the main difference becomes evident: With stroke-dashoffset set to totalLength, Firefox displays the entire path, as opposed to none of it, like the other browsers do.
So my question is: is this a bug, or is this bad form on my (and duopixel's) part? If the former is the case, does anybody know a workaround or a fix? If the latter, I would be very grateful if you could show me the correct way to do this!

How to use full-page background image leaving space for binding?

In Latex how can you make the background image to occupy the whole sheet on every page except a certain stripe on the inner side of each page? I can't figure it out.
I have a background image I'd like to be seen in whole on each page after printing/binding.
Matyi
There's some rather scary LaTeX hackery involving putting a picture environment under every page and using \includegraphics to put an image into that environment. You'll have to adjust the size of the image using the width option, and if you want even and odd pages you'll have to check the page number to know whether to shift the image right or left by changing \put(0,0) to \put(3,0) for example.
For page number testing try something on the order of
\ifodd\count0 ...stuff for odd-numbered pages ...
\else ... stuff for even-numbered pages ...
\fi
This isn't really a full answer but will be enough to get you started.
Honestly, I'd just add the white space in the image :)
Well, I was thinking of something like this.
Is this really so rare need to have? I myself need such a thing for the first time now but I don't feel it a so big oddity. It's strange for me that if you want a background to change over even and odd pages, just like normal text do, you need to feel betraying Latex logics. Or maybe I'm too fanatic of this challenge of mine and I want to feel the whole tex world change to fulfill my wishes. :)
Thank you for the answers!

Resources