GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — bug in parseCaps · Issue #224 · processing/processing-video Open DescriptionI need to get the resolution of the webcam. In the source we have the following: // This is a temporary addition until it's decided how to bring back resolution/framerate caps to the official API. // The old way of doing things is still listed in the video tutorial: // https://processing.org/tutorials/video static public String[] getCapabilities(String device) { for (int i=0; i < devices.size(); i++) { String deviceName = assignDisplayName(devices.get(i), i); if (devices.get(i).getDisplayName().equals(device) || devices.get(i).getName().equals(device) || deviceName.equals(device)) { return parseCaps(devices.get(i)); } } return new String[]{}; } The above calls if (0 < indexWidth && 0 < indexHeight && 0 < indexFramerate) { stringWidth = cap.substring(indexWidth, cap.indexOf(',', indexWidth)); stringHeight = cap.substring(indexHeight, cap.indexOf(", format", indexHeight)); stringFramerate = cap.substring(indexFramerate, cap.indexOf(']', indexFramerate)); } An example of the String cap is The problem with the above code is that Activity
MetadataMetadataAssigneesLabelsNo labels TypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |