33#ifndef EDA_3D_VIEWER_H 
   34#define EDA_3D_VIEWER_H 
   40#include <wx/colourdata.h> 
   44#define KICAD_DEFAULT_3D_DRAWFRAME_STYLE    (wxDEFAULT_FRAME_STYLE | wxWANTS_CHARS) 
  111    void NewDisplay( 
bool aForceImmediateRedraw = 
false );
 
  162    bool TryBefore( wxEvent& aEvent ) 
override;
 
  180    DECLARE_EVENT_TABLE()
 
 
APP_SETTINGS_BASE is a settings class that should be derived for each standalone KiCad application.
 
Helper class to handle information needed to display 3D board.
 
Information pertinent to a Pcbnew printed circuit board.
 
A class used to derive camera objects from.
 
Implement a canvas based on a wxGLCanvas.
 
void saveOrCopyImage(const wxImage &screenshotImage, EDA_3D_VIEWER_EXPORT_FORMAT aFormat, const wxString &fullFileName)
Save image to file or copy to clipboard based on format.
 
wxWindow * GetToolCanvas() const override
Canvas access.
 
void OnSetFocus(wxFocusEvent &event)
 
void onDisableRayTracing(wxCommandEvent &aEvent)
 
void CommonSettingsChanged(int aFlags) override
Notification that common settings are updated.
 
void applySettings(EDA_3D_VIEWER_SETTINGS *aSettings)
 
PCB_BASE_FRAME * Parent() const
 
void SaveSettings(APP_SETTINGS_BASE *aCfg) override
Save common frame parameters to a configuration data file.
 
void NewDisplay(bool aForceImmediateRedraw=false)
Reload and refresh (rebuild) the 3D scene.
 
void configureCanvas(std::unique_ptr< EDA_3D_CANVAS > &canvas, EDA_3D_VIEWER_SETTINGS *cfg)
Configure canvas settings for screenshot capture.
 
bool m_disable_ray_tracing
 
wxImage captureOpenGLScreenshot(BOARD_ADAPTER &adapter, TRACK_BALL &camera, const wxSize &aSize)
Capture screenshot using OpenGL renderer.
 
bool getExportFileName(EDA_3D_VIEWER_EXPORT_FORMAT &aFormat, wxString &fullFileName)
Get export filename through file dialog.
 
void setupUIConditions() override
Setup the UI conditions for the various actions and their controls in this frame.
 
void OnActivate(wxActivateEvent &event)
 
bool TryBefore(wxEvent &aEvent) override
 
void Exit3DFrame(wxCommandEvent &event)
Called when user press the File->Exit.
 
BOARD_ADAPTER m_boardAdapter
 
void ToggleAppearanceManager()
 
std::unique_ptr< NL_3D_VIEWER_PLUGIN > m_spaceMouse
 
void RenderEngineChanged()
RenderEngineChanged - Update toolbar icon and call canvas RenderEngineChanged.
 
void Process_Special_Functions(wxCommandEvent &event)
 
wxImage captureCurrentViewScreenshot()
Capture screenshot of the current view using the configured renderer.
 
void OnCloseWindow(wxCloseEvent &event)
 
void doReCreateMenuBar() override
 
void ShowChangedLanguage() override
 
EDA_3D_VIEWER_FRAME(KIWAY *aKiway, PCB_BASE_FRAME *aParent, const wxString &aTitle, long style=KICAD_DEFAULT_3D_DRAWFRAME_STYLE)
 
wxImage captureScreenshot(const wxSize &aSize)
Capture screenshot using appropriate rendering method.
 
void setupRenderingConfig(BOARD_ADAPTER &adapter)
Setup rendering configuration for screenshot capture.
 
void ReloadRequest()
Request reloading the 3D view.
 
wxFileName m_defaultSaveScreenshotFileName
 
wxImage convertRGBAToImage(uint8_t *rgbaBuffer, const wxSize &realSize)
Convert RGBA buffer to wxImage format.
 
TRACK_BALL m_trackBallCamera
 
EDA_3D_CANVAS * GetCanvas()
 
CAMERA & GetCurrentCamera()
 
BOARD_ADAPTER & GetAdapter()
 
void LoadSettings(APP_SETTINGS_BASE *aCfg) override
Load common frame parameters from a configuration file.
 
void saveImageToFile(const wxImage &screenshotImage, EDA_3D_VIEWER_EXPORT_FORMAT aFormat, const wxString &fullFileName)
Save image to file.
 
void copyImageToClipboard(const wxImage &screenshotImage)
Copy image to system clipboard.
 
void loadCommonSettings()
Load configuration from common settings.
 
APPEARANCE_CONTROLS_3D * GetAppearanceManager()
 
void ExportImage(EDA_3D_VIEWER_EXPORT_FORMAT aFormat, const wxSize &aSize)
Export 3D viewer image to file or clipboard.
 
wxImage captureRaytracingScreenshot(BOARD_ADAPTER &adapter, TRACK_BALL &camera, const wxSize &aSize)
Capture screenshot using raytracing renderer.
 
void TakeScreenshot(EDA_3D_VIEWER_EXPORT_FORMAT aFormat)
Create a Screenshot of the current 3D view.
 
void handleIconizeEvent(wxIconizeEvent &aEvent) override
Handle a window iconize event.
 
APPEARANCE_CONTROLS_3D * m_appearancePanel
 
Manage an 8-bit channel image.
 
KIWAY_PLAYER(KIWAY *aKiway, wxWindow *aParent, FRAME_T aFrameType, const wxString &aTitle, const wxPoint &aPos, const wxSize &aSize, long aStyle, const wxString &aFrameName, const EDA_IU_SCALE &aIuScale)
 
A minimalistic software bus for communications between various DLLs/DSOs (DSOs) within the same KiCad...
 
The class that implements the public interface to the SpaceMouse plug-in.
 
Base PCB main window class for Pcbnew, Gerbview, and CvPcb footprint viewer.
 
EDA_3D_VIEWER_EXPORT_FORMAT
 
#define KICAD_DEFAULT_3D_DRAWFRAME_STYLE
 
static const wxChar * m_logTrace
Trace mask used to enable or disable the trace output of this class.
 
Declaration for a track ball camera.