SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Studio
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Studio Discussion related to the SageTV Studio application produced by SageTV. Questions, issues, problems, suggestions, etc. relating to the Studio software application should be posted here.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 12-06-2008, 01:13 PM
jvl711's Avatar
jvl711 jvl711 is offline
Sage Fanatic
 
Join Date: Jan 2004
Posts: 825
Help getting Screen Capture of GUI

I am trying to capture the Sage GUI to a jpg file. I feel like I am close, but I am thinking that Sage may have a non standard way of drawing the components. Here is what I have so far. It throws no errors, but results in a completely black image.

panel = java_awt_Panel_getParent(GetEmbeddedPanel())
width = java_awt_Panel_getWidth(panel)
height = java_awt_Panel_getHeight(panel)
image = new_java_awt_image_BufferedImage(width, height, java_awt_image_BufferedImage_TYPE_INT_RGB)
java_awt_image_BufferedImage_createGraphics(image)
graphics = java_awt_image_BufferedImage_getGraphics(image)
java_awt_Panel_paintAll(panel,graphics)
javax_imageio_ImageIO_write(image, "jpg", layoutImageFile)

Any help would be really appreciated,
Thanks
Reply With Quote
  #2  
Old 12-06-2008, 01:44 PM
GKusnick's Avatar
GKusnick GKusnick is offline
SageTVaholic
 
Join Date: Dec 2005
Posts: 5,083
The documentation for GetEmbeddedPanel() doesn't say anything about Sage rendering its UI to that panel. It just says you can use that panel to embed Java UI elements within the Sage UI. So my assumption would be that the panel is empty unless you add something to it.

Have you looked at java.awt.Robot.createScreenCapture()?
__________________
-- Greg
Reply With Quote
  #3  
Old 12-06-2008, 01:49 PM
jvl711's Avatar
jvl711 jvl711 is offline
Sage Fanatic
 
Join Date: Jan 2004
Posts: 825
Quote:
Originally Posted by GKusnick View Post
The documentation for GetEmbeddedPanel() doesn't say anything about Sage rendering its UI to that panel. It just says you can use that panel to embed Java UI elements within the Sage UI. So my assumption would be that the panel is empty unless you add something to it.

Have you looked at java.awt.Robot.createScreenCapture()?
That is true, but I was getting the parent container, which I think might be the render object. This is what the object looks like with a toString().

Sat 12/6 14:06:36.990 Panel = sage.SpecialWindow[frame6,1319,52,1123x949,invalid,layout=sage.SpecialWindow,title=SageTV Client,resizable,normal]

Yes I looked at Robot. It looks like that only captures objects on the desktop, which would not work for HD100, HD200 or placeshifter.
Reply With Quote
  #4  
Old 12-06-2008, 07:35 PM
shadeblue.com's Avatar
shadeblue.com shadeblue.com is offline
Sage Aficionado
 
Join Date: Jun 2008
Posts: 435
I'm not sure exactly what you are looking to do, but I wrote some java code against this API: http://www.sagetv.com/2_papers/OSDPlugins.txt
to capture the current on-screen user interface to a JPG file.

(does not include the media content, only the STV)

-SB
__________________
Server Hardware: Intel Core 2 Quad Q6700 2.66GHz CPU, 4GB DDR2 RAM, NVIDIA nForce 780i SLI Motherboard, GeForce 8600 GT, Seagate Barracuda 7200.11 2.5TB
Operating System: Windows XP Professional
HTPC/DVR Software: SageTV 7
Capture Devices: 2 @ Hauppauge HD-PVR (1212), Hauppauge WinTV-HVR-1600 ATSC/QAM, HD Homerun
Media Extenders: 2 @ Sage HD100 & 1 @ Sage HD200
Signals/Providers: AT&T UVerse, OTA ATSC
Set-Top-Box: 2 @ Motorola Box VIP 1200
Reply With Quote
  #5  
Old 12-07-2008, 07:54 AM
jvl711's Avatar
jvl711 jvl711 is offline
Sage Fanatic
 
Join Date: Jan 2004
Posts: 825
Quote:
Originally Posted by shadeblue.com View Post
I'm not sure exactly what you are looking to do, but I wrote some java code against this API: http://www.sagetv.com/2_papers/OSDPlugins.txt
to capture the current on-screen user interface to a JPG file.

(does not include the media content, only the STV)

-SB
That would definetly work, but I am looking to do it from an STVi. Can this spec be used to capture the screen without setting it as an OSD plugin?

This is for my iMovies plugin. I want to take a screen capture of the layout when a user saves their settings.

From the looks of the OSDplugin spec Sage does not appear to be using the standard paint methods for drawing the OSD GUI.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Capture Devices Gone After Reboot hchucky Hardware Support 6 11-14-2008 10:24 PM
Screen Capture feature Jukin SageTV Software 3 08-26-2008 02:26 AM
Is there any way to capture OTA digital signal and play via MVP? InvisiblePin SageTV Media Extender 11 11-30-2006 05:03 PM
Force Full Screen in Sage mike1961 SageTV Software 10 06-22-2006 11:52 AM
Blank Screen after Windows Screen Saver TheThumper SageTV Software 3 01-30-2006 06:05 PM


All times are GMT -6. The time now is 02:30 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.