Some work on rendering, still really incomplete