OSDN Git Service

#47668 DTXC内で扱う分解能を下辺にするための布石。
[dtxmania/dtxmania.git] / DTXCreator / コード / 05.譜面 / C譜面管理.cs
index 76e9f30..f32eb79 100644 (file)
@@ -102,7 +102,7 @@ namespace DTXCreator.譜面
                public int nY座標dotが位置するgridを返す_最高解像度( int nY )
                {
                        int num = this._Form.pictureBox譜面パネル.ClientSize.Height - nY;
-                       return ( ( num / C小節.n1グリッドの高さdot ) + this.n現在の譜面表示下辺の譜面先頭からの位置grid );
+                       return (int)( ( num / C小節.n1グリッドの高さdot ) + this.n現在の譜面表示下辺の譜面先頭からの位置grid );
                }
                public int nレーンの左端X座標dotを返す( int nレーン番号0to )
                {
@@ -159,7 +159,7 @@ namespace DTXCreator.譜面
                public int n譜面先頭からの位置gridから描画領域内のY座標dotを返す( int n譜面先頭からの位置grid, Size sz描画領域dot )
                {
                        int num = n譜面先頭からの位置grid - this.n現在の譜面表示下辺の譜面先頭からの位置grid;
-                       return ( sz描画領域dot.Height - ( num * C小節.n1グリッドの高さdot ) );
+                       return (int)( sz描画領域dot.Height - ( num * C小節.n1グリッドの高さdot ) );
                }
                public int n譜面先頭からみた小節先頭の位置gridを返す( int n小節番号0to3599 )
                {
@@ -205,7 +205,7 @@ namespace DTXCreator.譜面
                                foreach( Cチップ cチップ in c小節.listチップ )
                                {
                                        int num4 = num3 + cチップ.n位置grid;
-                                       int num5 = C小節.n位置変換dot2grid( Cチップ.nチップの高さdot );
+                                       int num5 = C小節.n位置変換dot2grid( cチップの高さ.nチップの高さdot );
                                        if( ( ( cチップ.nレーン番号0to == num ) && ( num4 <= num2 ) ) && ( num2 <= ( num4 + num5 ) ) )
                                        {
                                                return cチップ;
@@ -648,7 +648,7 @@ namespace DTXCreator.譜面
                        this.strfmtレーン割付チップ番号文字フォーマット.Alignment = StringAlignment.Near;
                        int h = 0;
                        int num2 = 0;
-                       int num3 = this.n現在の譜面表示下辺の譜面先頭からの位置grid * C小節.n1グリッドの高さdot;
+                       int num3 = (int)(this.n現在の譜面表示下辺の譜面先頭からの位置grid * C小節.n1グリッドの高さdot);
                        int num4 = num3 + rc可視領域dot.Height;
                        int maxBar = this.n現在の最大の小節番号を返す();
                        int bar = 0;
@@ -779,6 +779,7 @@ namespace DTXCreator.譜面
                private StringFormat strfmtレーン割付チップ番号文字フォーマット = new StringFormat();
                private StringFormat strfmtレーン名文字フォーマット = new StringFormat();
                private StringFormat strfmt小節番号文字フォーマット = new StringFormat();
+               private Cチップの高さ cチップの高さ = new Cチップの高さ();
 
                private void t初期化_listレーンの生成()
                {
@@ -916,7 +917,7 @@ namespace DTXCreator.譜面
                                int num = cs.n小節長倍率を考慮した現在の小節の高さgrid;
                                for( int i = 0; i < num; i += this.n現在のガイド幅grid )
                                {
-                                       int num3 = rc小節のPicBox内描画領域.Bottom - ( i * C小節.n1グリッドの高さdot );
+                                       int num3 = (int)(rc小節のPicBox内描画領域.Bottom - ( i * C小節.n1グリッドの高さdot ));
                                        g.DrawLine( this.penガイド線ペン, rc小節のPicBox内描画領域.X, num3, rc小節のPicBox内描画領域.Right, num3 );
                                }
                        }
@@ -938,9 +939,9 @@ namespace DTXCreator.譜面
                                        continue;
                                }
                                rectangle.X = cレーン.n位置Xdot;
-                               rectangle.Y = ( rc小節のPicBox内描画領域.Bottom - ( num * C小節.n1グリッドの高さdot ) ) - Cチップ.nチップの高さdot;
+                               rectangle.Y = (int)(( rc小節のPicBox内描画領域.Bottom - ( num * C小節.n1グリッドの高さdot ) ) - cチップの高さ.nチップの高さdot);
                                rectangle.Width = cレーン.n幅dot;
-                               rectangle.Height = Cチップ.nチップの高さdot;
+                               rectangle.Height = cチップの高さ.nチップの高さdot;
                                if( !cチップ.b裏 )
                                {
                                        switch( cレーン.eレーン種別 )
@@ -1016,7 +1017,7 @@ namespace DTXCreator.譜面
                        int num = cs.n小節長倍率を考慮した現在の小節の高さgrid;
                        for( int i = 0; i < num; i += C小節.n基準の高さgrid / 4 )
                        {
-                               int num3 = rc小節のPicBox内描画領域.Bottom - ( i * C小節.n1グリッドの高さdot );
+                               int num3 = (int)(rc小節のPicBox内描画領域.Bottom - ( i * C小節.n1グリッドの高さdot ));
                                g.DrawLine( this.pen拍線ペン, rc小節のPicBox内描画領域.X, num3, rc小節のPicBox内描画領域.Right, num3 );
                        }
                }