CPlasmaRoutine.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. // PlasmaRoutine.h: interface for the CPlasmaRoutine class.
  2. //
  3. //////////////////////////////////////////////////////////////////////
  4. #if !defined(AFX_PLASMAROUTINE_H__29FFEFB6_A053_483E_8CB6_676A1B6F6DAC__INCLUDED_)
  5. #define AFX_PLASMAROUTINE_H__29FFEFB6_A053_483E_8CB6_676A1B6F6DAC__INCLUDED_
  6. #if _MSC_VER > 1000
  7. #pragma once
  8. #endif // _MSC_VER > 1000
  9. #include <Windows.h>
  10. class CPlasmaRoutine
  11. {
  12. public:
  13. CPlasmaRoutine();
  14. virtual ~CPlasmaRoutine();
  15. // Methods
  16. void SetDefaultValues(VARIANT* pExtParms);
  17. void InitializePlasma(VARIANT* pExtParms);
  18. void Create(int iWidth,int iHeight);
  19. void Render(DWORD* pBits,
  20. int iwidth,
  21. int iheight,
  22. int iLineLength);
  23. void SetRGB(int iIndex,int R,int G,int B);
  24. void InitCostBLTable();
  25. void InitPallette();
  26. void CalcPlasma();
  27. void CreateGradient(COLORREF clrStart,COLORREF clrEnd,long lSteps,COLORREF* pBuffer);
  28. // Props
  29. int m_iWidth;
  30. int m_iHeight;
  31. int m_iAlpha;
  32. BYTE* m_pPlasmaBits;
  33. DWORD m_pPalletteBuffer[256];
  34. int m_icostbl[256];
  35. COLORREF m_PlasmaColors[16];// Yep 16 colors needed to generate our pallete...
  36. unsigned char m_a1,m_a2,m_a3,m_a4,m_b1,m_b2,m_b3,m_b4;
  37. int m_iModifier1;
  38. int m_iModifier2;
  39. int m_iModifier3;
  40. int m_iModifier4;
  41. int m_iXModifier1;
  42. int m_iXModifier2;
  43. int m_iYModifier1;
  44. int m_iYModifier2;
  45. };
  46. #endif // !defined(AFX_PLASMAROUTINE_H__29FFEFB6_A053_483E_8CB6_676A1B6F6DAC__INCLUDED_)