SageTV Community  

Go Back   SageTV Community > SageTV Products > SageTV Linux
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Linux Discussion related to the SageTV Media Center for Linux. Questions, issues, problems, suggestions, etc. relating to the SageTV Linux should be posted here.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-17-2011, 06:42 AM
troll5501 troll5501 is offline
Sage Advanced User
 
Join Date: Jun 2006
Posts: 136
HD-PVR contrast, hue, saturation, etc.

So I'm trying out the beta firmware for the HD-PVR (installed via the Windows 1.6.29207 driver install), however the picture looks terrible with the default calibration settings, as discussed in this thread:

http://forums.sagetv.com/forums/showthread.php?t=56698

Unfortunately I cannot get Sage to use the modified settings that I put into Sage.properties as suggested by the Windows users. Does anyone know if this should work for Linux?

I can use v4l2-ctl to manually change them but when Sage starts a new recording they go back to the defaults. So Sage seems to know how to change them but it's disregarding the values I put into Sage.properties.
__________________
Server: HP DL380 G6, VMware ESXi 5.0 with HW passthrough for USB and Firewire, 4 x HD-PVR, ZFS storage
SageTV: Production: 7.1.9+Java 1.6.0_32 on XP, Test: 9.0.4.291+Java 1.8.0_72 on Linux 64-bit
Clients: 2 x Sage HD200 Extender, 1 x Sage HD100 Extender
Sources: 4 x Motorola DCH-3200 (firewire channel changing), HD Homerun Prime, OpenDCT 0.5.7
Reply With Quote
  #2  
Old 08-17-2011, 09:09 AM
gplasky's Avatar
gplasky gplasky is offline
SageTVaholic
 
Join Date: Jul 2003
Location: Howell, MI
Posts: 9,203
Did you stop Sage running when you edited the .properties file?

Gerry
__________________
Big Gerr
_______
Server - WHS 2011: Sage 7.1.9 - 1 x HD Prime and 2 x HDHomeRun - Intel Atom D525 1.6 GHz, Acer Easystore, RAM 4 GB, 4 x 2TB hotswap drives, 1 x 2TB USB ext Clients: 2 x PC Clients, 1 x HD300, 2 x HD-200, 1 x HD-100 DEV Client: Win 7 Ultimate 64 bit - AMD 64 x2 6000+, Gigabyte GA-MA790GP-DS4H MB, RAM 4GB, HD OS:500GB, DATA:1 x 500GB, Pace RGN STB.
Reply With Quote
  #3  
Old 08-17-2011, 09:21 AM
troll5501 troll5501 is offline
Sage Advanced User
 
Join Date: Jun 2006
Posts: 136
Yes, and Sage seems to be trying to use the new values. From sagetv_0.log:

Code:
Wed 8/17 9:36:28.114 [AsyncWatch@31fb8e] V4L:  updateColors0 b=131 c=64 h=16 s=72
So I added some debugging to the hdpvr module to see what it's doing, and I got this:

Code:
Aug 17 09:36:28 sagelinux kernel: [125622.092095] hdpvr 1-7:1.0: Setting brightness to 134
Aug 17 09:36:28 sagelinux kernel: [125622.092103] hdpvr 1-7:1.0: Setting contrast to 128
Aug 17 09:36:28 sagelinux kernel: [125622.092108] hdpvr 1-7:1.0: Setting hue to 128
Aug 17 09:36:28 sagelinux kernel: [125622.092113] hdpvr 1-7:1.0: Setting saturation to 128
I'm not sure where the disconnect is. I can "fix" it by hardcoding my values in the module code and rebuilding it, but that's a kludgy solution.
__________________
Server: HP DL380 G6, VMware ESXi 5.0 with HW passthrough for USB and Firewire, 4 x HD-PVR, ZFS storage
SageTV: Production: 7.1.9+Java 1.6.0_32 on XP, Test: 9.0.4.291+Java 1.8.0_72 on Linux 64-bit
Clients: 2 x Sage HD200 Extender, 1 x Sage HD100 Extender
Sources: 4 x Motorola DCH-3200 (firewire channel changing), HD Homerun Prime, OpenDCT 0.5.7
Reply With Quote
  #4  
Old 09-18-2011, 07:10 AM
bcjenkins bcjenkins is offline
SageTVaholic
 
Join Date: Jan 2006
Posts: 3,764
Would you mind posting the patch for "fixing" the driver? I would like to try the new firmware as I have problems in recordings when going from HD -> SD -> HD transmissions on the cable box.

B
__________________
Running SageTV on unRAID via Docker
Tuning handled by HDHR3-6CC-3X2 using OpenDCT
Reply With Quote
  #5  
Old 09-20-2011, 05:57 AM
bcjenkins bcjenkins is offline
SageTVaholic
 
Join Date: Jan 2006
Posts: 3,764
Using the Generic Tuner plugin from jpwegas I can run v4l-ctl after a tune.

Code:
v4l2-ctl -d /dev/video2 --set-ctrl=brightness=128,hue=64,saturation=44,contrast=64,sharpness=96
I would still like to hard code these values and ignore this step.

B
__________________
Running SageTV on unRAID via Docker
Tuning handled by HDHR3-6CC-3X2 using OpenDCT
Reply With Quote
  #6  
Old 09-20-2011, 07:23 AM
drewg drewg is offline
Sage Icon
 
Join Date: Aug 2007
Location: Richmond, VA
Posts: 1,042
Quote:
Originally Posted by bcjenkins View Post
Using the Generic Tuner plugin from jpwegas I can run v4l-ctl after a tune.

Code:
v4l2-ctl -d /dev/video2 --set-ctrl=brightness=128,hue=64,saturation=44,contrast=64,sharpness=96
I would still like to hard code these values and ignore this step.

