4 ms·
I haven't looked at the code yet, but I've been curious how they do this. I am not a mathematician, but my understanding is that the affine transform only lets
by frankus 17y ago
I haven't looked at the code yet, but I've been curious how they do this. I am not a mathematician, but my understanding is that the affine transform only lets you scale, rotate, and skew the whole image at a time.
Is the page curl effect some kind of custom non-affine transform? Or am I missing a simple way to do this using a single linear transformation?
- BigZaphod 17y agoIt looks like it's just an undocumented Core Image filter applied to the layer.
- windsurfer 17y agoCan't you get banned from the application store if you use undocumented ipod features?
- allenbrunson 17y agoNot if you're Apple, and this is Apple's app that the author is talking about.
- glhaynes 17y agoSo far, all of the Apple apps on the App Store seem to abide by "the rules". I hope that continues.
- cubicle67 17y agoYou don't get banned, but your app may be withdrawn until the private API calls are removed
- BigZaphod 17y agoUsually the app just gets rejected if someone uses an undocumented feature. Jailbreakers or people developing just for fun or using the adhoc or (I think) corporate deployment method don't go through the approval process and therefore can't get banned/rejected. So for people in those situations, it's fun to know how to do it.
- samlittlewood 17y agoYou are right[1], and there won't be a single linear transform. This page curl will almost certainly be a piecewise linear approximation using a triangle mesh whose vertices are animated according to the user input. 1. The GPU will also support projective transforms - but that won't help here.
- DLWormwood 17y ago> This page curl will almost certainly be a piecewise linear approximation using a triangle mesh whose vertices are animated according to the user input. I honestly can't tell if your being facetious here or not. There are certainly much simpler ways of pulling off this effect; ask any Demoscene participant.
- wtallis 17y agoSimpler in what way? Demoscene code is seldom simple to read or write, and usually doesn't take advantage of hardware acceleration. When I think demoscene, I think of getting crazy effects through esoteric bit manipulations. When you're already shipping OpenGL and your whole UI is composited with that, the easiest option is probably just texture mapping on to a low-resolution mesh.
- hexley 17y agoFinally, a voice of clarity.