MaxstARSDK  3.5.0
MasSurfaceThumbnail.mm
1 //
2 // MasSurfaceThumbnail.m
3 // MaxstARSDKFramework
4 //
5 // Created by Kimseunglee on 2017. 12. 10..
6 // Copyright © 2017년 Maxst. All rights reserved.
7 //
8 
9 #import "MasSurfaceThumbnail.h"
10 #include "SurfaceThumbnail.h"
11 
12 @interface MasSurfaceThumbnail()
13 {
14  maxstAR::SurfaceThumbnail *_surfaceThumbnail;
15 }
16 
17 @end
18 
19 @implementation MasSurfaceThumbnail
20 
21 - (instancetype)init:(void*)surfaceThumbnail {
22  self = [super init];
23  if (self) {
24  _surfaceThumbnail = (maxstAR::SurfaceThumbnail*)surfaceThumbnail;
25  }
26  return self;
27 }
28 
29 - (int) getWidth {
30  return _surfaceThumbnail->getWidth();
31 }
32 
33 - (int) getHeight {
34  return _surfaceThumbnail->getHeight();
35 }
36 
37 - (int) getBpp {
38  return _surfaceThumbnail->getBpp();
39 }
40 
41 - (MasColorFormat) getFormat {
42  return (MasColorFormat)_surfaceThumbnail->getFormat();
43 }
44 
45 - (int) getLength {
46  return _surfaceThumbnail->getLength();
47 }
48 
49 - (unsigned char*) getData {
50  return _surfaceThumbnail->getData();
51 }
52 
53 @end
unsigned char * getData()
MasColorFormat getFormat()
Contains surface thumbnail image information of first keyframe.