When I use Ti.Media.showCamera() with an overlay, the camera frame is fixed at the top so it remains a black stripe at the bottom.
But I need the camera's image was in full screen, and not only fastened at the top
I can not move it in any way.. does anyone know a solution?
This is my code:
Ti.Media.showCamera({
allowEditing : false,
overlay : $.overlay,//overlayView,
showControls : false,
mediaTypes : [Ti.Media.MEDIA_TYPE_PHOTO],
autohide : false,
transform: Ti.UI.create2DMatrix().scale(1)
});
So, this used to work ok in previous tiSDKs and/or iOS SDK targets. Titanium uses an OLD method for its camera that apple has been trying to get rid of. With iOS 10, apple removed the hook that Titanium was using to work around all this.
It was reported and, right or wrong, was dismissed as not a titanium problem.(https://jira.appcelerator.org/browse/TIMOB-24036)
You can use Mike Fogg's module (https://github.com/mikefogg/SquareCamera) to achieve the look you once had, because it uses the appropriate foundation classes for its media work.
Related
I am building a two player game.
When player A makes a turn, the screen should turn upside down for player seated on the opposite side.
I tried using transform on a View, but think that only works on text.
So I am looking for a solution to either
a. Keep the device orientation, but turn it upside down by 180 degrees.
b. Rotate the root view on my app by 180 degrees
I would appreciate suggestions.
Correction - turning the view using transform worked for me.
It was merely not working when in storyboard mode (not sure why).
Below works!
const rotateView = {
flex: 1,
transform: [{
rotate: '-180deg'
}],
}
View is rotated by 180 degrees.
I'm investigating if it's possible to implement the same functionalities of ZBar library with iOS 7 api.
Everything was good so far thanks to this tutorial.
However, I now want to have a green box shown on the screen whenever the camera detects a QRCode. The green box is supposed to wrap around the QRCode.
From the delegate of AVCaptureMetadataOutput, I can grab AVMetadataObject but the bounds getting from this object is always very small which is not correct, given the fact that my QRCode is very big on the screen.
Anyone has any ideas on how to achieve the green focusing box?
P/S: I came across the documentation and couldn't understand this line "If the metadata originates from video, bounds
may be expressed as scalar values from 0. - 1.". This is for the bounds property of AVMetadataObject
You can look at this tutorial for qrCode scanning using iOS 7.
I had to do the same thing in my scanner app. Here is a link that I found very useful and pretty much answered all my questions.
He goes step by step from setting up the scanner to adding the bounding box.
The following is mandatory: "Update the launch image to include the status bar area if it doesn’t already do so.". This might sound stupid but I don't exactly understand what this means. Do I actually need to but a static status bar into my launch image ? Or does it just mean I should be aware that the statusbar will be overlapped and should adjust my image if nessecary? So doing nothing will not get my app rejected? Any clarification on this subject is appreciated.
This only means that your launch image must be full resolution of the device display:
Example:
- iPad Mini Retina Display: 2048px x 1536px
I'm trying to create an animated ripple effect on the desktop of OSX. Not just the desktop, actually, but image of the desktop plus any windows on it.
As if the screen was a pond and a stone fell on a given point of it.
Can anyone give me some pointers on how to achieve this? Any sample source code woud be gratlt appreciated.
There is a small code fragment on this page, that describes how the author implemented a water ripple effect on iOS. Contains some development information and a video:
http://fabiensanglard.net/fluide/
Update:
Core Image provides a CIRippleTransition (http://developer.apple.com/library/mac/documentation/GraphicsImaging/Reference/CoreImageFilterReference/Reference/reference.html#//apple_ref/doc/filter/ci/CIRippleTransition - AFAIK this was used by Dashboard < 10.7)
This example uses the CI Transition in combination with Core Animation:
http://theocacao.com/document.page/528
If you combine that with a simple screenshot you get an image of your desktop & the desired ripple effect.
I am using UIImagePickerController for selecting images from the photo library. But I am getting a message on the console saying "Using two-stage rotation animation. To use the smoother single-stage animation, this application must remove two-stage method implementations."
What is this due to ?
Thanks
Several people appear to be having the same problem. None of these links provide a solution (as far as I can tell), so this post is intended just as a starting point for more searching. I have made it CW.
stackoverflow: Single-Stage vs Two-Stage Animation for iPhone Apps
cocoabuilder: how to change to the smoother single stage animation
stackoverflow: tabbarcontroller and navigationcontrollers in landscape mode
Apple support: 11186784
That normally means you have implemented one of:
willAnimateFirstHalfOfRotationToInterfaceOrientation:duration:
willAnimateSecondHalfOfRotationFromInterfaceOrientation:duration:
on one of your view controllers, even if they are empty. This is neither wrong nor deprecated, the message just say it could possibly done better if you moved your implementation to: willAnimateRotationToInterfaceOrientation:duration: