Unity3d Tutorial: Application Class Part5 - targetFrameRate
Unity3D 2012. 6. 13. 14:44http://file:///Applications/Unity/Documentation/ScriptReference/Application-targetFrameRate.html
Instructs game to try to render at a specified frame rate. Setting targetFrameRate to -1 (the default) makes standalone games render as fast as they can, and web player games to render at 50-60 frames/second depending on the platform. Note that setting targetFrameRate does not guarantee that frame rate. There can be fluctuations due to platform specifics, or the game might not achieve the frame rate because the computer is too slow. If vsync is set in quality setting, the target framerate is ignored, and the vblank interval is used instead. The vBlankCount property on qualitysettings can be used to limit the framerate to half of the screens refresh rate (60 fps screen can be limited to 30 fps by setting vBlankCount to 2) targetFrameRate is ignored in the editor.static var targetFrameRate : int
Description
using System.Collections;
public class example : MonoBehaviour {
void Awake() {
Application.targetFrameRate = 300;
}
}
기본값 - 1
유니티 에디터 문제인지 몰라도 한번 값을 바꾸면 이전값을 계속 가져오는듯 하다 이때는 에디터를 껐다 키면 정상적으로 기본값 -1을 확인할수 있다.
'Unity3D' 카테고리의 다른 글
3. 3DPlatform Tutorial - 3인칭 게임 튜토리얼 (0) | 2012.06.19 |
---|---|
Game Design 101 - Unity Viewport / 1st & 3rd person camera (0) | 2012.06.18 |
Unity3d Tutorial: Application Class Part4 - unityVersion (0) | 2012.06.13 |
Unity3d Tutorial : Application Class Part 3 - platform (0) | 2012.06.13 |
Unity3d Tutorial: Application Class Part 3 - isEditor (0) | 2012.06.13 |