KudanAR - iOS  1.6.0
ARVideoNode Class Reference

#import <ARVideoNode.h>

Inherits ARMeshNode.

Instance Methods

(instancetype) - initWithVideoTexture:
 
(instancetype) - initWithBundledFile:
 
(void) - play
 
(void) - pause
 
(void) - reset
 
- Instance Methods inherited from ARNode
(void) - addChild:
 
(void) - addChildren:
 
(void) - removeChild:
 
(void) - removeAllChildren
 
(void) - remove
 
(ARNode *) - findChildWithName:
 
(void) - markWorldTransformAsDirty
 
(void) - translateByX:y:z:
 
(void) - translateByX:y:z:transformSpace:
 
(void) - translateByVector:
 
(void) - translateByVector:transformSpace:
 
(void) - scaleByUniform:
 
(void) - scaleByX:y:z:
 
(void) - scaleByVector:
 
(void) - rotateByDegrees:axisX:y:z:
 
(void) - rotateByRadians:axisX:y:z:
 
(void) - rotateByQuaternion:
 
(ARVector3 *) - positionToWorld:
 
(ARVector3 *) - positionToEye:
 
(ARQuaternion *) - orientationToWorld:
 
(ARQuaternion *) - orientationToEye:
 
(CGPoint) - viewPortFromNodePosition:
 
(void) - render
 
(void) - preRender
 
(void) - postRender
 
(void) - addTouchTarget:withAction:
 
(void) - didReceiveTouch
 
(ARVector3 *) - nodeFromViewPort:
 

Properties

ARVideoTexturevideoTexture
 
ARVideoTextureMaterialvideoTextureMaterial
 
- Properties inherited from ARMeshNode
ARMeshmesh
 
ARMaterialmaterial
 
BOOL cull
 
- Properties inherited from ARNode
NSString * name
 
ARNodeparent
 
NSArray< ARNode * > * children
 
NSArray * descendants
 
ARVector3position
 
ARVector3scale
 
ARQuaternionorientation
 
ARMatrix4localTransform
 
ARMatrix4worldTransform
 
ARMatrix4fullTransform
 
ARQuaternionfullOrientation
 
ARQuaternionworldOrientation
 
ARVector3worldScale
 
ARVector3worldPosition
 
ARVector3fullPosition
 
ARNodeworld
 
NSUInteger childCount
 
BOOL visible
 

Additional Inherited Members

- Class Methods inherited from ARMeshNode
(instancetype) + testMeshNodeWithRed:green:blue:
 
(instancetype) + testMeshNodeWithTexture:
 
(instancetype) + meshNodeWithTexture:width:height:
 
(instancetype) + meshNodeWithRed:green:blue:width:height:
 
- Class Methods inherited from ARNode
(instancetype) + nodeWithName:
 
- Protected Types inherited from ARNode
enum  TransformSpace { ARNodeTransformSpaceLocal, ARNodeTransformSpaceParent, ARNodeTransformSpaceWorld }
 

Detailed Description

An ARVideoNode is a subclass of ARNode that is used to render video content.

Method Documentation

◆ initWithBundledFile:

- (instancetype) initWithBundledFile: (NSString *)  file

Initialise with a file in the app bundle. This is the simplest and easiest way to load a video file that has audio into a video node.

Example of use:

ARVideoNode *videoNode = [[ARVideoNode alloc] initWithBundledFile:@"example.mp4"];
Parameters
fileThe file in the app bundle to initialise with. The file path is relative to the app bundle and includes the file extension.

◆ initWithVideoTexture:

- (instancetype) initWithVideoTexture: (ARVideoTexture *)  videoTexture

Initialise an ARVideoNode using a video texture. This is useful for when your video and audio are in separate files.

Example of use:

ARVideoTexture *videoTexture = [[ARVideoTexture alloc] initWithVideoFile:@"video.mp4" audioFile:"audio.aac"];
ARVideoNode *videoNode = [[ARVideoNode alloc] initWithVideoTexture:videoTexture];
Parameters
videoTextureThe video texture to initialise with.

◆ pause

- (void) pause

Pauses playback. Current video time will be saved.

Example of use:

[videoNode pause];

◆ play

- (void) play

Starts/resumes playback from the saved time. If no time is currently saved, starts from the beginning. Default playback state is paused.

Example of use:

[videoNode play];

◆ reset

- (void) reset

Reset the video's position to 0 and its state to paused.

Example of use:

[videoNode reset];

Property Documentation

◆ videoTexture

- (ARVideoTexture*) videoTexture
readwritenonatomicassign

The video texture associated with the node.

◆ videoTextureMaterial

- (ARVideoTextureMaterial *) videoTextureMaterial
readwritenonatomicassign

The material of this video node, which is typically an instance of ARVideoTextureMaterial.

This provides convenient access to this node's material without need for a cast.


The documentation for this class was generated from the following files:
-[ARVideoNode reset]
void reset()
Definition: ARVideoNode.m:102
-[ARVideoNode play]
void play()
Definition: ARVideoNode.m:92
ARVideoNode::videoTexture
ARVideoTexture * videoTexture
Definition: ARVideoNode.h:16
-[ARVideoNode pause]
void pause()
Definition: ARVideoNode.m:97
ARVideoTexture
Definition: ARVideoTexture.h:9
ARVideoNode
Definition: ARVideoNode.h:12