void PictoAction::paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget ) {/*{{{*/ Q_UNUSED( option ); Q_UNUSED( widget ); int pos = drawDetails( painter, labels_.at( 0 ), 5 ); pos += 10; painter->drawRect( pos, 5, labels_.at( 1 )->width(), 50 ); labels_.at( 1 )->setPos( pos, 5 ); pos += labels_.at( 1 )->width() + 15; pos = drawDetails( painter, labels_.at( 2 ), pos ); Pictogramme::paint( painter, option, widget ); }/*}}}*/
void LightCycle::drawBike() { drawBottomDetails(); drawBottomBar(); drawEngineBlock(); drawFront(); drawBack(); drawInnerCircles(); drawLayeredCircles(); drawDetails(); }
//-------------------------------------------------------------- void kinectApp::draw(){ //-- background --// drawBack(); //-- show tracking results --// ofSetColor(255, 255, 255); if (isLive) { drawCamView(); if (hands) { drawAllHands(); } if (skel) { drawSkeletons(); } if (objects) { drawObjects(); } drawDetails(); } ofSetColor (255, 255, 255); //-- show FrameRate --// stringstream msgA; msgA //<< "FrameRate: " << ofToString(int(ofGetFrameRate())) << endl //uncomment this to get processed FrameRate << "FrameRate: " << ofToString(fps) << " " << endl; usedFont.drawString(msgA.str(), 16, 126); //-- calculate & display tracking status --// if (isLive && skel) { statusSkeletons = ofToString(openNIDevices.getNumTrackedUsers()); } else { statusSkeletons = "0"; } if (isLive && hands) { statusHands = ofToString(openNIDevices.getNumTrackedHands()); } else { statusHands = "0"; } if (isLive && objects) { statusObjects = ofToString(contourFinder.blobs.size()); } else { statusObjects = "0"; } stringstream msgB; msgB << "Hands: " << statusHands << endl << "Skeletons: " << statusSkeletons << endl << "Objects: " << statusObjects << endl; usedFont.drawString(msgB.str(), 136, 126); //-- show status of settings (new, saved, loaded or reset) --// stringstream msgC; msgC << "Settings: " << statusConfig << endl; usedFont.drawString(msgC.str(), 256, 126); //-- show osc info --// stringstream msgD; msgD << "SEND DATA TO" << endl << "Host: " << host << endl << "Port: " << ofToString(port) << endl; usedFont.drawString(msgD.str(), 471, 126); }