calling mil libraries from Java

Hello,

I am developing an application for capturing video signals from a Matrox card.

I want to display the image on a java panel and for this purpouse I need the window handler. My problem is that I don't know how to get this handler from java side and then passit to the "c" side.

I succeed using this snippet code:

MIL_ID MilApp, MilSys, MilDisp, MilDig, MilIm;

MappAllocDefault(M_SETUP, &MilApp, &MilSys, &MilDisp, &MilDig, &MilIm);

MdigGrabContinuous(MilDig, MilIm);

printf("Catchin signal...\n");

getchar();

MdigHalt(MilDig);

MappFreeDefault(MilApp, MilSys, MilDisp, MilDig, MilIm);

The problem is that here I display the image into a default window and I want to display it into a Java panel.

Thank you in advance.

ps.: Please can you also post the answer to d.delpozo@ibermatica.com

[911 byte] By [iceDani] at [2007-9-26 4:11:16]
# 1
hey
iceDani at 2007-6-29 13:16:00 > top of Java-index,Java HotSpot Virtual Machine,Specifications...
# 2
I got the answer for you, lucky you :-) http://java.sun.com/j2se/1.3/docs/guide/awt/AWT_Native_Interface.html
yilin at 2007-6-29 13:16:00 > top of Java-index,Java HotSpot Virtual Machine,Specifications...
# 3

Hy ,

I may be able to answer your question .

You may get the window handler in java side, then from the C side invoke that java method with

"CallStatic<return type of java method> Method , after you obtain a method ID with GetMethodId function.

This should work !!

PS :

Please excuse me for my poor english !

ovidiu3 at 2007-6-29 13:16:00 > top of Java-index,Java HotSpot Virtual Machine,Specifications...