From: Sunny <su...@op...> - 2005-09-16 00:51:23
|
I'm trying to get the CameraInterface working, but all I seem to get betting back from player is gibberish. Here is a short listing of the program I'm using: public static void main(String args[]) { System.out.println("testing..."); PlayerClient pc = new PlayerClient("host", 6665); CameraInterface ci = pc.requestInterfaceCamera(0, 'r'); pc.runThreaded(-1,-1); if (ci != null) System.out.println("CameraInterface good"); while (true) { ci.readData(); System.out.println("Width: " + ci.getWidth()); System.out.println("Height: " + ci.getHeight()); if (ci.getCompression() == CameraInterface.PLAYER_CAMERA_COMPRESS_RAW) { System.out.println("Compression: RAW"); } else { System.out.println("Compression: JPEG"); } System.out.println("Size: " + ci.getImageSize()); System.out.println("--------------------------"); sleep(1000); } That is essentially the main part of the test program, it seems simply enough, but I'm getting values like these back: Player v.1.6.4 [PlayerClient] : Got response for device 40(camerav4l) with access: r CameraInterface good Width: 0 Height: -16384 Compression: RAW Size: 0 -------------------------- Width: 0 Height: 0 Compression: RAW Size: -1073741824 -------------------------- Width: 0 Height: 0 Compression: RAW Size: 0 -------------------------- Width: 0 Height: 0 Compression: RAW Size: -1073741824 -------------------------- Width: 0 Height: -16384 Compression: JPEG Size: 49152 -------------------------- I know the camera itself works since I can use it in other programs (xawtv), so I'm assuming this is a playerstage/javaclient problem. Any pointers? thanks, Sunny |
From: Radu B. R. <ru...@cs...> - 2005-09-16 08:03:29
Attachments:
smime.p7s
|
I had the same problem while playing with the CMUcam2 some months ago. I had to go into the player driver and modify a lot of things in order to get stuff to work. What player driver are you using? I have a hunch that is a player issue (since Javaclient worked just fine with the CMUcam2), but we could check Javaclient as well. :) Cheers, Radu. Sunny wrote: > I'm trying to get the CameraInterface working, but all I seem to get > betting back from player is gibberish. Here is a short listing of the > program I'm using: > > public static void main(String args[]) { > > System.out.println("testing..."); > > PlayerClient pc = new PlayerClient("host", 6665); > CameraInterface ci = pc.requestInterfaceCamera(0, 'r'); > pc.runThreaded(-1,-1); > > if (ci != null) System.out.println("CameraInterface good"); > > while (true) { > ci.readData(); > System.out.println("Width: " + ci.getWidth()); > System.out.println("Height: " + ci.getHeight()); > if (ci.getCompression() == > CameraInterface.PLAYER_CAMERA_COMPRESS_RAW) { > System.out.println("Compression: RAW"); > } else { > System.out.println("Compression: JPEG"); > } > System.out.println("Size: " + ci.getImageSize()); > System.out.println("--------------------------"); > sleep(1000); > } > > That is essentially the main part of the test program, it seems simply > enough, but I'm getting values like these back: > Player v.1.6.4 > [PlayerClient] : Got response for device 40(camerav4l) with access: r > CameraInterface good > Width: 0 > Height: -16384 > Compression: RAW > Size: 0 > -------------------------- > Width: 0 > Height: 0 > Compression: RAW > Size: -1073741824 > -------------------------- > Width: 0 > Height: 0 > Compression: RAW > Size: 0 > -------------------------- > Width: 0 > Height: 0 > Compression: RAW > Size: -1073741824 > -------------------------- > Width: 0 > Height: -16384 > Compression: JPEG > Size: 49152 > -------------------------- > > I know the camera itself works since I can use it in other programs > (xawtv), so I'm assuming this is a playerstage/javaclient problem. > > Any pointers? > > thanks, > Sunny > > > ------------------------------------------------------- > SF.Net email is sponsored by: > Tame your development challenges with Apache's Geronimo App Server. > Download > it for free - -and be entered to win a 42" plasma tv or your very own > Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php > _______________________________________________ > Java-player-users mailing list > Jav...@li... > https://lists.sourceforge.net/lists/listinfo/java-player-users -- Yours sincerely, Radu Bogdan Rusu -- | Radu Bogdan Rusu | http://www.rbrusu.com | Intelligent Autonomous Systems Group | Technische Universitaet Muenchen |