parallax

Parallax sidebar scrolling

心已入冬 提交于 2019-12-23 05:06:36
问题 I just want to create a parallax sidebar like http://readwrite.com/. Is there any plugin for that? or Is that a custom parallax for just this site? 回答1: After a few hours of experimenting and coding, I've finally come up with a very exposed solution that doesn't rely on fixed positions (or extensive jQuery plugins), but rather relies solely on absolute positioning using known offsets. See it in action at: http://jsfiddle.net/LntUP/ The code that makes it happen: $(document).ready(function() {

Multiple parallax video backgrounds

混江龙づ霸主 提交于 2019-12-23 01:11:47
问题 I found answers here on stackoverflow on how to create video div with parallax effect The recommended plugin was: https://github.com/linnett/backgroundVideo However I need multiple of parallax backgrounds on one site and I am having trouble with that, first one in order is allright, but the others are misspositioned, dont work absolutely as you would expect What is a solution for this? Calling the same plugin for every background separately? How do I do that? This doesnt quite work: <script>

Is there a way of detecting if the browser will freeze the DOM while scrolling?

守給你的承諾、 提交于 2019-12-22 08:49:53
问题 Is there a way of detecting if the browser will freeze the DOM or disable JavaScript while scrolling? It's known that some mobile browsers do this, and it effectively kills scrolling-based effects like parallax and animations. I'd like to effectively implement the following pseudocode without resorting to UA sniffing: if (!browserWillFreezeWhileScrolling) { initializeScrollingEffects(); } else { initializeFallbackScript(); // maybe unnecessary } From what I can see, Modernizr doesn't check it

FFTW plan creation using OpenMP

五迷三道 提交于 2019-12-22 05:25:20
问题 I am trying to perform several FFT's in parallel. I am using FFTW and OpenMP. Each FFT is different, so I'm not relying on FFTW's build-in multithreading (which I know uses OpenMP). int m; // assume: // int numberOfColumns = 100; // int numberOfRows = 100; #pragma omp parallel for default(none) private(m) shared(numberOfColumns, numberOfRows)// num_threads(4) for(m = 0; m < 36; m++){ // create pointers double *inputTest; fftw_complex *outputTest; fftw_plan testPlan; // preallocate vectors for

Questions about Request Animation Frame

半世苍凉 提交于 2019-12-21 12:32:49
问题 I'm trying to build a parallax site, which will move few elements while scrolling the site. But instead of using a scroll event listener I'm using requestAnimationFrame , after reading this post by Paul Irish, and this video which said that scroll listener is a bit buggy. My questions are: It looks quite smooth in Chrome, but it's flickering badly in Firefox. Did I do something wrong here? Does my code actually taking up more resources than using normal scroll event listener ? I can hear my

Problems with background image position on Stellar.js

我的梦境 提交于 2019-12-19 10:06:36
问题 I'm using stellar.js to add a parallax effect to a vertical scrolling website, but I'm having problems with the background positions. When I use the class "data-stellar-background-ratio" to add the parallax effect on a div I can't set the background position to right via CSS. All the background images just go to the left no matter what. I tried to use the position property plugin syntax available on the website, but it seems to break the parallax effect somehow. Can anybody help me? Thank you

How do I create a parallax effect in UITableView with UIImageView in their prototype cells

牧云@^-^@ 提交于 2019-12-18 10:17:18
问题 I'm building an app in iOS 8.4 with Swift. I have a UITableView with a custom UITableViewCell that includes a UILabel and UIImageView . This is all fairly straight forward and everything renders fine. I'm trying to create a parallax effect similar to the one demonstrated in this demo. I currently have this code in my tableView.cellForRowAtIndexPath func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { var cell = self.tableView

formular to calculate width/height (relative to parent) of container with translateZ inside of parent container with perspective

十年热恋 提交于 2019-12-18 04:36:12
问题 What is the formular to calculate the widths/heights of child elements with translateZ inside of parent container with set perspective (keyword: "parallax") relative to its parents width/height? I'd like to create a site with parallax effect on both axis. I was able to figure out everything i need for my mockup except one thing. How to calculate the childrens widths/heights when its above 100%. Because of parents perspective and childrens translateZ the childrens widths/heights visually don't

Android Parallax Effect and View Pager

无人久伴 提交于 2019-12-18 02:49:23
问题 I'm trying to achieve a parallax effect in my application. I have a FragmentActivity that implements the OnPageChangeListener interface and listens to my ViewPager scrolling events. To achieve this effect in my XML I have a LinearLayout behind all the other views with my background, and I move it in the onPageScrolled callback. If I simply swipe it's all ok, the effect works and the background position change. But when my finger leaves the screen, the background is redrawn at his original

Parallax effect with UIScrollView subviews

自闭症网瘾萝莉.ら 提交于 2019-12-17 22:43:19
问题 I'm trying to create a Parallax effect on a UIView inside a UIScrollView. The effect seems to work, but not so well. First i add two UIView sub-views to a UIScrollView and set the UIScrollViews contentSize. The Views sum up and create a contentSize of {320, 1000}. Then I implemented the following in scrollViewDidScroll: - (void)scrollViewDidScroll:(UIScrollView *)scrollView { CGFloat offsetY = scrollView.contentOffset.y; CGFloat percentage = offsetY / scrollView.contentSize.height; NSLog(@