[View] [Edit] [Lock] [References] [Attachments] [History] [Home] [Changes] [Search] [Help]
api[VideoPreviewer-ios] index
Page for implementing wrappers of VideoPreviewer.framework for iOS.
Reflecting on ObjC objects defined by the library
- ensure you started The system server (and got the URL to access the server)
- connect to dji8 system from a workspace or Quick List.
- Save a global reference to library exports for exploring the contents
| appPool |
appPool := ObjCMirror tree @ #(
private var containers
Bundle Application
).
VPExports := (appPool at: appPool keys asArray first) @ #(
'dji8.app' Frameworks
'VideoPreviewer.framework'
VideoPreviewer
).
(VPExports collect: [:each| each name]) asLiteral
Note that this evaluation leaves a global array (VPExports) with the exported objects of the library, and returns an array with the names.
You can evaluate the expression with showIt to see the names in your workspace
- Inspect the exports at any time evaluating VPExports inspect
- To inspect the hierarchy
(ObjCMirror hierarchyFrom: VPExports) inspect; size
- To generate the code of full API evaluate (with showIt):
ObjCMirror codeForExports: VPExports
We don't need to generate wrapper for ALL the library
To export code for relevant classes evaluate
ObjCMirror codeForExports: (#( VideoPreviewer )
collect: [:each| ObjCClassMirror @ each ])
The code will include some methods we donīt need to use and others that need edition by hand.
After editing the code we end with the implementation we will publish for the framework
"VideoPreviewer.framework API implementation"
NSObject subclass: #VideoPreviewer category: #VideoPreviewer!
VideoPreviewer comment: '
UI component used to show the video feed streamed from DJI device.
FFmpeg is required. It consists of decoder, data buffer queue and OpenGL renderer.
Set the view before sending #start
@2017-today Alejandro Reimondo ([email protected])
'!
VideoPreviewer buildStaticFunctions: #(
#(instance VideoPreviewer)
)!
VideoPreviewer buildFunctions: #(
#adjustViewSize
#clearRender
#clearVideoData
#close
#decoderStatus
#encoderType
#frame
#getTickCount
#pause
#(push:length: #(_videoData length))
#reset
#resume
#rotation
#safeResume
#(setView: #(_aView) #Boolean)
#(start Boolean)
#status
#type
#unSetView
)!