An ALAsset object represents a photo or a video managed by the Photo application.
Questions tagged [alasset]
214 questions
3
votes
1 answer
What is the difference between ALAsset and PHAsset?
I've been curious this morning about PHAsset. I used to deal with ALAsset last month. I downloaded an iOS project from Apple website that uses ALAsset to make a simple iOS Photos-like app, and I modified it to add more features to be more iOS…

Glenn Posadas
- 12,555
- 6
- 54
- 95
3
votes
0 answers
ALAsset defaultRepresentation issue with iCloud pictures
Using ALAsset, I get a nil answer for a lot of pictures fetched from iCloud in my app when calling the method : defaultRepresentation.
However, when I call "thumbnail" I get the associated small picture.
It mostly happens when the picture has just…

Sonastra
- 182
- 1
- 9
3
votes
0 answers
How to share a video from UIActivityViewController to Vimeo or Facebook using Swift
I'm trying to share a video to Vimeo and or Facebook. I'm able to do it from the Library, but when I try to create it in code, it fails this far I have tried this
func showSheet() {
let bundle = NSBundle.mainBundle()
let…

user379468
- 3,989
- 10
- 50
- 68
3
votes
1 answer
Adding an Image to ALAssetsLibrary using XCTest
I have an app that uses photos extensively, making several operations on them:
resizing
cropping
metadata extraction
Most of the methods I wrote operate on AlAssets therefore I would like to write my tests (I'm using the new XCTest framework) to…

user361526
- 3,333
- 5
- 25
- 36
3
votes
1 answer
ALAsset pointer throw EXC_BAD_ACCESS when access it
I am developing an image gallery which permits to select some pictures from the iPhone and display them.
Some explanations about this gallery:
An UITableView displays the different directories which contain iPhone pictures
When the user click on…

Jean Lebrument
- 5,079
- 8
- 33
- 67
3
votes
1 answer
Fast way of obtaining thumbnail from ALAsset with filtered applied
A prompt and convenient way of gererating thumbnails from an ALAsset is described in the answer to question "Generating custom thumbnail from ALAssetRepresentation" — see a blog post of the author.
The only issue I have with this method is that it…

knuku
- 6,082
- 1
- 35
- 43
3
votes
1 answer
Does ALAsset only provide thumbnail of size 150x90? Its there any way of getting larger thumbnail size, say 320x320 or 640x640?
I tried getting a thumbnail CGImage from ALAsset class, but it only returns 120x90 pixels images on iPhone4, which look very bad. Is there a way of getting larger thumbnails (say 320x320 or 640x640)?
I want to load thumbnails quickly because full…

Nitin
- 31
- 2
3
votes
1 answer
Display an ALAsset using QLPreviewController
I'm wanting to use QLPreviewController to display ALAssets from the Photo Stream
QLPreviewController needs an NSURL to display the item
This works great when it is a File URL such as
/var/mobile/Applications/5374......9E0/Documents/image33.png
I…

NewDev
- 257
- 1
- 5
- 18
3
votes
1 answer
Using ALAsset photo in UIWebView img tag
I am able to successfully look up an image from the ALAssetsLibrary and use the UIImage in native views.
Is it possible to use that same asset's url (for example: assets-library://asset/asset.JPG?id=88AA03C4-E53F-4FE2-9752-9DA675D1FAF7&ext=JPG) in…

wrightcode
- 93
- 1
- 6
3
votes
2 answers
Is it possible to create an ALAsset object from NSData or other image type (CFImageRef, CIImage, UIImage)?
Is it possible to create an ALAsset object from NSData or other image type (CFImageRef, CIImage, UIImage)?
I don't want to save all of my applications images to the camera roll, but I want to be able to upload multiple images to Walgreen's…

Matt Foley
- 921
- 1
- 8
- 24
2
votes
2 answers
AssetsLibrary, how to enumerate all photos?
Is there better way to enumerate all photos on the device than this one?
for each asset group do this ...
[currentGroup enumerateAssetsUsingBlock:^(ALAsset *result, NSUInteger index, BOOL *stop)
{
if(result == nil)
…

Buron
- 1,193
- 2
- 13
- 23
2
votes
0 answers
Is it possible to set only the metadata of an ALAsset with writeModifiedImageDataToSavedPhotosAlbum or setImageData
Both writeModifiedImageDataToSavedPhotosAlbum and setImageData methods in ALAsset take both image data (in the form of an NSData object) and metadata (in the form of an NSDictionary object). I've got everything working to inject additional metadata…

berend
- 31
- 3
2
votes
2 answers
Trimming ALAsset video using UIVideoEditorController
I am having an ALAsset object of type video. I would like to trim this video using UIVideoEditorController. Following is the code snippet:
UIVideoEditorController *videoEditorController = [[UIVideoEditorController alloc]…

spd
- 2,114
- 1
- 29
- 54
2
votes
3 answers
Setting a UIImageView with ALAsset
I have a UIImageView and would like to set it to the contents of an ALAsset.
How is the ALAssets contents used to set a UIImage?

some_id
- 29,466
- 62
- 182
- 304
2
votes
1 answer
iphone image ALAsset problem
First of all sorry for the crappy formatting. I dont know how to format the code here.I am having a problem with retrieving the image from the photo library. I have pasted my code Please help me. I am having this problem from many days.
here, I am…

rakendu
- 73
- 2
- 6