Subloading and formating textures

New Message Reply Date view Thread view Subject view Author view

gthomas++at++icaen.uiowa.edu
Mon, 14 Apr 1997 13:34:15 -0500 (CDT)


Performers.

I wonder if you can help me understand how to best subload textures in my
multiprocess application.

I'm modifying Perfly so that I can load a live stream of images into one
of the textures. I've got the steam up and running, its getting the
images
into the textures that poses the problem.

Because each image takes some time to process, I've broken that work off
into
a localDBaseFunction process. There I define the texture and put it into a
texture buffer called ViewState->nextTexture that has global scope:

> ViewState->nextTexture->getImage(&ibuf, &nc, &sx, &sy, &sz);
> getNextImage( (unsigned char *) ibuf, sx, sy, nc,
ViewState->imageList[rep] );
> ViewState->nextTexture->setImage(ibuf, nc, sx, sy, 1);
> ViewState->nextTexture->format();

In a localPostDraw function, I subload nextTexture into the first element
of
the textureList that was so kindly set up and loaded when the application
began:

> tex = (pfTexture *) list->get(0);
> ViewState->nextTexture->getImage(&image, &nc, &xsize, &ysize, &sz);
> tex->subload(PFTEX_SOURCE_IMAGE, image, 0, 0, 0, 0, 512, 512);
  
Now here's the killer. This application works and the texture changes if
I run everything as a single process on my O2. If I fork off the dataBase
function, the application crashes and burns with the message:

PF Fatal/SysErr: _pfDirtCheck: pfRealloc of 0 bytes returned NULL.
PF Notice(11): Caught SIGCHLD. Exiting due to death of child with
pid 6514

Well, well, I think. I can not format the image in the dbasefunction. So
I move the format call to the draw function. In single processing mode it
is as if I'm not touching the texture. In multiprocessing mode I get the
following complaint with each draw attempt:

PF Notice/Usage: OpenGL Error 0x501 - invalid value

I'm really stuck and need to get this up and running in multi-processing
mode
by Friday. Can you help?

Other relevant info is: I'm running Performer 2.0 on an O2. My hinv is:
Video: MVP unit 0 version 1.2
AV: AV1 Card version 1, O2Cam type 1 version 0 connected.
FLASH PROM version 4.0
On-board serial ports: 2
On-board EPP/ECP parallel port
1 180 MHZ IP32 Processor
FPU: MIPS R5000 Floating Point Coprocessor Revision: 1.0
CPU: MIPS R5000 Processor Chip Revision: 2.1
Data cache size: 32 Kbytes
Instruction cache size: 32 Kbytes
Secondary unified instruction/data cache size: 512 Kbytes on Processor 0
Main memory size: 64 Mbytes
Iris Audio Processor: version A3 revision 15
Integral Ethernet: ec0, version 1
  Tape drive: unit 7 on SCSI controller 1: DAT
  CDROM: unit 4 on SCSI controller 0
  Disk drive: unit 1 on SCSI controller 0
CRM graphics installed
Integral SCSI controller 1: Version ADAPTEC 7880
Integral SCSI controller 0: Version ADAPTEC 7880
Vice: DX

The format of the images are:
Internal Format TX_RGB_5, full speed
External Format TX_PACK_8
Not a detail Texture
Not a gen_mipmap Texture
A subload format Texture

Thanks in advance for any help you can offer.

- Geb

-- 
Dr. Geb Thomas                   
The GROK Lab Industrial Engineering           (o)  (319) 335-5936
The University of Iowa           (f)  (319) 335-5424
=======================================================================
List Archives, FAQ, FTP:  http://www.sgi.com/Technology/Performer/
            Submissions:  info-performer++at++sgi.com
        Admin. requests:  info-performer-request++at++sgi.com

New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:55:03 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.