Example #1
0
        public void SetupTextureDisplay()
        {
            if (!Directory.Exists(tempGcTxdsDir))
            {
                Directory.CreateDirectory(tempGcTxdsDir);
            }
            if (!Directory.Exists(tempPcTxdsDir))
            {
                Directory.CreateDirectory(tempPcTxdsDir);
            }

            try
            {
                ExportTextureDictionary(pathToGcTXD, CheckState.Indeterminate);
                PerformTXDConversionExternal(platform);
                TextureManager.LoadTexturesFromTXD(pathToPcTXD);
            }
            catch (Exception ex)
            {
                MessageBox.Show("Unable to setup texture display: " + ex.Message);
            }

            File.Delete(pathToGcTXD);
            File.Delete(pathToPcTXD);
        }
Example #2
0
        public void EnableTextureForDisplay(AssetRWTX RWTX)
        {
            if (!Directory.Exists(tempGcTxdsDir))
            {
                Directory.CreateDirectory(tempGcTxdsDir);
            }
            if (!Directory.Exists(tempPcTxdsDir))
            {
                Directory.CreateDirectory(tempPcTxdsDir);
            }

            ExportSingleTextureToDictionary(pathToGcTXD, RWTX.Data, RWTX.AHDR.ADBG.assetName);

            PerformTXDConversionExternal(platform);

            TextureManager.LoadTexturesFromTXD(pathToPcTXD);

            File.Delete(pathToGcTXD);
            File.Delete(pathToPcTXD);
        }