I have looked at various Microsoft SDK packs (windows, directx, NET frameworks 3.5 etc).
Now, correct if I am wrong: if I would like to program DirectX or NET Frameworks with MASM
I would just have to use includelib for .lib file FROM SDK pack for API´s which need them? yes?
And that would work? no additional tweaking?
example, here is pen constructor from DirectX SDK:
Constructor Information
Stock Implementation gdiplus.dll
Header Declared in Gdipluspen.h, include gdiplus.h
Import library gdiplus.lib
Minimum availability GDI+ 1.0
Minimum operating systems Windows 98/Me, Windows XP, Windows 2000, Windows NT 4.0 SP6
Now,
if I would like to use GDI+ and use pen constructor I must include "gdiplus.lib" in masm? I don´t need Gdipluspen.h and gdiplus.h, because those are c++ files, right? Do I have to link gdiplus.dll with my program in some way?
thanx
You would need at least some of the declarations, constants, etc from the header files. You would link with the import library, and the system would load the DLL, assuming it could be found.
MASM32 SDK has many of the C header files converted for MASM programmers. In your example, you need to access GDI+, MASM32 v10 SDK has a gdiplus.inc include file ready for use:
include gdiplus.inc
includelib gdiplus.lib
If you can't find your declaration in MASM32 package, then MASM has a nice utility for doing the conversion for you, it's called H2INC.EXE (http://msdn.microsoft.com/en-us/library/aa903540(VS.71).aspx):
c:\>h2inc myheader.h /Zn /Zu
HTH,
-chris
cool ,c++ conversion utility...I thought I have to abandon assembler language...
I think for me it´s better to study c++ and then figure out how I would do it in MASM.
That way it would be easier to learn basic windows programming because most SDK examples are in c++.
thanx...lot´s of things to figure out ahead..
You can get h2incx from Japheth's site :
QuoteAbout h2incx
This tool's purpose is to convert C header files to Masm-style include files. It is much more powerful than Microsoft's h2inc tool. The main purpose is to convert the Win32 include files, but it should work with any C header files as well. It is a simple Win32 console application, but a 32bit DOS extended binary version is included as well to be used on Non-Win32 platforms.
http://japheth.de/h2incX.html