    explicit CameraWidget(std::string stream_name, VisionStreamType stream_type, bool zoom, QWidget* parent = nullptr);
    ~CameraWidget();
    void setBackgroundColor(const QColor &color) { bg = color; }
    void setFrameId(int frame_id) { draw_frame_id = frame_id; }
  
  signals:
    void clicked();
    void vipcThreadConnected(VisionIpcClient *);
    void vipcThreadFrameReceived();
 
</s> remove   void setStreamType(VisionStreamType type) { stream_type = type; }
 </s> add  </s> remove                                    stream_name(stream_name), stream_type(type), zoomed_view(zoom), QOpenGLWidget(parent) {
 </s> add                           stream_name(stream_name), requested_stream_type(type), zoomed_view(zoom), QOpenGLWidget(parent) { </s> remove   VisionStreamType cur_stream_type = stream_type;
 </s> add   VisionStreamType cur_stream = requested_stream_type; </s> remove   }
  if (s->worldObjectsVisible()) {
    if (sm.updated("modelV2")) {
      update_model(s, sm["modelV2"].getModelV2());
    }
    if (sm.updated("radarState") && sm.rcv_frame("modelV2") > s->scene.started_frame) {
      update_leads(s, sm["radarState"].getRadarState(), sm["modelV2"].getModelV2().getPosition());
    }
 </s> add     scene.calibration_wide_valid = wfde_list.size() == 3; </s> remove 
  if (sm.updated("carState")) {
    float v_ego = sm["carState"].getCarState().getVEgo();
    // TODO: support replays without ecam by using fcam
    // Wide or narrow cam dependent on speed
    if ((v_ego < 10) || s->wide_cam_only) {
      scene.wide_cam = true;
    } else if (v_ego > 15) {
      scene.wide_cam = false;
    }
  }
 </s> add 
  void setStreamType(VisionStreamType type) { requested_stream_type = type; }
  VisionStreamType getStreamType() { return active_stream_type; }
    explicit CameraWidget(std::string stream_name, VisionStreamType stream_type, bool zoom, QWidget* parent = nullptr);
    ~CameraWidget();
    void setBackgroundColor(const QColor &color) { bg = color; }
    void setFrameId(int frame_id) { draw_frame_id = frame_id; }
  void setStreamType(VisionStreamType type) { requested_stream_type = type; }
  VisionStreamType getStreamType() { return active_stream_type; }
  
  signals:
    void clicked();
    void vipcThreadConnected(VisionIpcClient *);
    void vipcThreadFrameReceived();
keep keep keep add keep keep keep keep keep
 UI: draw onroad objects on right frame (#26306)

* update before draw

* fix a lot of janky

* fix more flicker

* cleanup

* fix flicker when opening settings

* simplify 
selfdrive/ui/qt/widgets/cameraview.h