OSDN Git Service

#34199 ドラムのライフゲージのテクスチャサイズを最適化。
authoryyagi <yyagi@16f42ceb-6dc6-49c8-ba94-f2d53467949d>
Mon, 1 Sep 2014 16:11:11 +0000 (16:11 +0000)
committeryyagi <yyagi@16f42ceb-6dc6-49c8-ba94-f2d53467949d>
Mon, 1 Sep 2014 16:11:11 +0000 (16:11 +0000)
git-svn-id: http://svn.osdn.jp/svnroot/dtxmania/trunk@769 16f42ceb-6dc6-49c8-ba94-f2d53467949d

DTXManiaプロジェクト/コード/ステージ/07.演奏/ドラム画面/CAct演奏Drumsゲージ.cs
DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge.psd
DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge_.psd [new file with mode: 0644]
DTXManiaプロジェクト/作成資料/ScreenPlayDrums_gauge_white.psd [new file with mode: 0644]
実行時フォルダ/System/Default/Graphics/ScreenPlayDrums gauge.png [deleted file]
実行時フォルダ/System/Default/Graphics/ScreenPlayDrums-gauge.png [new file with mode: 0644]
実行時フォルダ/System/Default/Graphics/ScreenPlayDrums_gauge_white.png [new file with mode: 0644]

index 8ee5558..badc090 100644 (file)
@@ -44,6 +44,7 @@ namespace DTXMania
                        if( !base.b活性化してない )\r
                        {\r
                                this.txゲージ = CDTXMania.tテクスチャの生成( CSkin.Path( @"Graphics\ScreenPlayDrums gauge.png" ) );\r
+                               this.txゲージ白 = CDTXMania.tテクスチャの生成Af( CSkin.Path( @"Graphics\ScreenPlayDrums_gauge_white.png " ) );\r
                                base.OnManagedリソースの作成();\r
                        }\r
                }\r
@@ -51,6 +52,7 @@ namespace DTXMania
                {\r
                        if( !base.b活性化してない )\r
                        {\r
+                               CDTXMania.tテクスチャの解放( ref this.txゲージ白 );\r
                                CDTXMania.tテクスチャの解放( ref this.txゲージ );\r
                                base.OnManagedリソースの解放();\r
                        }\r
@@ -143,40 +145,44 @@ namespace DTXMania
                                }\r
                                #endregion\r
                                #region [ 光彩 ]\r
-                               if ( this.txゲージ != null )\r
+                               if ( this.txゲージ != null )\r
                                {\r
-                                       //this.txゲージ.vc拡大縮小倍率 = new Vector3( 1f, 1f, 1f );\r
-                                       this.txゲージ.n透明度 = 180;\r
-                                       this.txゲージ.b加算合成 = true;\r
+                                       this.txゲージ白.vc拡大縮小倍率 = new Vector3( 1f, 1f, 1f );\r
+                                       this.txゲージ.n透明度 = 180;\r
+                                       this.txゲージ.b加算合成 = true;\r
                                }\r
-                               for ( int i = 0; i < 4; i++ )\r
                                {\r
                                        Rectangle rect = new Rectangle(\r
-                                               (int) ( ( 0x40 + ( i * 0x10 ) ) * Scale.X ),\r
                                                0,\r
-                                               (int) ( 0x10 * Scale.X ),\r
-                                               (int) ( 0x40 * Scale.Y )\r
+                                               0,\r
+                                               (int) ( 0x10 *     Scale.X ),\r
+                                               (int) ( 0x40 * 4 * Scale.Y )\r
                                        );\r
-                                       #region [ clipping ]\r
-                                       int ylight = ( n表示ゲージ最大値 - n表示するゲージの高さ ) + (int) ( i * 0x40 * Scale.Y );\r
+                                       #region [ clipping1 ]\r
+                                       int ylight = ( n表示ゲージ最大値 - n表示するゲージの高さ ) + (int) ( 0 * 0x40 * Scale.Y );\r
                                        if ( ylight >= n表示ゲージ最大値 )\r
                                        {\r
-                                               break;\r
-                                       }\r
-                                       if ( ( ylight + rect.Height ) > n表示ゲージ最大値 )\r
-                                       {\r
-                                               int d = ( ylight + rect.Height ) - n表示ゲージ最大値;\r
-                                               rect.Height -= d;\r
+                                               //break;\r
                                        }\r
                                        #endregion\r
-                                       if ( ( rect.Top < rect.Bottom ) && ( this.txゲージ != null ) )\r
+                                       else\r
                                        {\r
-                                               this.txゲージ.t2D描画(\r
-                                                       CDTXMania.app.Device,\r
-                                                       (int) ( 6 * Scale.X ),\r
-                                                       (int) ( ylight + 0.5f ),\r
-                                                       rect\r
-                                               );\r
+                                               #region [ Clipping2 ]\r
+                                               if ( ( ylight + rect.Height ) > n表示ゲージ最大値 )\r
+                                               {\r
+                                                       int d = ( ylight + rect.Height ) - n表示ゲージ最大値;\r
+                                                       rect.Height -= d;\r
+                                               }\r
+                                               #endregion\r
+                                               if ( ( rect.Top < rect.Bottom ) && ( this.txゲージ白 != null ) )\r
+                                               {\r
+                                                       this.txゲージ白.t2D描画(\r
+                                                               CDTXMania.app.Device,\r
+                                                               (int) ( 6 * Scale.X ),\r
+                                                               (int) ( ylight + 0.5f ),\r
+                                                               rect\r
+                                                       );\r
+                                               }\r
                                        }\r
                                }\r
                                #endregion\r
