Click here to Skip to main content
Click here to Skip to main content
Articles » Multimedia » DirectX » Games » Downloads
 
Add your own
alternative version

Overlay using raphook.dll

, 21 Sep 2008 CPOL
A OverlayMgr based on Ray Adam's raphook.dll
osdmgr_bin.zip
bin
managed_d3d_example.exe
OverlayMgr.exe
OverlayWrapper.dll
plugins
NvidiaPlugin.dll
TimePlugin.dll
raphook.dll
osdmgr_src.zip
src
NvidiaPlugin
Properties
OverlayMgr
about.png
about.xcf
icon.ico
icon.xcf
plugins
TimePlugin
Properties
Properties
Settings.settings
Resources
PropertiesHS.png
repair.ico
Users.png
WarningHS.png
OverlayWrapper
OverlayWrapper.suo
Properties
raphook.dll
using System;
using System.Runtime.InteropServices;
using OverlayMgr;
using OverlayWrapper;

namespace NvidiaPlugin {
    /// <summary>
    /// Nvidia Plugin
    /// </summary>
    [Serializable]
    public class NvidiaPlugin : IPlugin {
        private bool active;

        #region IPlugin Members

        public string Name {
            get { return "Nvidia Support"; }
        }

        public string Description {
            get { return "Gives Access to temperature & co"; }
        }

        public bool Load() {
            return true;
        }

        public bool Unload() {
            return true;
        }

        public void ShowConfig() {
            new Settings().ShowDialog();
        }

        public bool Active {
            get { return active; }
            set { active = value; }
        }

        public void Tick() {
            //Temperature
            int gpu = 0;
            int env = 0;
            int limit = 0;

            NativeMethods.NvCplGetThermalSettings(0, ref gpu, ref env, ref limit);

            Overlay.Data.GPUTemp = gpu;
            Overlay.Data.EnvTemp = env;
        }

        #endregion

        #region Nested type: NativeMethods

        private class NativeMethods {
            [DllImport("nvcpl.dll")]
            public static extern bool NvCplGetThermalSettings(uint id, ref int gpu, ref int env, ref int limit);
        }

        #endregion
    }
}

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 Code Project Open License (CPOL)

Share

About the Author

]Metty[

Germany Germany
No Biography provided

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.141223.1 | Last Updated 21 Sep 2008
Article Copyright 2008 by ]Metty[
Everything else Copyright © CodeProject, 1999-2014
Layout: fixed | fluid