B
Ick, I hate having to hard-code things in modules.

Could you guys re-cycle my LD_PRELOAD hook that we used to intercept /dev/dvb recordings and increase the DMX buffer size? Eg, intercept the open(/dev/video..) and and add the appropriate ioctl to set the brightness / hue / etc. I guess this could be a problem if Sage later ioctls bad settings in, but you could also hook ioctl and close, and keep track of the /dev/video file descriptors, and either fixup Sage's ioctls or just skip them.

Drew
__________________
Server HW: AMD Ryzen Threadripper 2990WX 32-Core
Server SW: FreeBSD-current, ZFS, linux-oracle-jdk1.8.0, sagetv-server_9.2.2_amd64
Tuner HW: HDHR
Client: Nvidia Shield (HD300, HD100 in storage)
Reply With Quote
  #7  
Old 09-20-2011, 08:12 AM
bcjenkins bcjenkins is offline
SageTVaholic
 
Join Date: Jan 2006
Posts: 3,764
Quote:
Originally Posted by drewg View Post
Ick, I hate having to hard-code things in modules.

Could you guys re-cycle my LD_PRELOAD hook that we used to intercept /dev/dvb recordings and increase the DMX buffer size? Eg, intercept the open(/dev/video..) and and add the appropriate ioctl to set the brightness / hue / etc. I guess this could be a problem if Sage later ioctls bad settings in, but you could also hook ioctl and close, and keep track of the /dev/video file descriptors, and either fixup Sage's ioctls or just skip them.

Drew
That's Greek to me - could you provide a working example?

B
__________________
Running SageTV on unRAID via Docker
Tuning handled by HDHR3-6CC-3X2 using OpenDCT
Reply With Quote
  #8  
Old 09-20-2011, 08:25 AM
drewg drewg is offline
Sage Icon
 
Join Date: Aug 2007
Location: Richmond, VA
Posts: 1,042
Quote:
Originally Posted by bcjenkins View Post
That's Greek to me - could you provide a working example?

B
Probably not, since I don't have an HD-PVR.

I've attached the preload code I used before Qian fixed the buffer size issue. What it does is to intercept any calls to open(). It then checks to see if the open was to /dev/dvb/adapter*/dvr0. If it was, it issues a DVB ioctl to set the buffer size.

You'd want to modify the code to look for opens of /dev/video and to issue an ioctl to set the hue/color/etc.

The problem is that if sage later issues a bogus ioctl and resets the color. If that is the case, you'd also need to intercept ioctl, look for the ioctl that changes the color, and either ignore it, or replace the bogus values it is using with the correct values.


Drew
Attached Files
File Type: txt sage_preload.c.txt (2.2 KB, 264 views)
__________________
Server HW: AMD Ryzen Threadripper 2990WX 32-Core
Server SW: FreeBSD-current, ZFS, linux-oracle-jdk1.8.0, sagetv-server_9.2.2_amd64
Tuner HW: HDHR
Client: Nvidia Shield (HD300, HD100 in storage)
Reply With Quote
  #9  
Old 09-20-2011, 08:28 AM
drewg drewg is offline
Sage Icon
 
Join Date: Aug 2007
Location: Richmond, VA
Posts: 1,042
Wait a sec ... could this be a 32 bit bug in the HD-PVR drivers?

To troll5501: Are you using a 64-bit kernel? If yes, what happens if you try to set the color using a 32-bit version of v4l2-ctl? Do you see the same bad color? If so, then the bug is in the driver's handling of ioctls from 32-bit processes.

I *hate* that sagetv is 32-bit for this reason ... using 32-bit apps on 64-bit kernels is almost never tested by anybody.

Drew
__________________
Server HW: AMD Ryzen Threadripper 2990WX 32-Core
Server SW: FreeBSD-current, ZFS, linux-oracle-jdk1.8.0, sagetv-server_9.2.2_amd64
Tuner HW: HDHR
Client: Nvidia Shield (HD300, HD100 in storage)
Reply With Quote
  #10  
Old 10-25-2011, 01:59 PM
bcjenkins bcjenkins is offline
SageTVaholic
 
Join Date: Jan 2006
Posts: 3,764
There is a patch posted to the Linux Media list addressing this: http://www.mail-archive.com/linux-me.../msg38318.html

B
__________________
Running SageTV on unRAID via Docker
Tuning handled by HDHR3-6CC-3X2 using OpenDCT
Reply With Quote
  #11  
Old 01-05-2014, 10:50 AM
jchiso jchiso is offline
Sage Expert
 
Join Date: Nov 2003
Location: Columbus, OH
Posts: 674
I recently booted into Windows 8 on my system that runs my Linux server, and did the driver installation (and firmware update) for the HD-PVR. Now when I go back into Linux the encoder settings don't seem to have any effect. When I did a capture in Linux the contrast, brightness, etc. were all off, and I cannot re-set them by editing the Sage.properties file.

It seems that Linux is bypassing these settings and reading from the (new) firmware settings. Anyone know a way to overcome this, and force the Linux server to use a specific calibration set?
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
Can HD-PVR Brightness, Saturation, Contrast, etc. Be Controlled From Properties File? Savage1701 Hardware Support 30 08-21-2015 10:35 AM
Saturation By Channel jayrbrown77 SageTV Software 6 10-30-2006 08:48 PM
Problems setting Saturation, Hue, ect ldavis SageTV Recorder Software 1 08-09-2004 08:30 PM
How to adjust recording's levels, saturation, etc? Jack_PVR SageTV Software 4 05-31-2004 07:54 PM
Reducing saturation eswrite SageTV Recorder Software 1 10-07-2003 09:18 PM


All times are GMT -6. The time now is 05:08 PM.


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