TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: STEVEN DYCK
from: JERRY COFFIN
date: 1997-06-24 09:42:00
subject: pictures and sound

On (23 Jun 97) Steven Dyck wrote to All...
 SD> Being that no one has answered my question, it means one of three
 SD> things: no one know how, it is not possible, or I haven't waited long
 SD> enough.
Hmm...I think this is the first time I've seen your question.
 SD> BTW, my questions were how to load a picture into a program and how to
 SD> play music in c++ (or c).
Loading a picture depends greatly upon the format of picture file you
want to load.  Loading things like PCX and BMP files is pretty simple.
Loading things like JPEG files is fairly complex.  It's possible to
write code for almost any file format in C, but I'd reccomend looking
around for pre-written libraries for this if possible - they'll
generally let you get things done more quickly and easily.
Sound is much the same way - you have a half dozen or so different file
formats, and a about the same number of different synthesizer chips and
such.  If you want, you can write code to read almost any file format
and get the synthesizer to play it.  Unless you're somewhat masochistic,
you're probably best off using one of the _many_ libraries to handle the
details.
It's almost impossible to make any more specific statements without
knowing the file formats and hardware you're interested in using.  For
instance, playing music over MIDI is a LOT different from playing music
over the built-in loudspeaker on a PC.
    Later,
    Jerry.
... The Universe is a figment of its own imagination.
--- PPoint 1.90
---------------
* Origin: Point Pointedly Pointless (1:128/166.5)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.