@@ -219,34 +225,34 @@ namespace DTXMania
                                #region [ 泡 ]\r
                                if ( this.txゲージ != null )\r
                                {\r
-                                   this.txゲージ.b加算合成 = true;\r
+                                       this.txゲージ.b加算合成 = true;\r
                                }\r
                                for ( int j = 0; j < 24; j++ )\r
                                {\r
-                                   this.st白い星[ j ].ct進行.t進行Loop();\r
-                                   int x = 6 + this.st白い星[ j ].x;\r
+                                       this.st白い星[ j ].ct進行.t進行Loop();\r
+                                       int x = 6 + this.st白い星[ j ].x;\r
                                        int y泡 = ( n表示ゲージ最大値 - n表示するゲージの高さ ) + (int) ( ( 0x160 - this.st白い星[ j ].ct進行.n現在の値 ) * Scale.Y );\r
-                                   int n透明度 = ( this.st白い星[ j ].ct進行.n現在の値 < 0xb0 ) ? 0 : ( (int) ( 255.0 * ( ( (double) ( this.st白い星[ j ].ct進行.n現在の値 - 0xb0 ) ) / 176.0 ) ) );\r
-                                   if ( ( n透明度 != 0 ) && ( y泡 < (int) ( 0x191 * Scale.Y ) ) )\r
-                                   {\r
-                                       Rectangle rect = new Rectangle(\r
-                                           (int) ( 0 * Scale.X ),\r
-                                           (int) ( 0x20 * Scale.Y ),\r
-                                           (int) ( 0x20 * Scale.X ),\r
-                                           (int) ( 0x20 * Scale.Y )\r
-                                       );\r
-                                       if ( this.txゲージ != null )\r
-                                       {\r
-                                           this.txゲージ.vc拡大縮小倍率 = new Vector3( this.st白い星[ j ].fScale, this.st白い星[ j ].fScale, 1f );\r
-                                           this.txゲージ.n透明度 = n透明度;\r
-                                           this.txゲージ.t2D描画(\r
-                                               CDTXMania.app.Device,\r
-                                               (int) ( x * Scale.X ),\r
-                                               (int) ( y泡 + 0.5f ),\r
-                                               rect\r
-                                           );\r
-                                       }\r
-                                   }\r
+                                       int n透明度 = ( this.st白い星[ j ].ct進行.n現在の値 < 0xb0 ) ? 0 : ( (int) ( 255.0 * ( ( (double) ( this.st白い星[ j ].ct進行.n現在の値 - 0xb0 ) ) / 176.0 ) ) );\r
+                                       if ( ( n透明度 != 0 ) && ( y泡 < (int) ( 0x191 * Scale.Y ) ) )\r
+                                       {\r
+                                               Rectangle rect = new Rectangle(\r
+                                                       (int) ( 0 * Scale.X ),\r
+                                                       (int) ( 0x20 * Scale.Y ),\r
+                                                       (int) ( 0x20 * Scale.X ),\r
+                                                       (int) ( 0x20 * Scale.Y )\r
+                                               );\r
+                                               if ( this.txゲージ != null )\r
+                                               {\r
+                                                       this.txゲージ.vc拡大縮小倍率 = new Vector3( this.st白い星[ j ].fScale, this.st白い星[ j ].fScale, 1f );\r
+                                                       this.txゲージ.n透明度 = n透明度;\r
+                                                       this.txゲージ.t2D描画(\r
+                                                               CDTXMania.app.Device,\r
+                                                               (int) ( x * Scale.X ),\r
+                                                               (int) ( y泡 + 0.5f ),\r
+                                                               rect\r
+                                                       );\r
+                                               }\r
+                                       }\r
                                }\r
                                #endregion\r
                        }\r
@@ -266,7 +272,7 @@ namespace DTXMania
                        public CCounter ct進行;\r
                }\r
 \r
-\r
+               private CTextureAf txゲージ白;\r
                private const int STAR_MAX = 0x18;\r
                private ST白い星[] st白い星 = new ST白い星[ 0x18 ];\r
                //-----------------\r
index a424897..843a4e5 100644 (file)
Binary files a/DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge.psd and b/DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge.psd differ
diff --git a/DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge_.psd b/DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge_.psd
new file mode 100644 (file)
index 0000000..9a34cf4
Binary files /dev/null and b/DTXManiaプロジェクト/作成資料/ScreenPlayDrums gauge_.psd differ
diff --git a/DTXManiaプロジェクト/作成資料/ScreenPlayDrums_gauge_white.psd b/DTXManiaプロジェクト/作成資料/ScreenPlayDrums_gauge_white.psd
new file mode 100644 (file)
index 0000000..20dcb98
Binary files /dev/null and b/DTXManiaプロジェクト/作成資料/ScreenPlayDrums_gauge_white.psd differ
diff --git a/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums gauge.png b/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums gauge.png
deleted file mode 100644 (file)
index 5ae6890..0000000
Binary files a/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums gauge.png and /dev/null differ
diff --git a/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums-gauge.png b/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums-gauge.png
new file mode 100644 (file)
index 0000000..50635fe
Binary files /dev/null and b/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums-gauge.png differ
diff --git a/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums_gauge_white.png b/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums_gauge_white.png
new file mode 100644 (file)
index 0000000..81e7fae
Binary files /dev/null and b/実行時フォルダ/System/Default/Graphics/ScreenPlayDrums_gauge_white.png differ