# OCC.Display.WebGl.threejs_renderer module

`ExportEdgeToJSON`(edge_hash, point_set)

  Export a set of points to a LineSegment buffergeometry

class `HTMLBody_Part1`(vertex_shader=None, fragment_shader=None, uniforms=None)

  Bases: `object`

  `get_str`()

class `HTMLHeader`(bg_gradient_color1=’#ced7de’, bg_gradient_color2=’#808080’)

  Bases: `object`

  `get_str`()

class `ThreejsRenderer`(path=None)

  Bases: `object`

  `DisplayShape`(shape, vertex_shader=None, fragment_shader=None, map_faces_to_mesh=False, export_edges=False, color=(0.65, 0.65, 0.65), specular_color=(1, 1, 1), shininess=0.9, transparency=0.0, line_color=(0, 0.0, 0.0), line_width=2.0, mesh_quality=1.0)
  `GenerateHTMLFile`()

    Generate the HTML file to be rendered by the web browser

  `render`(server_port=8080)

    render the scene into the browser.

`color_to_hex`(rgb_color)

  Takes a tuple with 3 floats between 0 and 1. Returns a hex. Useful to convert occ colors to web color code