Click here to Skip to main content
11,635,656 members (79,092 online)
Click here to Skip to main content
Articles » Multimedia » OpenGL » General » Downloads
Add your own
alternative version

3D Graph ActiveX Control

, 2 Aug 2003 MIT 517.3K 41.5K 271
An ATL/STL ActiveX control based on OpenGL library for 3D data visualization
ntgraph3d_bin.zip
NTGraph3D.dll
ntgraph3d_demo.zip
NTGraph3D_demo
Demo3D
Demo.aps
Demo.clw
Demo.dsp
Demo.dsw
Demo.ncb
Demo.opt
Demo.plg
res
Demo.ico
Demo3D.hta
Torus
res
Torus.ico
Torus.aps
Torus.clw
Torus.dsp
Torus.dsw
Torus.ncb
Torus.opt
Torus.plg
ntgraph3d_src.zip
NTGraph3D_src
graphctl.bmp
GraphCtl.rgs
NTGraph3D.aps
NTGraph3D.def
NTGraph3D.dsp
NTGraph3D.dsw
NTGraph3D.ncb
NTGraph3D.opt
NTGraph3D.plg
NTGraph3D.tlb
NTGraph3Dps.def
NTGraph3Dps.mk
ReleaseMinSize
Test.dsm
ntgraph_bin.zip
NTGraph3D.dll
// NTGraph3D.cpp : Implementation of DLL Exports.


// Note: Proxy/Stub Information
//      To build a separate proxy/stub DLL, 
//      run nmake -f NTGraph3Dps.mk in the project directory.

#include "stdafx.h"
#include "resource.h"
#include <initguid.h>
#include "NTGraph3D.h"

#include "NTGraph3D_i.c"
#include "GraphCtl.h"


CComModule _Module;

BEGIN_OBJECT_MAP(ObjectMap)
OBJECT_ENTRY(CLSID_NTGraph3D, CGraphCtl)
END_OBJECT_MAP()

/////////////////////////////////////////////////////////////////////////////
// DLL Entry Point

extern "C"
BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID /*lpReserved*/)
{
    if (dwReason == DLL_PROCESS_ATTACH)
    {
        _Module.Init(ObjectMap, hInstance, &LIBID_NTGRAPH3DLib);
        DisableThreadLibraryCalls(hInstance);
    }
    else if (dwReason == DLL_PROCESS_DETACH)
        _Module.Term();
    return TRUE;    // ok
}

/////////////////////////////////////////////////////////////////////////////
// Used to determine whether the DLL can be unloaded by OLE

STDAPI DllCanUnloadNow(void)
{
    return (_Module.GetLockCount()==0) ? S_OK : S_FALSE;
}

/////////////////////////////////////////////////////////////////////////////
// Returns a class factory to create an object of the requested type

STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv)
{
    return _Module.GetClassObject(rclsid, riid, ppv);
}

/////////////////////////////////////////////////////////////////////////////
// DllRegisterServer - Adds entries to the system registry

STDAPI DllRegisterServer(void)
{
    // registers object, typelib and all interfaces in typelib
    return _Module.RegisterServer(TRUE);
}

/////////////////////////////////////////////////////////////////////////////
// DllUnregisterServer - Removes entries from the system registry

STDAPI DllUnregisterServer(void)
{
    return _Module.UnregisterServer(TRUE);
}


By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The MIT License

Share

About the Author

Nikolai Teofilov
Researcher
Germany Germany
No Biography provided

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.150728.1 | Last Updated 3 Aug 2003
Article Copyright 2003 by Nikolai Teofilov
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid