How to save the captured video?

49 views
Skip to first unread message

sakar

unread,
Jun 18, 2015, 6:54:40 AM6/18/15
to codenameone...@googlegroups.com
If you are experiencing an issue please mention the full platform your issue applies to:
IDE: NetBeans/Eclipse/IDEA
Desktop OS
Simulator
Device


I want to store the captured video but i am not able tp find appropriate class and methods to save it?Can someone help me to do this??

Shai Almog

unread,
Jun 18, 2015, 10:31:37 AM6/18/15
to codenameone...@googlegroups.com, sakar.ca...@gmail.com
Capture saves a video/picture to a file and returns a FileSystemStorage URL with the file. You will need to then copy the file to the location where you want it to reside.

Sakar Thapa

unread,
Jun 18, 2015, 12:59:00 PM6/18/15
to codenameone...@googlegroups.com, sakar.ca...@gmail.com
which class should i need to store video,i use Image class to store and ImageIO to copy.

Shai Almog

unread,
Jun 18, 2015, 11:19:02 PM6/18/15
to codenameone...@googlegroups.com, sakar...@gmail.com, sakar.ca...@gmail.com
ImageIO is used to resize an image. There is no such class for video.

sakar

unread,
Jun 19, 2015, 2:33:30 AM6/19/15
to codenameone...@googlegroups.com, sakar.ca...@gmail.com, sakar...@gmail.com
i have already stored image.
i have captured video but i have problem storing video  to the location where i want it to reside. How can i do that??

Shai Almog

unread,
Jun 19, 2015, 12:35:35 PM6/19/15
to codenameone...@googlegroups.com, sakar.ca...@gmail.com, sakar.ca...@gmail.com
Why don't you just copy the file to the new location? Did you look in the FileSystemStorage class.
Message has been deleted

sakar

unread,
Jun 21, 2015, 5:32:56 AM6/21/15
to codenameone...@googlegroups.com, sakar.ca...@gmail.com
I used  FileSystemStorge.getInstance().getOutputStream(path to save); to store video but doing this will create only blank file,contents are not copied...How to create file with contents;

sakar

unread,
Jun 21, 2015, 5:41:55 AM6/21/15
to codenameone...@googlegroups.com, sakar.ca...@gmail.com
I would like to request which methods of FileSystemStorage are used to store video

Fabrizio Grassi

unread,
Jun 21, 2015, 9:06:25 AM6/21/15
to codenameone...@googlegroups.com
Hi,
try Util.copy(inputStream, outputStream);

sakar

unread,
Jun 22, 2015, 12:50:26 AM6/22/15
to codenameone...@googlegroups.com
Thanx a lot Fabrizio.

Fabrizio Grassi

unread,
Jun 22, 2015, 2:06:05 AM6/22/15
to codenameone...@googlegroups.com
you are welcome!


On Thursday, June 18, 2015 at 12:54:40 PM UTC+2, sakar wrote:
Reply all
Reply to author
Forward
0 new messages