#include "Volumizer.h"
Go to the source code of this file.
Defines | |
#define | TOOL_HEIGHT 36 |
Functions | |
ATOM | RegisterSwatchClass (HINSTANCE hInstance) |
histogram handle this editor handles | |
LRESULT CALLBACK | SwatchProc (HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) |
BOOL CALLBACK | MaterialEditorProc (HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) |
void | EditTransferHandle (histo_handle *handle, HWND hWndParent) |
Variables | |
HWND | matDlg |
histo_handle * | cur_handle |
the material dialog handle |
#define TOOL_HEIGHT 36 |
void EditTransferHandle | ( | histo_handle * | handle, | |
HWND | hWndParent | |||
) |
Open a material editor dialog.
grab the handle
pop open the dialog box (modal)
after we're done, repaint the histogram
and rerender the raycast
hWndParent | handle this dialog should edit parent (usually the histogram window) |
Definition at line 184 of file MaterialEditor.cpp.
References cur_handle, DrawHistogram(), hInst, IDD_MATERIAL, MaterialEditorProc(), RayRender(), and wnd_histogram.
Referenced by HistogramProc().
BOOL CALLBACK MaterialEditorProc | ( | HWND | hDlg, | |
UINT | message, | |||
WPARAM | wParam, | |||
LPARAM | lParam | |||
) |
Dialog Procedure for the material editor window.
grab the initial values from the cur_handle current handle
HSCROLLs are fired from the two track bars (alpha and gradient)
finish up
Definition at line 126 of file MaterialEditor.cpp.
References cur_handle, DrawHistogram(), IDC_ALPHA, IDC_EXPONENT, IDC_GRADIENT, matDlg, and wnd_histogram.
Referenced by EditTransferHandle().
ATOM RegisterSwatchClass | ( | HINSTANCE | hInstance | ) |
histogram handle this editor handles
Register the window class for the small color swatches
Definition at line 15 of file MaterialEditor.cpp.
References SwatchProc().
Referenced by _tWinMain().
LRESULT CALLBACK SwatchProc | ( | HWND | hWnd, | |
UINT | message, | |||
WPARAM | wParam, | |||
LPARAM | lParam | |||
) |
Window procedure for the swatches. Doesn't do a lot except painting the background with the correct color, and opening a color chooser dialog when it's clicked.
pick a color!
paint the background with the correct color
Definition at line 40 of file MaterialEditor.cpp.
References cur_handle, IDC_AMBIENT, IDC_DIFFUSE, IDC_SPECULAR, and matDlg.
Referenced by RegisterSwatchClass().
histo_handle* cur_handle |
the material dialog handle
Definition at line 10 of file MaterialEditor.cpp.
Referenced by EditTransferHandle(), MaterialEditorProc(), and SwatchProc().
HWND matDlg |
Implements the material editor dialog box
Definition at line 9 of file MaterialEditor.cpp.
Referenced by MaterialEditorProc(), and SwatchProc().