예제 #1
0
 void NaClGLSupport::addConfig(void)
 {
     LogManager::getSingleton().logMessage("\tGLSupport addConfig called");
     
     // Currently no config options supported
     refreshConfig();
 }
예제 #2
0
 void EGLSupport::setConfigOption(const String &name, const String &value)
 {
     GLESSupport::setConfigOption(name, value);
     if (name == "Video Mode")
     {
         refreshConfig();
     }
 }
예제 #3
0
PlayListWidget::PlayListWidget(QWidget* parent) : QTreeWidget(parent){
// 	qDebug() << this << "constructor()";
	setRootIsDecorated(false);
	setSortingEnabled(false);
	setAcceptDrops(true);
	setDragEnabled(true);
	setItemsExpandable(false);
	setTabKeyNavigation(false);
	setSelectionMode(QAbstractItemView::ExtendedSelection);
	setAlternatingRowColors(true);
	setAllColumnsShowFocus(true);
	setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
	setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOn);

	header()->setContextMenuPolicy(Qt::CustomContextMenu);
	connect(
		header(),	SIGNAL(customContextMenuRequested(const QPoint&)),
		this,		SLOT(headerContextMenu(const QPoint&))
	);

	QStringList headerLabels;
	headerLabels << "*" << "Artist" << "Album" << "Title"  << "Date" << "Genre"<< "Track No." << "Length";
	setHeaderLabels(headerLabels);

	tabs=(PlayListTabs*) parentWidget();

	dropPointer=new DropPointer(this);
	dropPointer->hide();
	dropPointer->setWidth(visibleWidth());
	dropPointer->moveTo(0);

	refreshConfig();

	connectConfigUpdate();

	connect(
		this, SIGNAL(itemDoubleClicked(QTreeWidgetItem*,int)),
		this, SLOT(doubleClicked(QTreeWidgetItem*,int))
	);
	connect(
		this,	SIGNAL(playItem(PlayListItem*)),
		tabs,	SLOT(playItem(PlayListItem*))
	);
	connect(
		this, SIGNAL(itemDoubleClicked(QTreeWidgetItem*,int)),
		this, SLOT(deselect(QTreeWidgetItem*,int))
	);

	connect(
		verticalScrollBar(),	SIGNAL(valueChanged(int)),
		this,					SLOT(printPos(int))
	);

	firstShow=true;
	scrollPosition=0;
}
예제 #4
0
void deviceConfigHandleRawData(char header,
        InputStream* inputStream,
        OutputStream* outputStream) {
    if (header == COMMAND_CONFIG) {
        // Send ack first
        appendAck(outputStream);

        // can take a little time
        refreshConfig();
        append(outputStream, COMMAND_CONFIG);
        appendHex4(outputStream, config);
    }
}
예제 #5
0
/**
 * Returns a String corresponding to the configuration
 * '1' when the bit is set, '0' when not set
 */
void appendStringConfig(OutputStream* outputStream) {
    refreshConfig();
    signed int i;
    for (i = CONFIG_BIT_COUNT - 1; i >= 0; i--) {
        char c;
		if ((config & (1 << i)) > 0) {
			c = '1';
		}
        else {
            c = '0';
		}
	    append(outputStream, c);
    }
}
예제 #6
0
	//-------------------------------------------------------------------------------------------------//
	void GLXGLSupport::setConfigOption(const String &name, const String &value)
	{
		ConfigOptionMap::iterator option = mOptions.find(name);
		
		if(option == mOptions.end())
		{
			OGRE_EXCEPT( Exception::ERR_INVALIDPARAMS, "Option named " + name + " does not exist.", "GLXGLSupport::setConfigOption" );
		}
		else
		{
			option->second.currentValue = value;
		}
		
		if (name == "Video Mode")
		{
			ConfigOptionMap::iterator opt;
			if((opt = mOptions.find("Full Screen")) != mOptions.end())
			{
				if (opt->second.currentValue == "Yes")
					refreshConfig();
			}
		}
	}
