README.QNX
author Sam Lantinga <slouken@libsdl.org>
Tue, 24 Mar 2009 10:33:12 +0000
changeset 3099 82e60908fab1
parent 3092 cad1aefa2ed9
child 3107 3cf236d3cd81
permissions -rw-r--r--
Date: Mon, 23 Mar 2009 09:17:24 +0200
From: "Mike Gorchak"
Subject: New QNX patches

Please apply patch qnx4.diff, which is attached. What has been done:
1)Added back OpenGL ES renderer for QNX target. Added few corrections to
OpenGL ES renderer to let it work under QNX. OpenGL ES renderer do not
support textures under QNX, so I think some additional work must be done.
2) Added GL_OES_query_matrix extension to SDL_opengles.h header file, which
required by OpenGL ES 1.1 specification.
3) Added attribute clearing at the entrance of function
SDL_GL_GetAttribure(). Added error checking into the function
SDL_GL_GetAttribure(), because some attributes can't be obtained in OpenGL
ES 1.0.
4) Porting testdyngles to OpenGL ES 1.0 (1.1 has glColor4ub() and
glColor4f() functions, but 1.0 has glColor4f() only).
5) Added error checking after obtaining attributes using
SDL_GL_GetAttribute() function to the testgl2 and testgles.
6) Small correction to testmultiaudio with printing errors.
7) Added software and accelerated OpenGL ES 1.0 support into the QNX GF
driver.

Please remove ./src/audio/nto directory - it will not be used anymore.
Please create ./src/audio/qsa directory and add content of the archive
qsa.tar.gz into this directory. I rewrote some sound code, added support for
multiple audio cards, enumeration, etc. Added initial support for capture.

As far as I can understand SDL 1.3 is not supporting audio capture right now
? Sam, Am I right ? Or audio capture must be supported through the
PlayDevice routine ?

And last, please put file SDL_gf_opengles.c to the ./src/video/qnxgf
directory. It is OpenGL ES 1.1 emulation layer for some functions, which are
not supported by OpenGL ES 1.0.
slouken@886
     1
README.QNX by Mike Gorchak <mike@malva.ua>, <lestat@i.com.ua>
slouken@3099
     2
Last changed at 22 Mar 2009.
slouken@753
     3
slouken@3099
     4
QNX Photon and GF drivers are being constructed.
slouken@3099
     5
QNX QSA (QNX Sound Architecture) driver is ready.
slouken@3099
     6
QNX CDROM driver is ready.
slouken@3099
     7
QNX HID input driver is being constructed.
slouken@3099
     8
slouken@3099
     9
----------------------
slouken@3099
    10
 -- SDL QSA driver --
slouken@3099
    11
----------------------
slouken@3099
    12
slouken@3099
    13
   Due to QNX Sound Architecture limitations software could  not  determine
slouken@3099
    14
what playback channels are designed for, so some casus can be. For example,
slouken@3099
    15
output after testmultiaudio test utility execution:
slouken@3099
    16
slouken@3099
    17
Using audio driver: qsa
slouken@3099
    18
playing on device #0: ('Vortex 8820 @ fb000000 d0')...done.
slouken@3099
    19
playing on device #1: ('Vortex 8820 @ fb000000 d1')...done.
slouken@3099
    20
playing on device #2: ('i8x0 @ d800 d0')...done.
slouken@3099
    21
playing on device #3: ('i8x0 @ d800 d1')...done.
slouken@3099
    22
playing on all devices...
slouken@3099
    23
Open device 3 failed: QSA: snd_pcm_channel_params failed: Invalid argument
slouken@3099
    24
slouken@3099
    25
If  speakers  are  connected  to  both  audio  cards: Vortex 8820 and Intel
slouken@3099
    26
Integrated Audio we can hear sound playback on device #0 and devices #2, #3
slouken@3099
    27
only. Device #1 is an unknown PCM channel which does not produce any sound.
slouken@3099
    28
slouken@3099
    29
As for error during device #3 opening, it's caused  by QSA  software  mixer
slouken@3099
    30
channel, because  it can't open real hardware device #2, since it's already
slouken@3099
    31
opened by SDL.
slouken@3099
    32
slouken@3099
    33
After simultaneous sound playback  on  all  devices  utility testmultiaudio
slouken@3099
    34
stays running waiting for  sound playback  finish  on  device #1,  which is
slouken@3099
    35
locked up due to some Aureal Vortex 8820 driver limitations.
slouken@3092
    36
slouken@3092
    37
---------------------
slouken@3092
    38
 -- SDL GF driver --
