VLCKit

VLCMediaThumbnailer.h
1 /*****************************************************************************
2 * VLCKit: VLCMediaThumbnailer
3 *****************************************************************************
4 * Copyright (C) 2010-2012 Pierre d'Herbemont and VideoLAN
5 *
6 * Authors: Pierre d'Herbemont
7 *
8 * This program is free software; you can redistribute it and/or modify it
9 * under the terms of the GNU Lesser General Public License as published by
10 * the Free Software Foundation; either version 2.1 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public License
19 * along with this program; if not, write to the Free Software Foundation,
20 * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
21 *****************************************************************************/
22
23 #import <Foundation/Foundation.h>
24 #if TARGET_OS_IPHONE
25 # import <CoreGraphics/CoreGraphics.h>
26 #endif
27
28 @class VLCMedia;
29 @class VLCLibrary;
30 @protocol VLCMediaThumbnailerDelegate;
31
35 @interface VLCMediaThumbnailer : NSObject
36
44 + (VLCMediaThumbnailer *)thumbnailerWithMedia:(VLCMedia *)media andDelegate:(id<VLCMediaThumbnailerDelegate>)delegate;
52 + (VLCMediaThumbnailer *)thumbnailerWithMedia:(VLCMedia *)media delegate:(id<VLCMediaThumbnailerDelegate>)delegate andVLCLibrary:(VLCLibrary *)library;
53
57 - (void)fetchThumbnail;
58
62 @property (readwrite, weak, nonatomic) id<VLCMediaThumbnailerDelegate> delegate;
66 @property (readwrite, nonatomic) VLCMedia *media;
70 @property (readwrite, assign, nonatomic) CGImageRef thumbnail;
75 @property (readwrite) void * libVLCinstance;
76
83 @property (readwrite, assign, nonatomic) CGFloat thumbnailHeight;
84
91 @property (readwrite, assign, nonatomic) CGFloat thumbnailWidth;
92
99 @property (readwrite, assign, nonatomic) float snapshotPosition;
100 @end
101
105 @protocol VLCMediaThumbnailerDelegate
106 @required
112 - (void)mediaThumbnailerDidTimeOut:(VLCMediaThumbnailer *)mediaThumbnailer;
118 - (void)mediaThumbnailer:(VLCMediaThumbnailer *)mediaThumbnailer didFinishThumbnail:(CGImageRef)thumbnail;
119 @end
VLCMediaThumbnailer
Definition: VLCMediaThumbnailer.h:35
VLCMediaThumbnailer::thumbnailHeight
CGFloat thumbnailHeight
Definition: VLCMediaThumbnailer.h:83
VLCMediaThumbnailer::delegate
id< VLCMediaThumbnailerDelegate > delegate
Definition: VLCMediaThumbnailer.h:62
-[VLCMediaThumbnailer fetchThumbnail]
void fetchThumbnail()
VLCMediaThumbnailer::thumbnailWidth
CGFloat thumbnailWidth
Definition: VLCMediaThumbnailer.h:91
VLCMediaThumbnailer::media
VLCMedia * media
Definition: VLCMediaThumbnailer.h:66
VLCLibrary
Definition: VLCLibrary.h:41
VLCMediaThumbnailer::snapshotPosition
float snapshotPosition
Definition: VLCMediaThumbnailer.h:99
VLCMedia
Definition: VLCMedia.h:112
VLCMediaThumbnailer::thumbnail
CGImageRef thumbnail
Definition: VLCMediaThumbnailer.h:70
VLCMediaThumbnailerDelegate-p
Definition: VLCMediaThumbnailer.h:105
VLCMediaThumbnailer::libVLCinstance
void * libVLCinstance
Definition: VLCMediaThumbnailer.h:75