4
は、私はアクションで自分のゲームでいくつかの3D効果を可能にするには、このデプスバッファを設定できませんか? <a href="http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide%3aeffects" rel="nofollow">some cocos2d-iphone documentation</a>で
// IMPORTANT: Call this function at the very beginning, before running your 1st scene
// Create a depth buffer of 24 bits
// These means that openGL z-order will be taken into account
[[CCDirector sharedDirector] setDepthBufferFormat:kDepthBuffer16];
を置くように言われました。しかし何らかの理由でsetDepthBufferFormat
もkDepthBuffer16
もXCodeで認識されません。何か案は?
ああ:depthFormatの追加のパラメータを取ります「viewWithFrame」バリアントがあります。ありがとう。ところで、なぜ私が3Dアクションを実行すると、背景が黒くなるのか知っていますか? – Voldemort
深さバッファがないためにある可能性があります。深度テストも有効にする必要があります:[[CCDirector sharedDirector] setDepthTest:YES]; – LearnCocos2D