Example #1
0
        /// <summary>
        /// すべてのLGN細胞とカメラ画像を描画
        /// </summary>
        /// <param name="RetinalCell"></param>
        private void LGN_Draw(byte[] RetinalCell)
        {
            //LGN細胞への写像を計算するインスタンスを受容野の数だけ作成
            ImgDisplay = new ImgDisplayWindow();
            LGN_RF0    = new LGN_View(0);
            LGN_RF1    = new LGN_View(1);
            LGN_RF2    = new LGN_View(2);
            LGN_RF3    = new LGN_View(3);
            LGN_RF4    = new LGN_View(4);
            LGN_RF5    = new LGN_View(5);
            LGN_RF6    = new LGN_View(6);
            LGN_Projector LGN_Projector = new LGN_Projector();

            ImgDisplay.Show();
            LGN_RF0.Show();
            LGN_RF1.Show();
            LGN_RF2.Show();
            LGN_RF3.Show();
            LGN_RF4.Show();
            LGN_RF5.Show();
            LGN_RF6.Show();
            //受容野ごとにLGNへの射影結果を描画
            LGN_Projector.Dummy(0, RetinalCell, Ximg_RF0, Yimg_RF0, Xlgn_RF0, Ylgn_RF0, LGN_RF0);
            LGN_Projector.Dummy(1, RetinalCell, Ximg_RF1, Yimg_RF1, Xlgn_RF1, Ylgn_RF1, LGN_RF1);
            LGN_Projector.Dummy(2, RetinalCell, Ximg_RF2, Yimg_RF2, Xlgn_RF2, Ylgn_RF2, LGN_RF2);
            LGN_Projector.Dummy(3, RetinalCell, Ximg_RF3, Yimg_RF3, Xlgn_RF3, Ylgn_RF3, LGN_RF3);
            LGN_Projector.Dummy(4, RetinalCell, Ximg_RF4, Yimg_RF4, Xlgn_RF4, Ylgn_RF4, LGN_RF4);
            LGN_Projector.Dummy(5, RetinalCell, Ximg_RF5, Yimg_RF5, Xlgn_RF5, Ylgn_RF5, LGN_RF5);
            LGN_Projector.Dummy(6, RetinalCell, Ximg_RF6, Yimg_RF6, Xlgn_RF6, Ylgn_RF6, LGN_RF6);
            ImgDisplay.DrawMask(improc.ToImage(RetinalCell, 1280, 960), mask);
        }
Example #2
0
 /// <summary>
 /// 非同期にBMPデータを生成
 /// </summary>
 /// <param name="RetinalCell"></param>
 private async void AsyncMakeBMP(byte[] RetinalCell)
 {
     LGN_Projector LGN_Projector = new LGN_Projector();
     await Task.Run(() =>
     {
         bmp_RF0      = LGN_Projector.Retina2LGN(0, Ximg_RF0, Yimg_RF0, Xlgn_RF0, Ylgn_RF0, RetinalCell);
         bmp_RF1      = LGN_Projector.Retina2LGN(1, Ximg_RF1, Yimg_RF1, Xlgn_RF1, Ylgn_RF1, RetinalCell);
         bmp_RF2      = LGN_Projector.Retina2LGN(2, Ximg_RF2, Yimg_RF2, Xlgn_RF2, Ylgn_RF2, RetinalCell);
         bmp_RF3      = LGN_Projector.Retina2LGN(3, Ximg_RF3, Yimg_RF3, Xlgn_RF3, Ylgn_RF3, RetinalCell);
         bmp_RF4      = LGN_Projector.Retina2LGN(4, Ximg_RF4, Yimg_RF4, Xlgn_RF4, Ylgn_RF4, RetinalCell);
         bmp_RF5      = LGN_Projector.Retina2LGN(5, Ximg_RF5, Yimg_RF5, Xlgn_RF5, Ylgn_RF5, RetinalCell);
         bmp_RF6      = LGN_Projector.Retina2LGN(6, Ximg_RF6, Yimg_RF6, Xlgn_RF6, Ylgn_RF6, RetinalCell);
         DrawFlag_IMG = true;
     });
 }