kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #32562
Re: help with redraw
-
To:
<kicad-developers@xxxxxxxxxxxxxxxxxxx>
-
From:
Maciej Sumiński <maciej.suminski@xxxxxxx>
-
Date:
Thu, 21 Dec 2017 13:11:44 +0100
-
Authentication-results:
spf=pass (sender IP is 188.184.36.48) smtp.mailfrom=cern.ch; lists.launchpad.net; dkim=none (message not signed) header.d=none;lists.launchpad.net; dmarc=bestguesspass action=none header.from=cern.ch;
-
In-reply-to:
<c237f499-c9f0-52b7-d8df-3938d132a1ef@andreasbuhr.de>
-
Spamdiagnosticmetadata:
NSPM
-
Spamdiagnosticoutput:
1:99
-
User-agent:
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0
Hi Andreas,
You might be missing VIEW::Update() [1] call to invalidate a VIEW_ITEM
after it has been modified. If it does not help, I will have a look at
the code.
Cheers,
orson
1.
http://ci.kicad-pcb.org/job/kicad-doxygen/ws/Documentation/doxygen/html/classKIGFX_1_1VIEW.html#af8f6652fbafaf7ed08281ee9311e7857
On 12/21/2017 01:02 PM, Andreas Buhr wrote:
> Hi,
>
> could you maybe help me finding the right redraw or refresh or whatever
> function? I can draw everything, but I see my polygons only after I
> switched the canvas once (Cairo->OpenGL or vice versa). So my workflow
> at the moment is: 1. Open pcbnew, 2. switch the canvas, 3. then work
> normally.
>
> I followed the structure of RATSNEST and added a layer "LAYER_SI_MESH"
> (like "LAYER_RATSNEST").
>
> https://github.com/andreasbuhr/kicad/blob/e9695ce2f735d660771e342c4538ad707e97aa16/include/layers_id_colors_and_visibility.h#L205
>
>
> I then added a "SI_MESH_VIEWITEM" (like "RATSNEST_VIEWITEM") which has a
> "ViewDraw" function, wherein I draw the polygons on the GAL.
>
> https://github.com/andreasbuhr/kicad/blob/e9695ce2f735d660771e342c4538ad707e97aa16/pcbnew/si_mesh_viewitem.cpp#L54
>
>
> In PCB_DRAW_PANEL_GAL::DisplayBoard( BOARD* aBoard ), I added the
> SI_MESH_VIEWITEM
>
> https://github.com/andreasbuhr/kicad/blob/e9695ce2f735d660771e342c4538ad707e97aa16/pcbnew/pcb_draw_panel_gal.cpp#L178
>
> But it seems I am missing something. Any suggestions?
>
> Thanks a lot!
> Andreas
>
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help : https://help.launchpad.net/ListHelp
>
Attachment:
signature.asc
Description: OpenPGP digital signature
Follow ups
References