code: func setBlendFunc(cmp pixel.ComposeMethod) {
  	switch cmp {
  	case pixel.ComposeOver:
  		glhf.BlendFunc(glhf.One, glhf.OneMinusSrcAlpha)
  	case pixel.ComposeIn:
  		glhf.BlendFunc(glhf.DstAlpha, glhf.Zero)
  	case pixel.ComposeOut:
  		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.Zero)
  	case pixel.ComposeAtop:
  		glhf.BlendFunc(glhf.DstAlpha, glhf.OneMinusSrcAlpha)
  	case pixel.ComposeRover:
  		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.One)
  	case pixel.ComposeRin:
  		glhf.BlendFunc(glhf.Zero, glhf.SrcAlpha)
  	case pixel.ComposeRout:
  		glhf.BlendFunc(glhf.Zero, glhf.OneMinusSrcAlpha)
  	case pixel.ComposeRatop:
  		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.SrcAlpha)
  	case pixel.ComposeXor:
  		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.OneMinusSrcAlpha)
  	case pixel.ComposePlus:
  		glhf.BlendFunc(glhf.One, glhf.One)
  	case pixel.ComposeCopy:
  		glhf.BlendFunc(glhf.One, glhf.Zero)
  	default:
  		panic(errors.New("Canvas: invalid compose method"))
  	}
  }
docs: // must be manually called inside mainthread