28d668fff7
Also, change "Parameters" button to "Parameters..." to indicate it opens a dialog box. Adjust the spacing and remove the message about custom shader files.
34 lines
822 B
C++
34 lines
822 B
C++
#pragma once
|
|
#include "windows.h"
|
|
#include "../shaders/glsl.h"
|
|
|
|
typedef void(*APPLYCALLBACK) ();
|
|
|
|
class CShaderParamDlg
|
|
{
|
|
private:
|
|
static INT_PTR CALLBACK DlgShaderParams(HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam);
|
|
static INT_PTR CALLBACK WndProcContainerStatic(HWND hStatic, UINT msg, WPARAM wParam, LPARAM lParam);
|
|
void createContent(HWND hDlg);
|
|
void get_changed_parameters(HWND hDlg);
|
|
void handle_up_down(HWND hStatic, int id, int change);
|
|
void save_custom_shader();
|
|
void apply_changes(HWND hDlg);
|
|
|
|
GLSLShader &shader;
|
|
HFONT hFont;
|
|
unsigned int avgCharWidth;
|
|
unsigned int avgCharHeight;
|
|
int scrollpos;
|
|
std::vector<GLSLParam> saved_parameters;
|
|
|
|
WNDPROC oldStaticProc;
|
|
|
|
public:
|
|
CShaderParamDlg(GLSLShader &shade);
|
|
virtual ~CShaderParamDlg();
|
|
|
|
bool show();
|
|
};
|
|
|