Name

getChildCount()

Class

PShape

Description

Returns the number of children within the PShape.

Examples

  • PShape states;
    
    void setup() {
      size(100, 100);
      states = loadShape("tristate.svg");
      int count = states.getChildCount();
      println(count);
    }
    

Syntax

  • sh.getChildCount()

Parameters

  • sh(PShape) any variable of type PShape

Return

  • int