[TIMOB-1049] thumbnailImageAtTime does not work for video player
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Invalid |
Resolution Date | 2011-04-15T02:42:33.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 1.4.0 |
Components | iOS |
Labels | n/a |
Reporter | Nolan Wright |
Assignee | Blain Hamon |
Created | 2011-04-15T02:42:32.000+0000 |
Updated | 2017-03-02T19:21:25.000+0000 |
Description
http://helpdesk.appcelerator.net/tickets/2799">http://helpdesk.appcelerator.net/tickets/2799
code:
var video_full_path = Titanium.Filesystem.resourcesDirectory + '/content/sample_movie.mp4';
var thumbnail_button = Titanium.UI.createButton({
title: 'Gen Thumbnail',
top: 200,
height:32,
width:160
});
thumbnail_button.addEventListener ('click', function()
{
var recent_vid = Titanium.Media.createVideoPlayer({
contentURL: video_full_path
});
Ti.API.info ("File: " + video_full_path);
Ti.API.info ("Duration: " + recent_vid.duration);
Ti.API.info ("Generating thumbnail...");
var thumbnail = recent_vid.thumbnailImageAtTime (2, Titanium.Media.VIDEO_TIME_OPTION_EXACT);
Ti.API.info ("Done generating thumbnail!");
});
win.add (thumbnail_button);
var play_button = Titanium.UI.createButton({
title: 'Play Video',
top: 100,
height:32,
width:160
});
play_button.addEventListener ('click', function()
{
var recent_vid = Titanium.Media.createVideoPlayer({
contentURL: video_full_path
});
Ti.API.info ("Playing " + video_full_path);
Ti.API.info ("Duration: " + recent_vid.duration);
recent_vid.play();
});
win.add (play_button);
Modified JS that proves this is not the issue:
Problem could be the video path, or the movie type not being supported under iPhone.
(from [a0a0e6883432d1a0745764ac15a49a0045a96d43]) [#1049 state:invalid] Added thumbnail image to Phone -> Play Movie -> Embedded to test #1049 and thumbnail generation in general. http://github.com/appcelerator/titanium_mobile/commit/a0a0e6883432d1a0745764ac15a49a0045a96d43"> http://github.com/appcelerator/titanium_mobile/commit/a0a0e6883432d...
Okay, this was broken in 1.3.0 - it must've been fixed when I did #1044.
Closed as invalid.