3D viewer: fix a draw issue: missing holes.

Fixes #6608
https://gitlab.com/kicad/code/kicad/issues/6608
This commit is contained in:
jean-pierre charras 2020-12-04 16:35:57 +01:00
parent 2050e05944
commit e6550fb92e
1 changed files with 17 additions and 16 deletions

View File

@ -56,7 +56,7 @@ C3D_RENDER_OGL_LEGACY::C3D_RENDER_OGL_LEGACY( BOARD_ADAPTER& aAdapter, CCAMERA&
m_through_holes_outer = NULL;
m_through_holes_outer_ring = NULL;
m_through_holes_vias_outer = NULL;
//m_ogl_disp_list_through_holes_vias_inner = NULL;
//m_through_holes_vias_inner = NULL;
m_vias = NULL;
m_pad_holes = NULL;
m_vias_and_pad_holes_outer_contourn_and_caps = NULL;
@ -727,7 +727,6 @@ bool C3D_RENDER_OGL_LEGACY::Redraw( bool aIsMoving, REPORTER* aStatusReporter,
if( layer_id == F_Cu && m_platedPads_F_Cu )
{
m_platedPads_F_Cu->DrawAllCameraCulled( m_camera.GetPos().z,
drawMiddleSegments );
}
@ -796,7 +795,8 @@ bool C3D_RENDER_OGL_LEGACY::Redraw( bool aIsMoving, REPORTER* aStatusReporter,
}
else
{
pLayerDispList->DrawAllCameraCulledSubtractLayer( m_through_holes_outer,
pLayerDispList->DrawAllCameraCulledSubtractLayer( drawMiddleSegments,
m_through_holes_outer,
m_anti_board );
// Draw copper plated pads
@ -831,7 +831,8 @@ bool C3D_RENDER_OGL_LEGACY::Redraw( bool aIsMoving, REPORTER* aStatusReporter,
CLAYERS_OGL_DISP_LISTS* throughHolesOuter =
m_boardAdapter.GetFlag( FL_CLIP_SILK_ON_VIA_ANNULUS )
&& m_boardAdapter.GetFlag( FL_USE_REALISTIC_MODE )
&& ( layer_id == B_SilkS || layer_id == F_SilkS ) ? m_through_holes_outer_ring
&& ( layer_id == B_SilkS || layer_id == F_SilkS )
? m_through_holes_outer_ring
: m_through_holes_outer;
if( throughHolesOuter )