PageRenderTime 52ms CodeModel.GetById 39ms app.highlight 10ms RepoModel.GetById 1ms app.codeStats 0ms

/xbmc/settings/VideoSettings.cpp

http://github.com/xbmc/xbmc
C++ | 88 lines | 58 code | 5 blank | 25 comment | 50 complexity | abbe4527f55ccc72632af9624619d780 MD5 | raw file
 1/*
 2 *      Copyright (C) 2005-2013 Team XBMC
 3 *      http://xbmc.org
 4 *
 5 *  This Program is free software; you can redistribute it and/or modify
 6 *  it under the terms of the GNU General Public License as published by
 7 *  the Free Software Foundation; either version 2, or (at your option)
 8 *  any later version.
 9 *
10 *  This Program is distributed in the hope that it will be useful,
11 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
12 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 *  GNU General Public License for more details.
14 *
15 *  You should have received a copy of the GNU General Public License
16 *  along with XBMC; see the file COPYING.  If not, see
17 *  <http://www.gnu.org/licenses/>.
18 *
19 */
20// VideoSettings.cpp: implementation of the CVideoSettings class.
21//
22//////////////////////////////////////////////////////////////////////
23
24#include "VideoSettings.h"
25
26//////////////////////////////////////////////////////////////////////
27// Construction/Destruction
28//////////////////////////////////////////////////////////////////////
29
30CVideoSettings::CVideoSettings()
31{
32  m_InterlaceMethod = VS_INTERLACEMETHOD_AUTO;
33  m_ScalingMethod = VS_SCALINGMETHOD_LINEAR;
34  m_ViewMode = ViewModeNormal;
35  m_CustomZoomAmount = 1.0f;
36  m_CustomPixelRatio = 1.0f;
37  m_CustomVerticalShift = 0.0f;
38  m_CustomNonLinStretch = false;
39  m_AudioStream = -1;
40  m_SubtitleStream = -1;
41  m_SubtitleDelay = 0.0f;
42  m_SubtitleOn = true;
43  m_SubtitleCached = false;
44  m_Brightness = 50.0f;
45  m_Contrast = 50.0f;
46  m_Gamma = 20.0f;
47  m_Sharpness = 0.0f;
48  m_NoiseReduction = 0;
49  m_PostProcess = false;
50  m_VolumeAmplification = 0;
51  m_AudioDelay = 0.0f;
52  m_OutputToAllSpeakers = false;
53  m_ResumeTime = 0;
54  m_StereoMode = 0;
55  m_StereoInvert = false;
56  m_VideoStream = -1;
57
58}
59
60bool CVideoSettings::operator!=(const CVideoSettings &right) const
61{
62  if (m_InterlaceMethod != right.m_InterlaceMethod) return true;
63  if (m_ScalingMethod != right.m_ScalingMethod) return true;
64  if (m_ViewMode != right.m_ViewMode) return true;
65  if (m_CustomZoomAmount != right.m_CustomZoomAmount) return true;
66  if (m_CustomPixelRatio != right.m_CustomPixelRatio) return true;
67  if (m_CustomVerticalShift != right.m_CustomVerticalShift) return true;
68  if (m_CustomNonLinStretch != right.m_CustomNonLinStretch) return true;
69  if (m_AudioStream != right.m_AudioStream) return true;
70  if (m_SubtitleStream != right.m_SubtitleStream) return true;
71  if (m_SubtitleDelay != right.m_SubtitleDelay) return true;
72  if (m_SubtitleOn != right.m_SubtitleOn) return true;
73  if (m_SubtitleCached != right.m_SubtitleCached) return true;
74  if (m_Brightness != right.m_Brightness) return true;
75  if (m_Contrast != right.m_Contrast) return true;
76  if (m_Gamma != right.m_Gamma) return true;
77  if (m_Sharpness != right.m_Sharpness) return true;
78  if (m_NoiseReduction != right.m_NoiseReduction) return true;
79  if (m_PostProcess != right.m_PostProcess) return true;
80  if (m_VolumeAmplification != right.m_VolumeAmplification) return true;
81  if (m_AudioDelay != right.m_AudioDelay) return true;
82  if (m_OutputToAllSpeakers != right.m_OutputToAllSpeakers) return true;
83  if (m_ResumeTime != right.m_ResumeTime) return true;
84  if (m_StereoMode != right.m_StereoMode) return true;
85  if (m_StereoInvert != right.m_StereoInvert) return true;
86  if (m_VideoStream != right.m_VideoStream) return true;
87  return false;
88}