2012-12-15 08:52:02 +00:00
|
|
|
/*
|
|
|
|
* This program source code file is part of KiCad, a free EDA CAD application.
|
|
|
|
*
|
2015-03-17 07:39:15 +00:00
|
|
|
* Copyright (C) 2015 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
2012-12-15 08:52:02 +00:00
|
|
|
* Copyright (C) 2012 Wayne Stambaugh <stambaughw@verizon.net>
|
2015-03-17 07:39:15 +00:00
|
|
|
* Copyright (C) 1992-2015 KiCad Developers, see AUTHORS.txt for contributors.
|
2012-12-15 08:52:02 +00:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, you may find one here:
|
|
|
|
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
|
|
|
* or you may search the http://www.gnu.org website for the version 2 license,
|
|
|
|
* or you may write to the Free Software Foundation, Inc.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @file 3d_viewer.h
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _3D_CANVAS_H_
|
|
|
|
#define _3D_CANVAS_H_
|
|
|
|
|
|
|
|
#include <wx/glcanvas.h>
|
|
|
|
|
|
|
|
#ifdef __WXMAC__
|
|
|
|
# ifdef __DARWIN__
|
|
|
|
# include <OpenGL/glu.h>
|
|
|
|
# else
|
|
|
|
# include <glu.h>
|
|
|
|
# endif
|
|
|
|
#else
|
|
|
|
# include <GL/glu.h>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <3d_struct.h>
|
2015-03-28 11:33:56 +00:00
|
|
|
#include <modelparsers.h>
|
2015-03-13 19:27:25 +00:00
|
|
|
#include <class_module.h>
|
2015-03-28 11:33:56 +00:00
|
|
|
#include <CBBox.h>
|
2015-03-16 17:39:35 +00:00
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
class BOARD_DESIGN_SETTINGS;
|
|
|
|
class EDA_3D_FRAME;
|
2015-07-27 19:45:57 +00:00
|
|
|
class SHAPE_POLY_SET;
|
2015-04-14 15:12:35 +00:00
|
|
|
class REPORTER;
|
2014-07-30 09:01:25 +00:00
|
|
|
|
2014-04-25 06:00:04 +00:00
|
|
|
class VIA;
|
2014-01-30 08:18:47 +00:00
|
|
|
class D_PAD;
|
2012-12-15 08:52:02 +00:00
|
|
|
|
2014-03-08 19:04:23 +00:00
|
|
|
// We are using GL lists to store layers and other items
|
|
|
|
// to draw or not
|
|
|
|
// GL_LIST_ID are the GL lists indexes in m_glLists
|
|
|
|
enum GL_LIST_ID
|
|
|
|
{
|
|
|
|
GL_ID_BEGIN = 0,
|
|
|
|
GL_ID_AXIS = GL_ID_BEGIN, // list id for 3D axis
|
|
|
|
GL_ID_GRID, // list id for 3D grid
|
|
|
|
GL_ID_BOARD, // List id for copper layers
|
|
|
|
GL_ID_TECH_LAYERS, // List id for non copper layers (masks...)
|
|
|
|
GL_ID_AUX_LAYERS, // List id for user layers (draw, eco, comment)
|
2014-07-30 09:01:25 +00:00
|
|
|
GL_ID_3DSHAPES_SOLID_FRONT, // List id for 3D shapes, non transparent entities
|
|
|
|
GL_ID_3DSHAPES_TRANSP_FRONT,// List id for 3D shapes, transparent entities
|
2014-08-21 11:59:57 +00:00
|
|
|
GL_ID_3DSHAPES_SOLID_BACK, // List id for 3D shapes, non transparent entities
|
|
|
|
GL_ID_3DSHAPES_TRANSP_BACK, // List id for 3D shapes, transparent entities
|
2014-07-30 09:01:25 +00:00
|
|
|
GL_ID_SHADOW_FRONT,
|
|
|
|
GL_ID_SHADOW_BACK,
|
|
|
|
GL_ID_SHADOW_BOARD,
|
2014-08-21 11:59:57 +00:00
|
|
|
GL_ID_BODY, // Body only list
|
2014-03-08 19:04:23 +00:00
|
|
|
GL_ID_END
|
|
|
|
};
|
2012-12-15 08:52:02 +00:00
|
|
|
|
|
|
|
class EDA_3D_CANVAS : public wxGLCanvas
|
|
|
|
{
|
|
|
|
private:
|
|
|
|
bool m_init;
|
2015-04-14 15:12:35 +00:00
|
|
|
bool m_reportWarnings; ///< true to report all warnings when building the 3D scene
|
|
|
|
///< false to report errors only
|
2015-03-28 11:33:56 +00:00
|
|
|
GLuint m_glLists[GL_ID_END]; ///< GL lists
|
2012-12-15 08:52:02 +00:00
|
|
|
wxGLContext* m_glRC;
|
2015-03-28 11:33:56 +00:00
|
|
|
wxRealPoint m_draw3dOffset; ///< offset to draw the 3D mesh.
|
|
|
|
double m_ZBottom; ///< position of the back layer
|
|
|
|
double m_ZTop; ///< position of the front layer
|
2012-12-15 08:52:02 +00:00
|
|
|
|
2015-03-28 11:33:56 +00:00
|
|
|
GLuint m_text_pcb; ///< an index to the texture generated for pcb texts
|
|
|
|
GLuint m_text_silk; ///< an index to the texture generated for silk layers
|
2014-07-30 09:01:25 +00:00
|
|
|
|
2015-02-26 10:33:15 +00:00
|
|
|
// Index to the textures generated for shadows
|
2014-07-30 09:01:25 +00:00
|
|
|
bool m_shadow_init;
|
|
|
|
GLuint m_text_fake_shadow_front;
|
|
|
|
GLuint m_text_fake_shadow_back;
|
|
|
|
GLuint m_text_fake_shadow_board;
|
|
|
|
|
2015-03-28 11:33:56 +00:00
|
|
|
CBBOX m_boardAABBox; ///< Axis Align Bounding Box of the board
|
|
|
|
CBBOX m_fastAABBox; ///< Axis Align Bounding Box that contain the other bounding boxes
|
|
|
|
CBBOX m_fastAABBox_Shadow; ///< A bit scalled version of the m_fastAABBox
|
|
|
|
|
|
|
|
S3D_VERTEX m_lightPos;
|
|
|
|
|
|
|
|
/// Stores the list of parsers for each new file name (dont repeat files already loaded)
|
|
|
|
std::vector<S3D_MODEL_PARSER *> m_model_parsers_list;
|
|
|
|
std::vector<wxString> m_model_filename_list;
|
|
|
|
|
|
|
|
void create_and_render_shadow_buffer( GLuint *aDst_gl_texture,
|
2014-07-30 15:39:55 +00:00
|
|
|
GLuint aTexture_size, bool aDraw_body, int aBlurPasses );
|
|
|
|
|
2015-03-28 11:33:56 +00:00
|
|
|
void calcBBox();
|
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
public:
|
|
|
|
EDA_3D_CANVAS( EDA_3D_FRAME* parent, int* attribList = 0 );
|
|
|
|
~EDA_3D_CANVAS();
|
|
|
|
|
2014-05-04 17:08:36 +00:00
|
|
|
EDA_3D_FRAME* Parent() const { return static_cast<EDA_3D_FRAME*>( GetParent() ); }
|
2012-12-15 08:52:02 +00:00
|
|
|
|
2014-03-08 19:04:23 +00:00
|
|
|
BOARD* GetBoard() { return Parent()->GetBoard(); }
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Function ClearLists
|
|
|
|
* Clear the display list.
|
|
|
|
* @param aGlList = the list to clear.
|
|
|
|
* if 0 (default) all lists are cleared
|
|
|
|
*/
|
2014-07-30 15:39:55 +00:00
|
|
|
void ClearLists( int aGlList = 0 );
|
2012-12-15 08:52:02 +00:00
|
|
|
|
|
|
|
// Event functions:
|
|
|
|
void OnPaint( wxPaintEvent& event );
|
|
|
|
void OnEraseBackground( wxEraseEvent& event );
|
|
|
|
void OnChar( wxKeyEvent& event );
|
|
|
|
void OnMouseWheel( wxMouseEvent& event );
|
2015-05-21 20:54:29 +00:00
|
|
|
#ifdef USE_OSX_MAGNIFY_EVENT
|
|
|
|
void OnMagnify( wxMouseEvent& event );
|
|
|
|
#endif
|
2012-12-15 08:52:02 +00:00
|
|
|
void OnMouseMove( wxMouseEvent& event );
|
|
|
|
void OnRightClick( wxMouseEvent& event );
|
|
|
|
void OnPopUpMenu( wxCommandEvent& event );
|
2015-06-10 19:39:30 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Function TakeScreenshot
|
|
|
|
*
|
|
|
|
* creates a screenshot of the current 3D view and save to file as png or jpeg or image
|
|
|
|
* is copied to the clipboard
|
|
|
|
*/
|
2012-12-15 08:52:02 +00:00
|
|
|
void TakeScreenshot( wxCommandEvent& event );
|
|
|
|
void OnEnterWindow( wxMouseEvent& event );
|
|
|
|
|
|
|
|
// Display functions
|
|
|
|
void SetView3D( int keycode );
|
|
|
|
void DisplayStatus();
|
2014-03-05 17:40:23 +00:00
|
|
|
void Redraw();
|
2012-12-15 08:52:02 +00:00
|
|
|
void Render();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Function CreateDrawGL_List
|
2013-05-01 19:01:14 +00:00
|
|
|
* Prepares the parameters of the OpenGL draw list
|
2015-03-16 17:39:35 +00:00
|
|
|
* creates the OpenGL draw list items (board, grid ...)
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aErrorMessages = a REPORTER which will filled with error messages,
|
2015-03-16 17:39:35 +00:00
|
|
|
* if any
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aActivity = a REPORTER to display activity state
|
2012-12-15 08:52:02 +00:00
|
|
|
*/
|
2015-04-14 15:12:35 +00:00
|
|
|
void CreateDrawGL_List( REPORTER* aErrorMessages, REPORTER* aActivity );
|
2012-12-15 08:52:02 +00:00
|
|
|
void InitGL();
|
2015-03-17 07:39:15 +00:00
|
|
|
|
|
|
|
void ReportWarnings( bool aReport ) { m_reportWarnings = aReport; }
|
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
void SetLights();
|
2014-08-04 11:28:29 +00:00
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
void SetOffset(double aPosX, double aPosY)
|
|
|
|
{
|
|
|
|
m_draw3dOffset.x = aPosX;
|
|
|
|
m_draw3dOffset.y = aPosY;
|
|
|
|
}
|
2014-08-04 11:28:29 +00:00
|
|
|
|
2014-08-21 11:59:57 +00:00
|
|
|
/** @return the INFO3D_VISU which contains the current parameters
|
|
|
|
* to draw the 3D view og the board
|
|
|
|
*/
|
2014-08-20 17:53:09 +00:00
|
|
|
INFO3D_VISU& GetPrm3DVisu() const;
|
|
|
|
|
|
|
|
|
2014-08-04 11:28:29 +00:00
|
|
|
private:
|
2014-08-20 17:53:09 +00:00
|
|
|
|
2014-08-20 08:39:19 +00:00
|
|
|
/**
|
|
|
|
* return true if we are in realistic mode render
|
|
|
|
*/
|
|
|
|
bool isRealisticMode() const;
|
|
|
|
|
|
|
|
/**
|
2014-08-20 17:53:09 +00:00
|
|
|
* @return true if aItem should be displayed
|
2014-08-20 08:39:19 +00:00
|
|
|
* @param aItem = an item of DISPLAY3D_FLG enum
|
|
|
|
*/
|
|
|
|
bool isEnabled( DISPLAY3D_FLG aItem ) const;
|
|
|
|
|
2014-08-20 17:53:09 +00:00
|
|
|
/** Helper function
|
2014-08-20 08:39:19 +00:00
|
|
|
* @return true if aLayer should be displayed, false otherwise
|
|
|
|
*/
|
|
|
|
bool is3DLayerEnabled( LAYER_ID aLayer ) const;
|
|
|
|
|
2014-08-20 17:53:09 +00:00
|
|
|
/**
|
|
|
|
* @return the size of the board in pcb units
|
|
|
|
*/
|
|
|
|
wxSize getBoardSize() const;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @return the position of the board center in pcb units
|
|
|
|
*/
|
|
|
|
wxPoint getBoardCenter() const;
|
|
|
|
|
2014-08-04 11:28:29 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Helper function setGLTechLayersColor
|
2014-08-04 11:28:29 +00:00
|
|
|
* Initialize the color to draw the non copper layers
|
|
|
|
* in realistic mode and normal mode.
|
|
|
|
*/
|
2014-08-20 17:53:09 +00:00
|
|
|
void setGLTechLayersColor( LAYER_NUM aLayer );
|
2014-08-04 11:28:29 +00:00
|
|
|
|
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Helper function setGLCopperColor
|
2014-08-04 11:28:29 +00:00
|
|
|
* Initialize the copper color to draw the board
|
|
|
|
* in realistic mode (a golden yellow color )
|
|
|
|
*/
|
2014-08-20 17:53:09 +00:00
|
|
|
void setGLCopperColor();
|
2014-08-04 11:28:29 +00:00
|
|
|
|
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Helper function setGLEpoxyColor
|
2014-08-04 11:28:29 +00:00
|
|
|
* Initialize the color to draw the epoxy body board in realistic mode.
|
|
|
|
*/
|
2015-03-15 15:51:56 +00:00
|
|
|
void setGLEpoxyColor( float aTransparency = 1.0 );
|
2012-12-15 08:52:02 +00:00
|
|
|
|
2014-08-04 11:28:29 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Helper function setGLSolderMaskColor
|
2014-08-04 11:28:29 +00:00
|
|
|
* Initialize the color to draw the solder mask layers in realistic mode.
|
|
|
|
*/
|
2015-03-15 15:51:56 +00:00
|
|
|
void setGLSolderMaskColor( float aTransparency = 1.0 );
|
2014-08-04 11:28:29 +00:00
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Function buildBoard3DView
|
2013-05-01 19:01:14 +00:00
|
|
|
* Called by CreateDrawGL_List()
|
2014-03-08 19:04:23 +00:00
|
|
|
* Populates the OpenGL GL_ID_BOARD draw list with board items only on copper layers.
|
|
|
|
* 3D footprint shapes, tech layers and aux layers are not on this list
|
2015-03-16 17:39:35 +00:00
|
|
|
* Fills aErrorMessages with error messages created by some calculation function
|
2015-04-14 15:12:35 +00:00
|
|
|
* display activity state
|
2015-03-17 07:39:15 +00:00
|
|
|
* @param aBoardList =
|
|
|
|
* @param aBodyOnlyList =
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aErrorMessages = a REPORTER to add error and warning messages
|
2015-03-17 07:39:15 +00:00
|
|
|
* created by the build process (can be NULL)
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aActivity = a REPORTER to display activity state
|
2012-12-15 08:52:02 +00:00
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void buildBoard3DView( GLuint aBoardList, GLuint aBodyOnlyList,
|
2015-04-14 15:12:35 +00:00
|
|
|
REPORTER* aErrorMessages, REPORTER* aActivity );
|
2012-12-15 08:52:02 +00:00
|
|
|
|
2014-03-08 19:04:23 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Function buildTechLayers3DView
|
2014-03-08 19:04:23 +00:00
|
|
|
* Called by CreateDrawGL_List()
|
2014-07-30 15:39:55 +00:00
|
|
|
* Populates the OpenGL GL_ID_TECH_LAYERS draw list with items on tech layers
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aErrorMessages = a REPORTER to add error and warning messages
|
2015-03-17 07:39:15 +00:00
|
|
|
* created by the build process (can be NULL)
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aActivity = a REPORTER to display activity state
|
2014-03-08 19:04:23 +00:00
|
|
|
*/
|
2015-04-14 15:12:35 +00:00
|
|
|
void buildTechLayers3DView( REPORTER* aErrorMessages, REPORTER* aActivity );
|
2014-03-08 19:04:23 +00:00
|
|
|
|
2014-07-30 09:01:25 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Function buildShadowList
|
2014-07-30 09:01:25 +00:00
|
|
|
* Called by CreateDrawGL_List()
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void buildShadowList( GLuint aFrontList, GLuint aBacklist, GLuint aBoardList );
|
2014-07-30 09:01:25 +00:00
|
|
|
|
2014-03-08 19:04:23 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Function buildFootprintShape3DList
|
2014-03-08 19:04:23 +00:00
|
|
|
* Called by CreateDrawGL_List()
|
|
|
|
* Fills the OpenGL GL_ID_3DSHAPES_SOLID and GL_ID_3DSHAPES_TRANSP
|
|
|
|
* draw lists with 3D footprint shapes
|
|
|
|
* @param aOpaqueList is the gl list for non transparent items
|
|
|
|
* @param aTransparentList is the gl list for non transparent items,
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aErrorMessages = a REPORTER to add error and warning messages
|
|
|
|
* created by the build process (can be NULL)
|
|
|
|
* @param aActivity = a REPORTER to display activity state
|
2014-03-08 19:04:23 +00:00
|
|
|
* which need to be drawn after all other items
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void buildFootprintShape3DList( GLuint aOpaqueList,
|
2015-04-14 15:12:35 +00:00
|
|
|
GLuint aTransparentList,
|
|
|
|
REPORTER* aErrorMessages, REPORTER* aActivity );
|
2014-03-08 19:04:23 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Function buildBoard3DAuxLayers
|
2014-03-08 19:04:23 +00:00
|
|
|
* Called by CreateDrawGL_List()
|
|
|
|
* Fills the OpenGL GL_ID_AUX_LAYERS draw list
|
|
|
|
* with items on aux layers only
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aErrorMessages = a REPORTER to add error and warning messages
|
|
|
|
* created by the build process (can be NULL)
|
|
|
|
* @param aActivity = a REPORTER to display activity state
|
|
|
|
* which need to be drawn after all other items
|
2014-03-08 19:04:23 +00:00
|
|
|
*/
|
2015-04-14 15:12:35 +00:00
|
|
|
void buildBoard3DAuxLayers( REPORTER* aErrorMessages, REPORTER* aActivity );
|
2014-03-08 19:04:23 +00:00
|
|
|
|
2015-03-28 11:33:56 +00:00
|
|
|
void draw3DGrid( double aGriSizeMM );
|
|
|
|
void draw3DAxis();
|
2014-03-08 19:04:23 +00:00
|
|
|
|
2014-08-04 11:28:29 +00:00
|
|
|
/**
|
|
|
|
* Helper function BuildPadShapeThickOutlineAsPolygon:
|
|
|
|
* Build a pad outline as non filled polygon, to draw pads on silkscreen layer
|
|
|
|
* with a line thickness = aWidth
|
|
|
|
* Used only to draw pads outlines on silkscreen layers.
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void buildPadShapeThickOutlineAsPolygon( const D_PAD* aPad,
|
2015-07-27 19:45:57 +00:00
|
|
|
SHAPE_POLY_SET& aCornerBuffer,
|
2014-08-04 11:28:29 +00:00
|
|
|
int aWidth,
|
|
|
|
int aCircleToSegmentsCount,
|
|
|
|
double aCorrectionFactor );
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Helper function draw3DViaHole:
|
2014-08-04 11:28:29 +00:00
|
|
|
* Draw the via hole:
|
|
|
|
* Build a vertical hole (a cylinder) between the first and the last via layers
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void draw3DViaHole( const VIA * aVia );
|
2014-08-04 11:28:29 +00:00
|
|
|
|
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* Helper function draw3DPadHole:
|
2014-08-04 11:28:29 +00:00
|
|
|
* Draw the pad hole:
|
|
|
|
* Build a vertical hole (round or oblong) between the front and back layers
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void draw3DPadHole( const D_PAD * aPad );
|
2012-12-15 08:52:02 +00:00
|
|
|
|
2015-03-13 19:27:25 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* function render3DComponentShape
|
2015-03-13 19:27:25 +00:00
|
|
|
* insert mesh in gl list
|
|
|
|
* @param module
|
|
|
|
* @param aIsRenderingJustNonTransparentObjects = true to load non transparent objects
|
|
|
|
* @param aIsRenderingJustTransparentObjects = true to load non transparent objects
|
|
|
|
* in openGL, transparent objects should be drawn *after* non transparent objects
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
void render3DComponentShape( MODULE* module,
|
2015-03-13 19:27:25 +00:00
|
|
|
bool aIsRenderingJustNonTransparentObjects,
|
2015-03-28 11:33:56 +00:00
|
|
|
bool aIsRenderingJustTransparentObjects );
|
2015-03-13 19:27:25 +00:00
|
|
|
|
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* function read3DComponentShape
|
2015-03-13 19:27:25 +00:00
|
|
|
* read the 3D component shape(s) of the footprint (physical shape).
|
|
|
|
* @param module
|
|
|
|
* @return true if load was succeeded, false otherwise
|
|
|
|
*/
|
2015-03-28 11:33:56 +00:00
|
|
|
bool read3DComponentShape( MODULE* module );
|
2015-03-13 19:27:25 +00:00
|
|
|
|
2015-03-17 07:39:15 +00:00
|
|
|
/**
|
2015-03-28 11:33:56 +00:00
|
|
|
* function generateFakeShadowsTextures
|
2015-03-17 07:39:15 +00:00
|
|
|
* creates shadows of the board an footprints
|
|
|
|
* for aesthetical purpose
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aErrorMessages = a REPORTER to add error and warning messages
|
2015-03-17 07:39:15 +00:00
|
|
|
* created by the build process (can be NULL)
|
2015-04-14 15:12:35 +00:00
|
|
|
* @param aActivity = a REPORTER to display activity state
|
2015-03-17 07:39:15 +00:00
|
|
|
*/
|
2015-04-14 15:12:35 +00:00
|
|
|
void generateFakeShadowsTextures( REPORTER* aErrorMessages, REPORTER* aActivity );
|
2014-07-30 09:01:25 +00:00
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
DECLARE_EVENT_TABLE()
|
|
|
|
};
|
|
|
|
|
2014-07-30 09:01:25 +00:00
|
|
|
void CheckGLError(const char *aFileName, int aLineNumber);
|
|
|
|
|
2012-12-15 08:52:02 +00:00
|
|
|
#endif /* _3D_CANVAS_H_ */
|