예제 #7
0
    void EGLSupport::addConfig(void)
    {
        ConfigOption optFullScreen;
        ConfigOption optVideoMode;
        ConfigOption optDisplayFrequency;
        ConfigOption optFSAA;
        ConfigOption optRTTMode;

        optFullScreen.name = "Full Screen";
        optFullScreen.immutable = false;

        optVideoMode.name = "Video Mode";
        optVideoMode.immutable = false;

        optDisplayFrequency.name = "Display Frequency";
        optDisplayFrequency.immutable = false;

        optFSAA.name = "FSAA";
        optFSAA.immutable = false;

        optRTTMode.name = "RTT Preferred Mode";
        optRTTMode.immutable = false;

        optFullScreen.possibleValues.push_back("No");
        optFullScreen.possibleValues.push_back("Yes");

        optFullScreen.currentValue = optFullScreen.possibleValues[1];

        VideoModes::const_iterator value = mVideoModes.begin();
        VideoModes::const_iterator end = mVideoModes.end();

        for (; value != end; value++)
        {
            String mode = StringConverter::toString(value->first.first,4) + " x " + StringConverter::toString(value->first.second,4);
            optVideoMode.possibleValues.push_back(mode);
        }
        removeDuplicates(optVideoMode.possibleValues);

        optVideoMode.currentValue = StringConverter::toString(mCurrentMode.first.first,4) + " x " + StringConverter::toString(mCurrentMode.first.second,4);

        refreshConfig();
        if (!mSampleLevels.empty())
        {
            StringVector::const_iterator value = mSampleLevels.begin();
            StringVector::const_iterator end = mSampleLevels.end();

            for (; value != end; value++)
            {
                optFSAA.possibleValues.push_back(*value);
            }

            optFSAA.currentValue = optFSAA.possibleValues[0];
        }

        optRTTMode.possibleValues.push_back("Copy");
        optRTTMode.currentValue = optRTTMode.possibleValues[0];

        mOptions[optFullScreen.name] = optFullScreen;
        mOptions[optVideoMode.name] = optVideoMode;
        mOptions[optDisplayFrequency.name] = optDisplayFrequency;
        mOptions[optFSAA.name] = optFSAA;
        mOptions[optRTTMode.name] = optRTTMode;

        refreshConfig();
    }
예제 #8
0
unsigned char isConfigBalise() {
    refreshConfig();
    return isConfigSet(CONFIG_USE_BALISE_MASK);
}
예제 #9
0
int isConfigSet(unsigned int configMask) {
	refreshConfig();
	int intersection = (config & configMask);
    return intersection != 0;
}
예제 #10
0
unsigned int getConfigValue(void) {
    refreshConfig();
    return config;
}
예제 #11
0
BOOL isConfigDeviceOk(void) {
    refreshConfig();
    return getConfigValue() < MAX_UNSIGNEDINT;
}
예제 #12
0
void initConfig(void) {
    refreshConfig();
}
예제 #13
0
unsigned char getStrategy() {
    refreshConfig();
    return config & CONFIG_STRATEGY_MASK;
}
예제 #14
0
	//-------------------------------------------------------------------------------------------------//
	void GLXGLSupport::addConfig(void) 
	{
		ConfigOption optFullScreen;
		ConfigOption optVideoMode;
		ConfigOption optDisplayFrequency;
		ConfigOption optVSync;
		ConfigOption optFSAA;
		ConfigOption optRTTMode;
		ConfigOption optSRGB;
#ifdef RTSHADER_SYSTEM_BUILD_CORE_SHADERS
		ConfigOption optEnableFixedPipeline;
#endif
		
		optFullScreen.name = "Full Screen";
		optFullScreen.immutable = false;
		
		optVideoMode.name = "Video Mode";
		optVideoMode.immutable = false;
		
		optDisplayFrequency.name = "Display Frequency";
		optDisplayFrequency.immutable = false;
		
		optVSync.name = "VSync";
		optVSync.immutable = false;
		
		optFSAA.name = "FSAA";
		optFSAA.immutable = false;
		
		optRTTMode.name = "RTT Preferred Mode";
		optRTTMode.immutable = false;
		
		optSRGB.name = "sRGB Gamma Conversion";
		optSRGB.immutable = false;

#ifdef RTSHADER_SYSTEM_BUILD_CORE_SHADERS
		optEnableFixedPipeline.name = "Fixed Pipeline Enabled";
		optEnableFixedPipeline.possibleValues.push_back( "Yes" );
		optEnableFixedPipeline.possibleValues.push_back( "No" );
		optEnableFixedPipeline.currentValue = "Yes";
		optEnableFixedPipeline.immutable = false;
#endif

		optFullScreen.possibleValues.push_back("No");
		optFullScreen.possibleValues.push_back("Yes");
		
		optFullScreen.currentValue = optFullScreen.possibleValues[1];
		
		VideoModes::const_iterator value = mVideoModes.begin();
		VideoModes::const_iterator end = mVideoModes.end();
		
		for (; value != end; value++)
		{
			String mode = StringConverter::toString(value->first.first,4) + " x " + StringConverter::toString(value->first.second,4);
			
			optVideoMode.possibleValues.push_back(mode);
		}
		
		remove_duplicates(optVideoMode.possibleValues);
		
		optVideoMode.currentValue = StringConverter::toString(mCurrentMode.first.first,4) + " x " + StringConverter::toString(mCurrentMode.first.second,4);
		
		refreshConfig();
		
		if (GLXEW_SGI_swap_control)
		{
			optVSync.possibleValues.push_back("No");
			optVSync.possibleValues.push_back("Yes");
			
			optVSync.currentValue = optVSync.possibleValues[0];
		}
		
		// Is it worth checking for GL_EXT_framebuffer_object ?
		optRTTMode.possibleValues.push_back("FBO");
		
		if (GLXEW_VERSION_1_3)
		{
			optRTTMode.possibleValues.push_back("PBuffer");
		}
		
		optRTTMode.possibleValues.push_back("Copy");
		
		optRTTMode.currentValue = optRTTMode.possibleValues[0];
		
		if (! mSampleLevels.empty())
		{
			StringVector::const_iterator value = mSampleLevels.begin();
			StringVector::const_iterator end = mSampleLevels.end();
			
			for (; value != end; value++)
			{
				optFSAA.possibleValues.push_back(*value);
			}
			
			optFSAA.currentValue = optFSAA.possibleValues[0];
		}
		
		if (GLXEW_EXT_framebuffer_sRGB)
		{	
			optSRGB.possibleValues.push_back("No");
			optSRGB.possibleValues.push_back("Yes");

			optSRGB.currentValue = optSRGB.possibleValues[0];
		}

		mOptions[optFullScreen.name] = optFullScreen;
		mOptions[optVideoMode.name] = optVideoMode;
		mOptions[optDisplayFrequency.name] = optDisplayFrequency;
		mOptions[optVSync.name] = optVSync;
		mOptions[optRTTMode.name] = optRTTMode;
		mOptions[optFSAA.name] = optFSAA;
		mOptions[optSRGB.name] = optSRGB;
#ifdef RTSHADER_SYSTEM_BUILD_CORE_SHADERS
		mOptions[optEnableFixedPipeline.name] = optEnableFixedPipeline;
#endif
		
		refreshConfig();
	}
