/[svn]/linuxsampler/trunk/src/common/Features.h
ViewVC logotype

Annotation of /linuxsampler/trunk/src/common/Features.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1723 - (hide annotations) (download) (as text)
Sun Apr 20 08:53:39 2008 UTC (12 years, 2 months ago) by schoenebeck
File MIME type: text/x-c++hdr
File size: 2439 byte(s)
* allow pan control of engine channels on C++ API level
* export denormals-are-zero mode feature to C++ API

1 schoenebeck 320 /***************************************************************************
2     * *
3     * LinuxSampler - modular, streaming capable sampler *
4     * *
5     * Copyright (C) 2003, 2004 by Benno Senoner and Christian Schoenebeck *
6 schoenebeck 1723 * Copyright (C) 2005 - 2008 Christian Schoenebeck *
7 schoenebeck 320 * *
8     * This program is free software; you can redistribute it and/or modify *
9     * it under the terms of the GNU General Public License as published by *
10     * the Free Software Foundation; either version 2 of the License, or *
11     * (at your option) any later version. *
12     * *
13     * This program is distributed in the hope that it will be useful, *
14     * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16     * GNU General Public License for more details. *
17     * *
18     * You should have received a copy of the GNU General Public License *
19     * along with this program; if not, write to the Free Software *
20     * Foundation, Inc., 59 Temple Place, Suite 330, Boston, *
21     * MA 02111-1307 USA *
22     ***************************************************************************/
23    
24     #ifndef __FEATURES_H__
25     #define __FEATURES_H__
26    
27 schoenebeck 1424 #include "global_private.h"
28 schoenebeck 320
29     /**
30     * Detects system / CPU specific features at runtime.
31     */
32     class Features {
33     public:
34 schoenebeck 579 static void detect();
35 schoenebeck 1723 static bool enableDenormalsAreZeroMode();
36 schoenebeck 579 static String featuresAsString();
37 schoenebeck 320
38 schoenebeck 617 #if CONFIG_ASM && ARCH_X86
39 schoenebeck 320 inline static bool supportsMMX() { return bMMX; }
40     inline static bool supportsSSE() { return bSSE; }
41 persson 425 inline static bool supportsSSE2() { return bSSE2; }
42 schoenebeck 617 #endif // CONFIG_ASM && ARCH_X86
43 schoenebeck 320 private:
44 schoenebeck 617 #if CONFIG_ASM && ARCH_X86
45 schoenebeck 320 static bool bMMX;
46     static bool bSSE;
47 persson 425 static bool bSSE2;
48 schoenebeck 617 #endif // CONFIG_ASM && ARCH_X86
49 schoenebeck 320 };
50    
51     #endif // __FEATURES_H__

  ViewVC Help
Powered by ViewVC