MOAL.data_structures.other package

Submodules

MOAL.data_structures.other.heightmap module

class MOAL.data_structures.other.heightmap.HeightMap(size=10, max=10)[source]

A heightmap is a data structure used to store the height values of (typically) a terrain geometry in 3-d programs.

Each value may represent discrete sections across the terrain grid.

__init__(size=10, max=10)[source]
get_data(ztype='sin')[source]

Return data format suitable for plotting.

MOAL.data_structures.other.lightmap module

class MOAL.data_structures.other.lightmap.Lightmap(height=10, width=10)[source]

From Wikipedia: “A lightmap is a data structure which contains the brightness of surfaces in 3d graphics applications such as video games. Lightmaps are pre-computed, and normally used for static objects only. They are particularly suited to urban and indoor environments with large planar surfaces.”

__init__(height=10, width=10)[source]
__str__()[source]

This is a ...weird... method, but it’s SOME way to visualize the notion of lighting, as darkness and lightness. Since I can’t be bothered to actually build a real renderer for this project, I’m doing this to illustrate the idea in a fun(?) way.

compute(recipe=1)[source]

Don’t be confused: the notion of a recipe is just for fun here. It has nothing to do with lightmaps – it’s just to experiment with example ‘ascii lighting’ for more interesting visualizations.

MOAL.data_structures.other.routing_table module

class MOAL.data_structures.other.routing_table.RoutingTable[source]
__getitem__(key)
__init__()
__str__()
add(data)
get_all(key)
get_networkid(ip)

Network ID is comprised of Network Destination and Netmask, using CIDR notation. https://www.youtube.com/watch?v=t5xYI0jzOf4

MOAL.data_structures.other.symbol_table module

MOAL.data_structures.other.symbol_table.format_table(code_string)[source]

MOAL.data_structures.other.winged_edge module

class MOAL.data_structures.other.winged_edge.WingedEdge(*args, **kwargs)[source]
__init__(*args, **kwargs)
__str__()
add_edge(edge_name)
add_face(left, right)
add_traversal(*args, **kwargs)
add_vertices(start, end)
class MOAL.data_structures.other.winged_edge.WingedEdgeEdge(edge, data={})[source]
__init__(edge, data={})
class MOAL.data_structures.other.winged_edge.WingedEdgeFace(orient, data={})[source]
__init__(orient, data={})
class MOAL.data_structures.other.winged_edge.WingedEdgeTraversal(pred, succ)[source]
__init__(pred, succ)
class MOAL.data_structures.other.winged_edge.WingedEdgeVertex(start, end, data={})[source]
__init__(start, end, data={})