예제 #15
0
    //-------------------------------------------------------------------------------------------------//
    void GLXGLSupport::addConfig(void)
    {
        ConfigOption optFullScreen;
        ConfigOption optVideoMode;
        ConfigOption optDisplayFrequency;
        ConfigOption optVSync;
        ConfigOption optFSAA;
        ConfigOption optRTTMode;
        ConfigOption optSRGB;
        ConfigOption optEnableFixedPipeline;

        optFullScreen.name = "Full Screen";
        optFullScreen.immutable = false;

        optVideoMode.name = "Video Mode";
        optVideoMode.immutable = false;

        optDisplayFrequency.name = "Display Frequency";
        optDisplayFrequency.immutable = false;

        optVSync.name = "VSync";
        optVSync.immutable = false;

        optFSAA.name = "FSAA";
        optFSAA.immutable = false;

        optRTTMode.name = "RTT Preferred Mode";
        optRTTMode.immutable = false;

        optSRGB.name = "sRGB Gamma Conversion";
        optSRGB.immutable = false;

        optEnableFixedPipeline.name = "Fixed Pipeline Enabled";
        optEnableFixedPipeline.possibleValues.push_back( "Yes" );
        optEnableFixedPipeline.possibleValues.push_back( "No" );
        optEnableFixedPipeline.currentValue = "Yes";
        optEnableFixedPipeline.immutable = false;

        optFullScreen.possibleValues.push_back("No");
        optFullScreen.possibleValues.push_back("Yes");

        optFullScreen.currentValue = optFullScreen.possibleValues[1];

        VideoModes::const_iterator value = mVideoModes.begin();
        VideoModes::const_iterator end = mVideoModes.end();

        for (; value != end; value++)
        {
            String mode = StringConverter::toString(value->first.first,4) + " x " + StringConverter::toString(value->first.second,4);

            optVideoMode.possibleValues.push_back(mode);
        }

        remove_duplicates(optVideoMode.possibleValues);

        optVideoMode.currentValue = StringConverter::toString(mCurrentMode.first.first,4) + " x " + StringConverter::toString(mCurrentMode.first.second,4);

        refreshConfig();

        optVSync.possibleValues.push_back("No");
        optVSync.possibleValues.push_back("Yes");
        optVSync.currentValue = optVSync.possibleValues[0];

        optRTTMode.possibleValues.push_back("FBO");
        optRTTMode.currentValue = optRTTMode.possibleValues[0];

        if (! mSampleLevels.empty())
        {
            StringVector::const_iterator sampleLevel = mSampleLevels.begin();

            for (; sampleLevel != mSampleLevels.end(); sampleLevel++)
            {
                optFSAA.possibleValues.push_back(*sampleLevel);
            }

            optFSAA.currentValue = optFSAA.possibleValues[0];
        }

        optSRGB.possibleValues.push_back("No");
        optSRGB.possibleValues.push_back("Yes");

        optSRGB.currentValue = optSRGB.possibleValues[0];

        mOptions[optFullScreen.name] = optFullScreen;
        mOptions[optVideoMode.name] = optVideoMode;
        mOptions[optDisplayFrequency.name] = optDisplayFrequency;
        mOptions[optVSync.name] = optVSync;
        mOptions[optRTTMode.name] = optRTTMode;
        mOptions[optFSAA.name] = optFSAA;
        mOptions[optSRGB.name] = optSRGB;
        mOptions[optEnableFixedPipeline.name] = optEnableFixedPipeline;

        refreshConfig();
    }