slouken@3092
    39
---------------------
slouken@3092
    40
slouken@3092
    41
Here is an additional information about SDL GF driver:
slouken@3092
    42
 * 0. Introduction.
slouken@3092
    43
 * 1. Environment variables which SDL GF driver supports.
slouken@3092
    44
 * 2. Custom video modes.
slouken@3092
    45
 * 3. Limitations.
slouken@3092
    46
slouken@3092
    47
0. Introduction.
slouken@3092
    48
slouken@3099
    49
   SDL GF driver is a layer between  SDL  and  QNX Graphics Framework (GF).
slouken@3099
    50
SDL GF driver also supports OpenGL ES  through the  QNX Graphics Framework.
slouken@3099
    51
Hardware accelerated features which SDL can support depend on real hardware
slouken@3099
    52
capabilities.
slouken@3092
    53
slouken@3092
    54
1. Environment variables which GF driver supports.
slouken@3092
    55
slouken@3099
    56
   GF  driver  supports  the  following  environment  variables for  QNX GF
slouken@3099
    57
specific customization options:
slouken@3099
    58
   a) SDL_VIDEO_GF_REFRESH_RATE - refresh  rate  of  video  output  in  Hz.
slouken@3099
    59
      Without this environment variable declaration  SDL  controls  refresh
slouken@3099
    60
      rate of your display.  If this enironment  variable is set  to 0, SDL
slouken@3099
    61
      will control  refresh  rate  of  display,  otherwise  value  of  flag
slouken@3099
    62
      SDL_VIDEO_GF_REFRESH_RATE  is  used  for  all  screen  resolutions as
slouken@3099
    63
      refresh rate. This example will set 60Hz refresh rate as refresh rate
slouken@3099
    64
      for all graphics modes:
slouken@3092
    65
slouken@3092
    66
      export SDL_VIDEO_GF_REFRESH_RATE=60
slouken@3092
    67
slouken@3092
    68
2. Custom video modes.
slouken@3092
    69
slouken@3099
    70
   Since most QNX graphics drivers support GENERIC  video  modes, i.e.  you
slouken@3099
    71
can specify any horizontal and vertical resolution and  any  refresh  rate,
slouken@3099
    72
SDL GF driver uses its own fullscreen modes list, which can be  incomplete.
slouken@3099
    73
You can add any custom video mode, which your QNX graphics driver  supports
slouken@3099
    74
by  editing  file  ./src/video/qnxgf/SDL_qnxgf.c.   Custom   graphics  mode
slouken@3099
    75
definition looks like this:
slouken@3092
    76
slouken@3099
    77
   {0, 1024, 640, 60, NULL},   /* 1024x640 mode is 60Hz only             */
slouken@3092
    78
slouken@3099
    79
You must specify horizontal resolution as  the  second  parameter, vertical
slouken@3099
    80
resolution as the third one and  refresh  rate  as  the  fourth  parameter.
slouken@3099
    81
Please leave the first and the last parameters as 0 and NULL.  Then send me
slouken@3099
    82
your changes to e-mail address which is specified in  the  header  of  this
slouken@3099
    83
document.
slouken@3092
    84
slouken@3092
    85
3. Limitations.
slouken@3092
    86
slouken@3092
    87
   There are few limitations while using SDL GF driver:
slouken@3092
    88
slouken@3099
    89
   a) Since  GF   driver   supports   fullscreen  modes  only,   when  flag
slouken@3099
    90
SDL_WINDOW_FULLSCREEN is not specified, SDL GF driver will try to find  the
slouken@3099
    91
fullscreen graphics mode which corresponds to SDL window size. Refresh rate
slouken@3099
    92
will be the  lowest  available,  if  SDL_VIDEO_GF_REFRESH_RATE  environment
slouken@3099
    93
variable is not set.
slouken@3099
    94
   b) As confirmed by QSSL none of existing video  drivers  has  support of
slouken@3099
    95
doublescan low-resolution video modes.  So  modes  below  640x480  are  not
slouken@3099
    96
supported. If your video driver supports low-resolution video modes, please
slouken@3099
    97
add SDL_GF_LOWRESOLUTION flag to the gf_devicename array in the SDL_qnxgf.c
slouken@3099
    98
source file.
slouken@3092
    99
slouken@3099
   100
-------------------------
slouken@3099
   101
 -- SDL Photon driver --
slouken@3099
   102
-------------------------
slouken@3099
   103
slouken@3099
   104
----------------------------
slouken@3099
   105
 -- SDL HID input driver --
slouken@3099
   106
----------------------------