Пример #1
0
        /// <summary>
        ///     Se cierra el ejemplo. Liberar recursos
        /// </summary>
        internal void DisposeElements()
        {
            if (tgcTerrain != null)
            {
                tgcTerrain.Dispose();
            }

            foreach (var meshObj in MeshObjects)
            {
                meshObj.mesh.Dispose();
            }
        }
Пример #2
0
        /// <summary>
        ///     Se llama cuando termina la ejecución del ejemplo.
        ///     Hacer Dispose() de todos los objetos creados.
        ///     Es muy importante liberar los recursos, sobretodo los gráficos ya que quedan bloqueados en el device de video.
        /// </summary>
        public override void Dispose()
        {
            disposing = true;
            shark.Dispose();
            efectoDesaparecer.Dispose();
            sonidoUnderwater.dispose();
            Player.Dispose();
            oceano.Dispose();
            heightmap.Dispose();

            foreach (var pez in peces)
            {
                pez.Dispose();
            }
            foreach (var coral in corales)
            {
                coral.Dispose();
            }
            foreach (var metal in metales)
            {
                metal.Dispose();
            }
            foreach (var piedra in piedras)
            {
                piedra.Dispose();
            }

            nave.Dispose();

            interiorNave.Dispose();
            mesaNave.Dispose();
            sogaInterior.Dispose();
            lamparaNave.Dispose();
            sillaInterior.Dispose();
            timonInterior.Dispose();
            Particulas.Dispose();
            Oceano.Dispose();
            Hud.Dispose();
            maskTexture.dispose();
            perlinTexture.dispose();
            arma.Dispose();
            effect.Dispose();
            renderTarget.Dispose();
            fullScreenQuad.Dispose();
            depthStencil.Dispose();
            coralesBrillantes.Dispose();
            FBVerticalBloom.Dispose();
            FBHorizontalBool.Dispose();
        }
Пример #3
0
        public override void Dispose()
        {
            circuito.dispose();
            car.Dispose();
            effect.Dispose();
            terrain.Dispose();
            skyBox.Dispose();

            g_pRenderTarget.Dispose();
            g_pRenderTarget2.Dispose();
            g_pRenderTarget3.Dispose();
            g_pRenderTarget4.Dispose();
            g_pRenderTarget5.Dispose();
            g_pDepthStencil.Dispose();
            g_pVBV3D.Dispose();
        }
Пример #4
0
 public override void Dispose()
 {
     mesh.Dispose();
     effect.Dispose();
     terrain.Dispose();
     g_pDepthStencil.Dispose();
     g_pBaseTexture.Dispose();
     g_pVelocidad.Dispose();
     g_pVelocidadOut.Dispose();
     g_pPos.Dispose();
     g_pPosOut.Dispose();
     g_pTempPos.Dispose();
     g_pTempVel.Dispose();
     g_pHeightmap.Dispose();
     scene.disposeAll();
     g_pVB.Dispose();
     g_pVBV3D.Dispose();
 }
Пример #5
0
        public void Dispose()
        {
            //Se hace dispose del modelo fisico.
            dynamicsWorld.Dispose();
            dispatcher.Dispose();
            collisionConfiguration.Dispose();
            constraintSolver.Dispose();
            overlappingPairCache.Dispose();
            personajeBody.Dispose();
            floorBody.Dispose();

            //Dispose de Meshes
            foreach (TgcMesh mesh in meshes)
            {
                mesh.Dispose();
            }

            personaje.Dispose();

            terreno.Dispose();
        }
Пример #6
0
        public override void Dispose()
        {
            effect.Dispose();
            recoltableItemEffect.Dispose();
            wavesEffect.Dispose();
            playerModel.Dispose();
            bulletManager.Dispose();
            skyBox.Dispose();
            //skyBoxUndersea.Dispose();
            surfacePlane.Dispose();
            underseaTerrain.Dispose();
            collectModel.Dispose();
            shipHelmPoster.Dispose();

            //Dispose de Meshes
            meshes.ForEach(x => x.Dispose());

            shipHelmMesh.ForEach(x => x.Dispose());

            historyModel.Dispose();

            music.closeFile();
        }
Пример #7
0
 public override void Dispose()
 {
     foreach (TgcMesh m in meshes)
     {
         m.Dispose();
     }
     effect.Dispose();
     skyBox.Dispose();
     terrain.Dispose();
     pasto.Dispose();
     arbol.Dispose();
     arbusto.Dispose();
     g_pRenderTarget.Dispose();
     g_pGlowMap.Dispose();
     g_pRenderTarget4Aux.Dispose();
     g_pRenderTarget4.Dispose();
     g_pVBV3D.Dispose();
     g_pDepthStencil.Dispose();
     for (int i = 0; i < NUM_REDUCE_TX; i++)
     {
         g_pLuminance[i].Dispose();
     }
     g_pLuminance_ant.Dispose();
 }
Пример #8
0
 public override void Dispose()
 {
     terrain.Dispose();
     physicsExample.Dispose();
 }
Пример #9
0
 public void DisposeEscenario()
 {
     skyBox.Dispose();
     heightmap.Dispose();
     tgcScene.Meshes.ForEach(mesh => mesh.Dispose());
 }