Click here to Skip to main content
16,007,885 members
Home / Discussions / C#
   

C#

 
GeneralRe: Converting short into byte[] Pin
Robert Rohde5-Feb-05 4:06
Robert Rohde5-Feb-05 4:06 
GeneralThe using statement Pin
paululvinius5-Feb-05 1:06
paululvinius5-Feb-05 1:06 
GeneralRe: The using statement Pin
Robert Rohde5-Feb-05 1:17
Robert Rohde5-Feb-05 1:17 
GeneralRunning Without a form GUI Pin
Amir Jalaly5-Feb-05 0:03
Amir Jalaly5-Feb-05 0:03 
GeneralRe: Running Without a form GUI Pin
Gary Thom5-Feb-05 1:18
Gary Thom5-Feb-05 1:18 
Generalcommunication between a c# application and C++ com Pin
yaya1014-Feb-05 21:45
yaya1014-Feb-05 21:45 
GeneralRe: communication between a c# application and C++ com Pin
Heath Stewart5-Feb-05 4:52
protectorHeath Stewart5-Feb-05 4:52 
GeneralRe: communication between a c# application and C++ com Pin
yaya1017-Feb-05 7:24
yaya1017-Feb-05 7:24 
About the sendmessage() explenation, I can use that function in my filter but I want the function to respond to data I send from the C# application to the filter, I dont know how to recieve that information in my C++ filter so I tried to write another native com which will be the mediator, where I send that com the pointer to the IUnknown of the filter that I retrieve in my encoder application using GetTransformPlugin function of the IWMEncTransform object, when I try using that I get the error:
"Object reference not set to an instance of an object".
I also tried a different way inorder to avoid using another com:
Trans is my IWMEncTransform object, and I use

IntPtr s1 = Marshal.GetIUnknownForObject(Trans.GetTransformPlugin());

To retrieve it's IUnknown interface.

Now I'd like to pass that IUnknown as an argument to Queryinterface function:

IntPtr ptr;

Marshal.QueryInterface(s1, ref guid, out ptr);

The question is what's my guid?

I tried to obtain my filter guid from its implementation code (C++), where it says:


// {bc4ed075-019c-4ba1-b69c-4ddd80e562a8}

DEFINE_GUID(IID_IMycamfilterapp,

0xbc4ed075, 0x19c, 0x4ba1, 0xb6, 0x9c, 0x4d, 0xdd, 0x80, 0xe5, 0x62, 0xa8);

Therefore I wrote:


System.Guid guid = new Guid(0xbc4ed075, 0x19c, 0x4ba1, 0xb6, 0x9c, 0x4d, 0xdd, 0x80, 0xe5, 0x62, 0xa8);

Marshal.QueryInterface(s1, ref guid, out ptr);


The code has no warnings/errors, but 'ptr' gets the value '0', which is obviously wrong.

Do you have any suggestion to get it work?

Do you think I should use a different approach in order to obtain my transform filter interface?

All I'm looking for is a simple way to send some information to my filter while it's running.


GeneralOdd SSL Public Key Pin
bigals4-Feb-05 18:25
bigals4-Feb-05 18:25 
GeneralStop and Start MSDOS C# App Pin
StephenMcAllister4-Feb-05 18:17
StephenMcAllister4-Feb-05 18:17 
GeneralRe: Stop and Start MSDOS C# App Pin
Heath Stewart5-Feb-05 4:44
protectorHeath Stewart5-Feb-05 4:44 
GeneralAccess Database Pin
Cappuccino_David4-Feb-05 16:51
Cappuccino_David4-Feb-05 16:51 
GeneralRe: Access Database Pin
Yulianto.4-Feb-05 17:16
Yulianto.4-Feb-05 17:16 
GeneralRe: Access Database Pin
Luis Alonso Ramos4-Feb-05 19:23
Luis Alonso Ramos4-Feb-05 19:23 
GeneralRe: Access Database Pin
Cappuccino_David5-Feb-05 8:23
Cappuccino_David5-Feb-05 8:23 
GeneralRe: Access Database Pin
Luis Alonso Ramos5-Feb-05 8:30
Luis Alonso Ramos5-Feb-05 8:30 
GeneralonMaximize() or onResize() questions... Pin
new_phoenix4-Feb-05 16:46
new_phoenix4-Feb-05 16:46 
GeneralRe: onMaximize() or onResize() questions... Pin
Heath Stewart5-Feb-05 3:39
protectorHeath Stewart5-Feb-05 3:39 
GeneralRe: onMaximize() or onResize() questions... Pin
new_phoenix5-Feb-05 8:20
new_phoenix5-Feb-05 8:20 
GeneralRe: onMaximize() or onResize() questions... Pin
Heath Stewart6-Feb-05 5:35
protectorHeath Stewart6-Feb-05 5:35 
GeneralRe: onMaximize() or onResize() questions... Pin
new_phoenix6-Feb-05 12:12
new_phoenix6-Feb-05 12:12 
GeneralRe: onMaximize() or onResize() questions... Pin
Heath Stewart7-Feb-05 6:36
protectorHeath Stewart7-Feb-05 6:36 
GeneralBest Practices - Serializing Dialog Data Pin
Newbie_T4-Feb-05 16:37
Newbie_T4-Feb-05 16:37 
GeneralRe: Best Practices - Serializing Dialog Data Pin
Heath Stewart5-Feb-05 3:30
protectorHeath Stewart5-Feb-05 3:30 
QuestionHow to modify the tnsnames.ora file by method? Pin
Colinyin4-Feb-05 13:06
Colinyin4-Feb-05 13:06 

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

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