Click here to Skip to main content
       

C#

 
Questionset the parent form size according to child form in mdi form PinmemberArun kumar Gautam28-Dec-12 1:12 
AnswerRe: set the parent form size according to child form in mdi form PinmemberMatt U.28-Dec-12 4:16 
AnswerRe: set the parent form size according to child form in mdi form PinmemberEddy Vluggen28-Dec-12 9:04 
QuestionSelected rows in a gridview Pinmemberrakeshs31227-Dec-12 19:26 
AnswerRe: Selected rows in a gridview Pinmembervanikanc28-Dec-12 6:48 
GeneralRe: Selected rows in a gridview Pinmemberrakeshs31228-Dec-12 18:48 
AnswerRe: Selected rows in a gridview PinmvpAbhinav S28-Dec-12 23:39 
QuestionSliding an Image on another Image PinmemberShubhanshu Pathak27-Dec-12 18:09 
Dear Group,

I am new to DirectX and I am stuck in one basic scenario. So my requirement is -
I am having C# Windows Form. Now on top of that form I have to Slide one Image on top of another Image. Both Images are passed to my this translating class.
I used the concept of Sprite after going through the online Samples. But the problem is when the Sprite is moving the background is set to the color which is provided in the Device.Clear() method. I didn't find any way by which I can overcome this. There is no way to set the background image of the Device too.

I also tried using the concept of Microsoft.DirectX.DirectDraw.Surface too. PFB the code which I tried -

// Code Snippet Begin
SurfaceDescription description = new SurfaceDescription();
 
description.SurfaceCaps.PrimarySurface = true;
description.SurfaceCaps.Flip = true;
description.SurfaceCaps.Complex = true;
description.BackBufferCount = 1;
 
m_PrimarySurface = new Surface(description, m_Device);
description.Clear();
description.SurfaceCaps.BackBuffer = true;
m_SecondarySurface = m_PrimarySurface.GetAttachedSurface(description.SurfaceCaps);
 
description.Clear();
description.SurfaceCaps.OffScreenPlain = true;
 
m_ImageSurfaceurface = new Surface("MyImage.jpg", description, m_Device);
// Code Snippet End

But here the line -

m_ImageSurfaceurface = new Surface("MyImage.jpg", description, m_Device);

is giving build error without any explanation why.

So I am in a stuck state. Please Help...

Note - I have DirectX 9.0 SDK installed.

Thanks in advance...
Shubhanshu .
QuestionSerial Port Won't Send While Receiving PinmemberC-P-User-327-Dec-12 15:13 
AnswerRe: Serial Port Won't Send While Receiving PinmvpRichard MacCutchan27-Dec-12 21:45 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-328-Dec-12 5:21 
GeneralRe: Serial Port Won't Send While Receiving PinmvpRichard MacCutchan28-Dec-12 5:45 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-328-Dec-12 5:59 
GeneralRe: Serial Port Won't Send While Receiving PinmvpRichard MacCutchan28-Dec-12 6:40 
AnswerRe: Serial Port Won't Send While Receiving PinmemberGrooverFromHolland28-Dec-12 7:04 
AnswerRe: Serial Port Won't Send While Receiving Pinmemberjschell28-Dec-12 9:53 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-331-Dec-12 10:54 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-31-Jan-13 13:35 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-31-Jan-13 13:36 
GeneralRe: Serial Port Won't Send While Receiving PinmemberGrooverFromHolland1-Jan-13 23:41 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-32-Jan-13 4:25 
GeneralRe: Serial Port Won't Send While Receiving PinmemberC-P-User-37-Jan-13 9:21 
QuestionQuestion about split PinmemberS Douglas27-Dec-12 6:32 
AnswerRe: Question about split PinmemberPIEBALDconsult27-Dec-12 7:20 
GeneralRe: Question about split PinmemberS Douglas27-Dec-12 8:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web03 | 2.8.141022.2 | Last Updated 25 Oct 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid