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 11-22-2005, 11:43 AM
nielm's Avatar
nielm nielm is offline
SageTVaholic
 
Join Date: Oct 2003
Location: Belgium
Posts: 4,496
Diagonal lines

If I make a 'line' shape with a certain width and height, I get a diagonal line: \ (top-left->bottom-right)...

How do I make a diagonal line in the opposite direction: / ?

Is this what 'line shapes are not fully supported' means in the docs?!
__________________
Check out my enhancements for Sage in the Sage Customisations and Sageplugins Wiki
Reply With Quote
  #2  
Old 11-22-2005, 11:54 AM
Opus4's Avatar
Opus4 Opus4 is offline
Administrator
 
Join Date: Sep 2003
Location: NJ
Posts: 19,624
Quote:
Originally Posted by nielm
If I make a 'line' shape with a certain width and height, I get a diagonal line: \ (top-left->bottom-right)...

How do I make a diagonal line in the opposite direction: / ?
Try negative values. I made a line go the other direction using
Anchor X = 0.0
Anchor Y = 1.0
Fixed Width = -1.0
Fixed Height = 1.0
Anchor Point X = 1.0
Anchor Point Y = 1.0

Quote:
Is this what 'line shapes are not fully supported' means in the docs?!
Line Shapes don't get drawn correctly, or at all, when 3D Acceleration is enabled... which limits them to simple vertical/horiz lines using rectangles instead. Edit: When 3D is off, the diagonal lines are visible on the Overscan adjustment screens.

- Andy
__________________
SageTV Open Source v9 is available.
- Read the SageTV FAQ. Older PDF User's Guides mostly still apply: SageTV V7.0 & SageTV Studio v7.1.
- Hauppauge remote help: 1) Basics/Extending it 2) Replace it 3) Use it w/o needing focus
- HD Extenders: A) FAQs B) URC MX-700 remote setup
Note: This is a users' forum; see the Rules. For official tech support fill out a Support Request.
Reply With Quote
  #3  
Old 11-22-2005, 12:36 PM
deria deria is offline
Sage Aficionado
 
Join Date: Nov 2005
Posts: 408
You might suffer a performance penalty, but you could instead use an image object and draw the content of the line into the image. As long as the image object has a transparent background, you should be good to go.

I'm not a Java programmer so I'm not sure how to manipulate the bufferedimage object, but you could start with the article at:

http://www.javaworld.com/javaworld/j...-09-media.html

In .NET, this is pretty trivial. You basically create a bitmap object and then instantiate a graphics object from it which allows you to use all of the line/shape/bitmap/anything-related-to-drawing functions against the bitmap. I imagine that Java has something similar.

Behind the scenes, SageTV converts images to DirectX9 textures as soon as they're created, so once the image is created there should be no performance issues. As long as you're careful to not recreate the image every time its drawn, it shouldn't be possible to tell that any funny business is going on with regard to the line.

I was thinking about this earlier because I have a need to draw circles, arcs, and ellipse shapes.
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


All times are GMT -6. The time now is 06:10 PM.


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