()
| 68 | } |
| 69 | |
| 70 | public byte[] toArray() { |
| 71 | int num = checkVector(_channels, _depth); |
| 72 | if(num < 0) |
| 73 | throw new RuntimeException("Native Mat has unexpected type or size: " + toString()); |
| 74 | byte[] a = new byte[num * _channels]; |
| 75 | if(num == 0) |
| 76 | return a; |
| 77 | get(0, 0, a); //TODO: check ret val! |
| 78 | return a; |
| 79 | } |
| 80 | |
| 81 | public void fromList(List<Byte> lb) { |
| 82 | if(lb==null || lb.size()==0) |
no test coverage detected