locked
how to do copy imagesource? RRS feed

  • Question

  • My english is poor.  Sorry for the inconvenience.

    I use Direct+XAML , so I choose SurfaceImageSource method.

    I want to copy  imagesource to past my view.

    My code(look bottom) purpose make four different image.

    My code result is same photo. It isn't my want result.

    Code like this:

     gDirectXImageDraw is SurfaceImageSource.

     gDirectXImageDraw(...); //Do something 
     gDirectXImageDraw->UpdateView();
     brush_1->ImageSource = gDirectXImageDraw;
     this->RearView->Fill = brush_1;
     
     gDirectXImageDraw(...); //Do something 2
     gDirectXImageDraw->UpdateView();
     brush_2->ImageSource = gDirectXImageDraw;
     this->FrontView->Fill = brush_2;

     gDirectXImageDraw(...); //Do something 3
     gDirectXImageDraw->UpdateView();
     brush_3->ImageSource = gDirectXImageDraw;
     this->LeftView->Fill = brush_3;

     gDirectXImageDraw(...); //Do something 4
     gDirectXImageDraw->UpdateView();
     brush_4->ImageSource = gDirectXImageDraw;
     this->RightView->Fill = brush_4;

    Tuesday, September 10, 2013 1:40 AM

Answers

  • Hi KC-Steven,

    Please just have a look at this sample:

    http://code.msdn.microsoft.com/windowsapps/XAML-SurfaceImageSource-58f7e4d5/view/Discussions

    I hope it is helpful!

    Regards!


    <font color="0099FF">&lt;THE CONTENT IS PROVIDED &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED&gt;</font><br/> Thanks<br/> MSDN Community Support<br/> <br/> Please remember to &quot;Mark as Answer&quot; the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    • Marked as answer by KC-Steven Wednesday, July 30, 2014 9:18 AM
    Wednesday, September 11, 2013 12:08 PM
    Moderator

All replies

  • Hi KC-Steven,

    Please just have a look at this sample:

    http://code.msdn.microsoft.com/windowsapps/XAML-SurfaceImageSource-58f7e4d5/view/Discussions

    I hope it is helpful!

    Regards!


    <font color="0099FF">&lt;THE CONTENT IS PROVIDED &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED&gt;</font><br/> Thanks<br/> MSDN Community Support<br/> <br/> Please remember to &quot;Mark as Answer&quot; the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    • Marked as answer by KC-Steven Wednesday, July 30, 2014 9:18 AM
    Wednesday, September 11, 2013 12:08 PM
    Moderator
  • I know this example, and work well.

    But, Now I want to do a screen past four imagesource in four image or rectangle.

    So, I set conditions 1,get imagesource for gDirectXImageDraw(); //Set View position / look at /

    then, I set conditions 2,get imagesource for gDirectXImageDraw(); //Set View position 2  / look at 2/

    ...

    Finally, Four View is same image, and Image is Final Setting condition. 

    View like this(four view in a view):

      {view

               [ View 1 ]         [ View 2  ]

               [ View 3 ]         [ View 4  ]                   

                                                        }

    Thursday, September 12, 2013 1:39 AM