private void Awake()
    {
        Resolution.Bake();
        InitRenderTexture();
        MakeBuffer(ref dummyRenderCheckBuffer, 1, sizeof(int), renderCheckBufferData);
        Display.texture = displayTexture;

        oldFieldOfView = Camera.fieldOfView;
        resetTransforms.Add(Camera.transform);
        resetTransforms.Add(DirectionalLight.transform);
    }
Ejemplo n.º 2
0
    private void Awake()
    {
        Resolution.Bake();
        ThreadGroupSize.Bake();
        CellSize.Bake();

        MakeBuffer(ref dummyRenderCheckBuffer, 1, sizeof(int), renderCheckBufferData);
        MakeBuffer(ref dummyStepCheckBuffer, 1, sizeof(int), stepCheckBufferData);
        MakeTexture(ref workingTexture, Resolution);
        MakeTexture(ref displayTexture, Resolution);

        gameResolution = Resolution.Value / CellSize.Value;
        gameResolution.Bake();

        MakeTexture(ref workingGameTexture, gameResolution);
        MakeTexture(ref gameTexture, gameResolution);
        Display.texture = displayTexture;
    }