Friday, 15 August 2014

ios - How to set contents of scenekit background to cube map -



ios - How to set contents of scenekit background to cube map -

i trying set background contents of scene skybox effect using array of 6 images.

i have created array of images in right order, know need use

+ (instancetype) materialpropertywithcontents:(id)contents

however i'm struggling work out how , utilize class method homecoming property containing cube map.

scnscene's "background" property of scnmaterialproperty class. can straight set it's contents array of 6 images setup skybox (see scnscene.h).

ascene.background.contents = @[@"right.png", @"left.png", @"top.png", @"bottom.png", @"back.png", @"front.png"];

make sure 6 images square , same dimensions.

ios scenekit skybox

No comments:

Post a Comment