top of page

[Aug. 21st - Aug.25th] Week 9 Report

This week's work mainly focus on integration..Also, add new features as well.

 

1. How did I do integration to Grind?

As final committed to Grind Repo, I put everything related to PokeMeow inside Grind(as grind's renderer). Also, I tried to make it a local reference as a unified jar file and it also works.

2.Structure of calling pokemeow to draw

a) In GrindRenderingEngineFactory, there is a RootPaneContainer. Add a desktopPane and then apply internal frames inside it(as canvas to make everything displayed).

b) Create a viewport which implements GLEventListener(necessary), MouseListener(works now ) and KeyListener(Confilicts, already listen to keyboard, not working).

c) Create and call a renderer inside viewport. Also, viewport takes the responsibility to control mouse behavior and invoke actions.

d) GrindRenderer focus on creating and drawing objects. On initialization, just setup the whole network and keep nodes in nodeList while keep edges in edgeList.

Do full-coverage-query to nodes as optional.

Draw objects on screen by going through the arrayList.

e) Dynamically change the network

Use mouse interaction(events listened from viewport) to make dynamic changes to network. Either add a new object, select, delete or adjust position and scales.

In all, everything related to actual drawing should take place in GrindRenderer.

3. Changes made in Pokemeow(haven't been Synchronized yet)

a) Make reshape as what we want it to be. When reshaping a window, we want every single object keep the position and size without distortion.

However, this can not be achieved automatically by openGL. Therefore, we need to change viewMatrix manually to keep the position. Now works for renderToTexture, but some artifacts exists when mouse interaction is applied.

b) SimpleNodesFactory to draw a large number of nodes(hair ball) inside viewport. We make everything simplest : the shader, shape, parameters to get the fastest and inaccuracy draw. For edges, just use solid edges without arrowhead will cost only 2 vertices.

bottom of page