Click here to Skip to main content
15,896,912 members
Articles / Desktop Programming / MFC

Effecto Player

Rate me:
Please Sign up or sign in to vote.
4.78/5 (39 votes)
23 Sep 20035 min read 164K   14.8K   97  
Media audio player with 3D and 2D effects and skinning.
//-----------------------------------------------------------------------------
// File: DIUtil.h
//
// Desc: DirectInput support using action mapping
//
// Copyright (C) 1995-2000 Microsoft Corporation. All Rights Reserved.
//-----------------------------------------------------------------------------
#ifndef DIUTIL_H
#define DIUTIL_H
#include <dinput.h>




//-----------------------------------------------------------------------------
// Name: class CInputDeviceManager
// Desc: Input device manager using DX8 action mapping
//-----------------------------------------------------------------------------
class CInputDeviceManager
{
    HWND                 m_hWnd;
    TCHAR*               m_strUserName;

    LPDIRECTINPUT8       m_pDI;
    LPDIRECTINPUTDEVICE8 m_pdidDevices[20];
    DWORD                m_dwNumDevices;
    DIACTIONFORMAT       m_diaf;

public:
    // Device control
    HRESULT AddDevice( const DIDEVICEINSTANCE* pdidi, LPDIRECTINPUTDEVICE8 pdidDevice );
    HRESULT GetDevices( LPDIRECTINPUTDEVICE8** ppDevices, DWORD* pdwNumDevices );
    HRESULT ConfigureDevices( HWND hWnd, IUnknown* pSurface, VOID* pCallback, DWORD dwFlags );
    VOID UnacquireDevices();

    // Construction
    HRESULT SetActionFormat( DIACTIONFORMAT& diaf, BOOL bReenumerate );
    HRESULT Create( HWND hWnd, TCHAR* strUserName, DIACTIONFORMAT& diaf );

    CInputDeviceManager();
    ~CInputDeviceManager();
};

#endif


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 has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Web Developer
Egypt Egypt
My name is Ahmed Ismaiel Zakaria
i'm programming c++ & visual c++ (MFC )& Visual basic and recently COM,ATL
Student in Faculty of computer and information science in Egypt

Comments and Discussions