I'm working on an android app which can download the video from server and store it in SD card. and plays it while the app is in offline mode. but i want the add one more functionality to my app. now the videos downloaded by app can be played by any video player in the device. But i want to restrict that functionality.so the videos downloaded by my app can only playable by my app(like youtube app).
I'm totally new to this functionality .. any ideas and approaches to achieve this ?
Thanks in advance ..
As mentioned by #Vivek Kumar Srivastava:
If you are working on Api Level-8 then I suggest to use getExternalFilesDir (String type)
instead of Environment.getExternalStorageDirectory() because there are two benefit using this
-all images and data will be automatically deleted when your application uninstall by user
-images do not visible in the media application (in Gallery).
Related
I am developing a video player where downloaded video tutorials have to be played offline.
I want to secure these video files. What is the best and economical way to encrypt these files per user
once user get video, they can share it with others. I want to restrict that.
Please suggest me some ideas of how I can protect these videos from piracy.
Please help
You could create a key per user and encrypt the file with that before downloading it into the user device. Using the same key you could decrypt the file while playing in you app
How does the YouTube offline feature work? I want to implement this feature in my app. Is there any solution?
Youtube Offline Features works in following manner:
Youtube app downloads the video.
Saves it into youtube app's data directory in encrypted format so other apps can't access it.
Encryption is done so that video can not be played by any other apps even if video is extracted from youtube app data directory on rooted Android device.
Video is decrypted while playing offline in the youtube app.
Video is deleted after a predefined time.
I am developing an application where downloaded video can not be accessed by user outside the app. I want to know how to make it possible that user can not accessed video outside the app and only play it in the app. thanks.
Yes it's possible to do so infact popular apps like youtube do it when you download a video for offline loading. you have to encrypt the video and delete the original. After doing that decode it back when you want to play
I am new to Android developing. I have lots of videos around the size of 500MB. I have been testing my app but i always transfered the videos through the usb cable and not directly through my app. Is there a way to embed these videos within my app so that they are automatically transfered to the sdcard? I just need to know if it is possible or not.
i don't think it is possible at all to store all your videos inside your app and make the final APK out of that.
beacuse, Android market has a size limitation of 50MB. see here http://android-developers.blogspot.in/2010/12/android-market-client-update.html
pratcise is, that developer (especially in the games section), let the users download a small basic application which downloads the rest over the network (if WiFi is available), so that the user doesn't have to download a sh*tload of stuff if he wants to install your app, let say while he is outside, using GPRS/UTMS, or roaming...
I've been following this blog to help me make a simple music player function with an Android app (http://simonmacdonald.blogspot.com/2011/05/using-media-class-in-phonegap.html).
All works well - but I would like some way to extract a list of all music media stored on the phone so the user can click a file and play it. Does anyone know if this is possible via phone gap? I'd need to access track name/artist etc and a link to the track.
Cheers
Paul
Prognosis is not good.... PhoneGap does not have an API for accessing the media library. So, you would have to fall back to the File API to locate music files, and then... you would have to read the binary data in the actual files to extract out the track/artist metadata. Ouch. Seems pretty impractical.
[EDIT]
By the way, PhoneGap is not the only game in town. Appcelerator seems to solve the same problem, and apparently has a richer API, which includes
access to media metadata