summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/tests/AVStreams/mpeg
diff options
context:
space:
mode:
authorlevine <levine@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-10-20 02:34:57 +0000
committerlevine <levine@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-10-20 02:34:57 +0000
commit5c1001ce4f585836e1f83c28d1df89aee42fb743 (patch)
tree5967e9ca7d44ed1d2823be9746817ebb8e025f5d /TAO/orbsvcs/tests/AVStreams/mpeg
parent2ae14b2b85ad813a269e8a5529aa76cf984fa8a5 (diff)
downloadATCD-5c1001ce4f585836e1f83c28d1df89aee42fb743.tar.gz
changed include protection from #if !defined to ifndef, and added #pragma once, if possible
Diffstat (limited to 'TAO/orbsvcs/tests/AVStreams/mpeg')
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/include/common.h248
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h14
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h370
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/dither.h6
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h10
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h14
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/global.h30
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mibload.h86
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/newproto.h30
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/proto.h10
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ui.h6
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.h24
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/video.h38
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibload.h90
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibwidgets.h68
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_State.h17
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_i.h18
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Server.h23
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Globals.h145
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_State.h65
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_i.h12
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Server.h57
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/server_proto.h40
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/com.h84
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/fileio.h32
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/filters.h36
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/routine.h32
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h34
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Machine_Properties.h24
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Property_Exporter.h144
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Video_Repository.h33
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/as.h25
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/augmented_server.h65
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h43
-rw-r--r--TAO/orbsvcs/tests/AVStreams/mpeg/source/server/vs.h25
35 files changed, 1038 insertions, 960 deletions
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/include/common.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/include/common.h
index 2708154c055..140ba26e82c 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/include/common.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/include/common.h
@@ -1,33 +1,37 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
* Department of Computer Science and Engineering
* email: scen@cse.ogi.edu
*/
-#if !defined (_MPEG_COMMON_H)
+#ifndef _MPEG_COMMON_H
#define _MPEG_COMMON_H
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
extern int gethostname (char*, size_t);
#define VERSION 200 /* version 2.00 */
@@ -45,19 +49,19 @@ extern int gethostname (char*, size_t);
/*
#define LOG_DIR "/home/shanweic/log/"
-#define DEVELOPER_UID 8640
+#define DEVELOPER_UID 8640
*/
/* %% this is where the logging is done.." */
#define LOG_DIR "./"
-#define DEVELOPER_UID 1735
+#define DEVELOPER_UID 1735
-#define SFprintf if ((!getuid()) || getuid() == DEVELOPER_UID) fprintf
-#define Fprintf if (shared->config.verbose) fprintf
+#define SFprintf if ((!getuid()) || getuid() == DEVELOPER_UID) fprintf
+#define Fprintf if (shared->config.verbose) fprintf
-#define VCR_TCP_PORT 7101
-#define VCR_UNIX_PORT "/tmp/vcr_unix_port01"
-#define VCR_ATM_PORT "3005"
+#define VCR_TCP_PORT 7101
+#define VCR_UNIX_PORT "/tmp/vcr_unix_port01"
+#define VCR_ATM_PORT "3005"
#define SPEEDUP_INV_SCALE 5 /* VS fast starts at 5/(5-1) normal speed */
@@ -71,15 +75,15 @@ extern int gethostname (char*, size_t);
#define VD_BUF_SIZE (1024 * 1024) /* Size of client VD buffer */
-#define PATH_SIZE 256
-#define PATTERN_SIZE 100
-#define MAX_FRAMES 54000 /* half hour video at 30FPS */
+#define PATH_SIZE 256
+#define PATTERN_SIZE 100
+#define MAX_FRAMES 54000 /* half hour video at 30FPS */
#define MAX_VDQUEUE_SIZE 20
-#define MAX_FB_PACKETS 20 /* max number of feedback packet info collected. */
-#define POSITION_RANGE 100
-#define MSGGAP_MIN -10 /* these are used for recording stat of
- msgs received by VB */
-#define MSGGAP_MAX 50
+#define MAX_FB_PACKETS 20 /* max number of feedback packet info collected. */
+#define POSITION_RANGE 100
+#define MSGGAP_MIN -10 /* these are used for recording stat of
+ msgs received by VB */
+#define MSGGAP_MAX 50
#define INET_SOCKET_BUFFER_SIZE 1400
@@ -94,14 +98,14 @@ extern int gethostname (char*, size_t);
/* Video and audio compression format */
-#define VIDEO_MPEG1 0
-#define VIDEO_MPEG2 1
-#define VIDEO_JPEG 3
-#define VIDEO_SIF 4
+#define VIDEO_MPEG1 0
+#define VIDEO_MPEG2 1
+#define VIDEO_JPEG 3
+#define VIDEO_SIF 4
-#define AUDIO_RAW 10
-#define AUDIO_MPEG1 11
-#define AUDIO_MPEG2 12
+#define AUDIO_RAW 10
+#define AUDIO_MPEG1 11
+#define AUDIO_MPEG2 12
/* system configuration default values */
@@ -130,10 +134,10 @@ extern int gethostname (char*, size_t);
typedef struct
{
- int encodeType;
- int channels;
- int samplesPerSecond;
- int bytesPerSample;
+ int encodeType;
+ int channels;
+ int samplesPerSecond;
+ int bytesPerSample;
} AudioParameter;
/* client processes shared data structure definition */
@@ -145,14 +149,14 @@ typedef struct
char * VBbufAddr, * VDbufAddr;
int pixelValid;
unsigned char pixel[256]; /* for transfering pixel value from VP to VD */
-
+
/* command and status */
int cmd;
int cmdsn;
int cmdBusy;
int loopBack;
-
+
int framesPerSecond; /* Frames per second */
int usecPerFrame; /* micro-seconds per frame, actual video speed */
int samplesPerSecond; /* Samples per second */
@@ -170,7 +174,7 @@ typedef struct
int live; /* non-zero if any of the video/audio streams are live source */
int videoFormat;
int audioFormat;
-
+
/* video channel parameters */
int totalFrames;
int totalGroups;
@@ -186,21 +190,21 @@ typedef struct
char pattern[PATTERN_SIZE];
int IframeGap;
int VStimeAdvance;
-
+
int lastIframeDecoded;
int sendPatternGops;
char sendPattern[PATTERN_SIZE];
float frameRateLimit;
int framesDropped;
int qosRecomputes;
-
+
/* video channel status */
int currentGroup;
int currentFrame;
int currentDisplay;
int nextFrame;
int nextGroup;
-
+
/* audio channel parameters */
int totalSamples;
AudioParameter audioPara;
@@ -214,87 +218,87 @@ typedef struct
int currentUPF;
int rtplay; /* realtime tag, -- VD needs to drop frames when needed */
int collectStat; /* to indicate if statistics should be collected or not */
- int VBheadFrame; /* ID of last frame put to VBbuffer by VB */
+ int VBheadFrame; /* ID of last frame put to VBbuffer by VB */
int needHeader; /* VD requests resending of systerm Header */
int playRoundTripDelay; /* play round trip time (from issuing play/FF/FB
- command to first Decoded frame showup in
- VD buffer) estimated by CTR start_timer() */
- int audioMaxPktSize; /* 0 -- reliable byte stream,
- >0 - non-discard mode packet stream,
- <0 - discard mode packet stream */
+ command to first Decoded frame showup in
+ VD buffer) estimated by CTR start_timer() */
+ int audioMaxPktSize; /* 0 -- reliable byte stream,
+ >0 - non-discard mode packet stream,
+ <0 - discard mode packet stream */
int videoMaxPktSize;
/* System configuration parameters */
struct
{
- int rt; /* play as fast as possible without dropping frames,
- and audio turned off when this tag is set to 0 (zero)
- */
- int maxFPS; /* maximum PLAY frames-per-second, this play speed is used
- during playback when speed scale is set to 100 */
+ int rt; /* play as fast as possible without dropping frames,
+ and audio turned off when this tag is set to 0 (zero)
+ */
+ int maxFPS; /* maximum PLAY frames-per-second, this play speed is used
+ during playback when speed scale is set to 100 */
int maxSPS; /* similar to maxFPS, used when audio is played without
- corresponding video
- */
- int ffFPS; /* play speed when Fast forward */
- int fbFPS; /* play speed when fast rewind */
+ corresponding video
+ */
+ int ffFPS; /* play speed when Fast forward */
+ int fbFPS; /* play speed when fast rewind */
int feedBackDelay; /* msec, delay of feedback when AB, VB received first
- packet, 0 (zero) default to adaptive */
+ packet, 0 (zero) default to adaptive */
int audioMask; /* mask for audio output device */
AudioParameter audioPara; /* default audio parameter by system */
int audioTimerDuration; /* for audio-only case, miliseconds */
int audioBufferedIntervals; /* for audio-only case,
- audioTimerDuration * audioBufferedIntervals
- milliseconds of audio samples will be buffered
- in AF buffer
- */
+ audioTimerDuration * audioBufferedIntervals
+ milliseconds of audio samples will be buffered
+ in AF buffer
+ */
int framesPerAudioPlay; /* for audio-video case, each time, samples corresponding
- to this number of video frames will be played */
+ to this number of video frames will be played */
int audioForward; /* forward value for audio channel, in AFTime unit
- (number of samples), audio channel is played ahead of video
- by this number of samples. This is introduce to compensate
- the dely to AF in audio channel, and usually should be less
- than 1 (one) second, but greater than zero.
- */
+ (number of samples), audio channel is played ahead of video
+ by this number of samples. This is introduce to compensate
+ the dely to AF in audio channel, and usually should be less
+ than 1 (one) second, but greater than zero.
+ */
int VStimeAdvance; /* target VB buffer level to be mentained (micro-seconds). This
- is sent in INIT message to VS, to decide how many frames to
- be maintained in VB buffer
- */
+ is sent in INIT message to VS, to decide how many frames to
+ be maintained in VB buffer
+ */
float frameRateLimit; /* playback frame rate limit (frames per second) */
int collectStat; /* tag to collect statistics to file 'stat.n' when set */
int collectFrameInfo; /* collect MPEG frame info to file 'stat.n' when set*/
int syncEffective; /* tag to make sync mechanism effective when set */
int qosEffective; /* tag to make QoS control effective when set */
- int audioOffset; /* offset added to audio channel 'nextSample' when play().
- usually audio and video are not recorded strictly
- synchronized. This parameter is to compensate it. The
- value can be any integer value.
- */
+ int audioOffset; /* offset added to audio channel 'nextSample' when play().
+ usually audio and video are not recorded strictly
+ synchronized. This parameter is to compensate it. The
+ value can be any integer value.
+ */
int filterPara; /* 1/R of Median, nsamples of Mean and Average */
- int maxSPframes; /* max number of frame in a sendPattern */
- int audioConn; /* tag for connection oriented audio data channel */
- int videoConn; /* tag for connection oriented video data channel */
+ int maxSPframes; /* max number of frame in a sendPattern */
+ int audioConn; /* tag for connection oriented audio data channel */
+ int videoConn; /* tag for connection oriented video data channel */
int verbose;
} config;
#ifdef STAT
struct
{
- unsigned VBmaxBytes; /* max fill level (bytes) in VB */
- unsigned VBdroppedFrames; /* accumulative total number of frames dropped by VB
- because VB buffer full */
- unsigned VBemptyTimes; /* number of time VD fail to get a frame from VB
- immediately */
+ unsigned VBmaxBytes; /* max fill level (bytes) in VB */
+ unsigned VBdroppedFrames; /* accumulative total number of frames dropped by VB
+ because VB buffer full */
+ unsigned VBemptyTimes; /* number of time VD fail to get a frame from VB
+ immediately */
unsigned VDnoRef; /* # of frames without reference */
unsigned VDagainstSendPattern; /* # of frames against send pattern */
unsigned VDtooLateI; /* # of I frames dropped 'cause too late */
unsigned VDtooLateP; /* # of P frames dropped 'cause too late */
unsigned VDtooLateB; /* # of B frames dropped 'cause too late */
- unsigned VDlastFrameDecoded; /* ID of last frame decoded by VD */
+ unsigned VDlastFrameDecoded; /* ID of last frame decoded by VD */
unsigned CTRdropLate;
unsigned CTRdropOutOrder;
unsigned CTRdispOnTime;
unsigned CTRdispLate;
- unsigned fbPacketNumber; /* # packets sent by feedback mechanism */
+ unsigned fbPacketNumber; /* # packets sent by feedback mechanism */
struct {
int frameId;
int addUsecPerFrame;
@@ -303,14 +307,14 @@ typedef struct
int framesDropped;
float frameRateLimit;
int advance;
- } fbPackets[MAX_FB_PACKETS]; /* recording FB packet contents */
+ } fbPackets[MAX_FB_PACKETS]; /* recording FB packet contents */
unsigned VDqueue[MAX_VDQUEUE_SIZE]; /* record number of frames with VD queue
- length of index number */
+ length of index number */
int VBmsgGaps[MSGGAP_MAX + 1 - MSGGAP_MIN]; /* # of ind-sized gaps between msgs */
char VBframesReceived[(MAX_FRAMES + 7)/8]; /* bit array for frames received by VB */
- char VDframesDecoded[(MAX_FRAMES + 7)/8]; /* bit array for frames decoded by VD */
- char VPframesDisplayed[(MAX_FRAMES + 7)/8]; /* bit array for frames displayed by VP */
- short VBfillLevel[MAX_FRAMES]; /* VB buffer fill level (frames) recorded by CTR */
+ char VDframesDecoded[(MAX_FRAMES + 7)/8]; /* bit array for frames decoded by VD */
+ char VPframesDisplayed[(MAX_FRAMES + 7)/8]; /* bit array for frames displayed by VP */
+ short VBfillLevel[MAX_FRAMES]; /* VB buffer fill level (frames) recorded by CTR */
} stat;
#endif
} SharedData;
@@ -320,30 +324,30 @@ typedef struct
/* GUI to CTR, (and also CTR to VS and/or AS) */
#define CmdINIT 0 /* followed by: videoHost, videoPath, audioHost, audioPath
- each item is passed as a string (without 0), led with length(int) */
-#define CmdINITaudio 1 /* for CTR-AS */
-#define CmdINITvideo 2 /* for CTR-VS */
+ each item is passed as a string (without 0), led with length(int) */
+#define CmdINITaudio 1 /* for CTR-AS */
+#define CmdINITvideo 2 /* for CTR-VS */
#define CmdSTOP 3
-#define CmdFF 4
-#define CmdFB 5
+#define CmdFF 4
+#define CmdFB 5
#define CmdSTEP 6
-#define CmdPLAY 7
-#define CmdREF 20 /* this is for sending REFerence frame by VS
- for CmdSTEP and CmdPLAY */
-#define CmdPOSITION 8 /* followed by position */
-#define CmdPOSITIONrelease 9 /* followed by position */
-#define CmdVOLUME 10 /* followed by position */
-#define CmdBALANCE 11 /* followed by position */
-#define CmdSPEED 12 /* followed by position */
-#define CmdLOOPenable 13
-#define CmdLOOPdisable 14
-#define CmdSTATstream 23 /* reply with { | type(byte) | size(int) }+ | */
-#define CmdSTATsent 24 /* reply with { | byte }+ | */
-#define CmdCLOSE 18
-#define CmdFAIL 19 /* followed by a string */
-
-#define CmdDONE 15 /* CTR to GUI:
- replay for accptance and execution of Above Cmd */
+#define CmdPLAY 7
+#define CmdREF 20 /* this is for sending REFerence frame by VS
+ for CmdSTEP and CmdPLAY */
+#define CmdPOSITION 8 /* followed by position */
+#define CmdPOSITIONrelease 9 /* followed by position */
+#define CmdVOLUME 10 /* followed by position */
+#define CmdBALANCE 11 /* followed by position */
+#define CmdSPEED 12 /* followed by position */
+#define CmdLOOPenable 13
+#define CmdLOOPdisable 14
+#define CmdSTATstream 23 /* reply with { | type(byte) | size(int) }+ | */
+#define CmdSTATsent 24 /* reply with { | byte }+ | */
+#define CmdCLOSE 18
+#define CmdFAIL 19 /* followed by a string */
+
+#define CmdDONE 15 /* CTR to GUI:
+ replay for accptance and execution of Above Cmd */
#define CmdVPinitScreen 30 /* CTR to VP(GUI), audio-only screen clearning */
#define CmdVPdisplayFrame 31 /* CTR to VP(GUI) to display the single frame in buffer */
@@ -375,7 +379,7 @@ typedef struct
{
int live;
int format;
-
+
int totalHeaders;
int totalFrames;
int totalGroups;
@@ -508,7 +512,7 @@ typedef struct
{
int live;
int format;
-
+
AudioParameter para;
int totalSamples;
} INITaudioReply;
@@ -575,7 +579,7 @@ typedef struct
typedef struct {
int sh, gop, frame, display, future, past;
- int refcount; /* reference count */
+ int refcount; /* reference count */
unsigned char * data; /* data buffer for image */
} FrameBlock;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h
index a972440bc29..b45b17c38ee 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/Command_Handler.h
@@ -26,6 +26,10 @@
*/
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
// ============================================================================
//
// = LIBRARY
@@ -45,7 +49,7 @@
// ============================================================================
-#if !defined (AV_COMMAND_HANDLER_H)
+#ifndef AV_COMMAND_HANDLER_H
#define AV_COMMAND_HANDLER_H
#include "ace/Reactor.h"
@@ -76,7 +80,7 @@ class Receiver_i
void push_audio_mmdevice (CORBA::Object_ptr mmdevice,
const char* audio_file,
- CORBA::Environment&);
+ CORBA::Environment&);
private:
Command_Handler *command_handler_;
@@ -377,7 +381,7 @@ public:
int operation_tag_;
// operation tag for release/press for position.
-
+
int position_val_;
// value of the position button.
@@ -473,7 +477,7 @@ public:
int step (void);
int play (int flag,
- CORBA::Environment& env);
+ CORBA::Environment& env);
int position_action (int operation_tag);
@@ -566,7 +570,7 @@ private:
Receiver_i receiver_;
// Receive object,called by the agent to give the mmdevice object
- // reference.
+ // reference.
char *data_host_;
// interface name to bind to for data transfer.
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
index 37d2dfa93ce..da6f73bca54 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/decoders.h
@@ -2,17 +2,17 @@
/*
* Copyright (c) 1992 The Regents of the University of California.
* All rights reserved.
- *
+ *
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice and the following
* two paragraphs appear in all copies of this software.
- *
+ *
* IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
* DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
* OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF
* CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+ *
* THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
@@ -32,6 +32,10 @@
#include "util.h"
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
/* Code for unbound values in decoding tables */
#define ERROR -1
#define DCT_ERROR 63
@@ -47,7 +51,7 @@
#define END_OF_BLOCK 62
#define ESCAPE 61
-/* Structure for an entry in the decoding table of
+/* Structure for an entry in the decoding table of
* macroblock_address_increment */
typedef struct {
unsigned int value; /* value for macroblock_address_increment */
@@ -90,10 +94,10 @@ extern coded_block_pattern_entry coded_block_pattern[512];
/* Structure for an entry in the decoding table of motion vectors */
typedef struct {
int code; /* value for motion_horizontal_forward_code,
- * motion_vertical_forward_code,
- * motion_horizontal_backward_code, or
- * motion_vertical_backward_code.
- */
+ * motion_vertical_forward_code,
+ * motion_horizontal_backward_code, or
+ * motion_vertical_backward_code.
+ */
int num_bits; /* length of the Huffman code */
} motion_vectors_entry;
@@ -156,127 +160,127 @@ extern unsigned short int dct_coeff_first[256];
flush_bits(dct_dc_size_chrominance[index].num_bits); \
}
-#define DecodeDCTCoeff(dct_coeff_tbl, run, level) \
-{ \
- unsigned int temp, index; \
- unsigned int value, next32bits, flushed; \
- \
- /* \
- * Grab the next 32 bits and use it to improve performance of \
- * getting the bits to parse. Thus, calls are translated as: \
- * \
- * show_bitsX <--> next32bits >> (32-X) \
- * get_bitsX <--> val = next32bits >> (32-flushed-X); \
- * flushed += X; \
- * next32bits &= bitMask[flushed]; \
- * flush_bitsX <--> flushed += X; \
- * next32bits &= bitMask[flushed]; \
- * \
- * I've streamlined the code a lot, so that we don't have to mask \
- * out the low order bits and a few of the extra adds are removed. \
- */ \
- show_bits32(next32bits); \
- \
- /* show_bits8(index); */ \
- index = next32bits >> 24; \
- \
- if (index > 3) { \
- value = dct_coeff_tbl[index]; \
- run = value >> RUN_SHIFT; \
- if (run != END_OF_BLOCK) { \
- /* num_bits = (value & NUM_MASK) + 1; */ \
- /* flush_bits(num_bits); */ \
- if (run != ESCAPE) { \
- /* get_bits1(value); */ \
- /* if (value) level = -level; */ \
- flushed = (value & NUM_MASK) + 2; \
- level = (value & LEVEL_MASK) >> LEVEL_SHIFT; \
- value = next32bits >> (32-flushed); \
- value &= 0x1; \
- if (value) level = -level; \
- /* next32bits &= ((~0) >> flushed); last op before update */ \
- } \
- else { /* run == ESCAPE */ \
- /* Get the next six into run, and next 8 into temp */ \
- /* get_bits14(temp); */ \
- flushed = (value & NUM_MASK) + 1; \
- temp = next32bits >> (18-flushed); \
- /* Normally, we'd ad 14 to flushed, but I've saved a few \
- * instr by moving the add below */ \
- temp &= 0x3fff; \
- run = temp >> 8; \
- temp &= 0xff; \
- if (temp == 0) { \
- /* get_bits8(level); */ \
- level = next32bits >> (10-flushed); \
- level &= 0xff; \
- flushed += 22; \
- assert(level >= 128); \
- } else if (temp != 128) { \
- /* Grab sign bit */ \
- flushed += 14; \
- level = ((int) (temp << 24)) >> 24; \
- } else { \
- /* get_bits8(level); */ \
- level = next32bits >> (10-flushed); \
- level &= 0xff; \
- flushed += 22; \
- level = level - 256; \
- assert(level <= -128 && level >= -255); \
- } \
- } \
- /* Update bitstream... */ \
- flush_bits(flushed); \
- assert (flushed <= 32); \
- } \
- } \
- else { \
- if (index == 2) { \
- /* show_bits10(index); */ \
- index = next32bits >> 22; \
- value = dct_coeff_tbl_2[index & 3]; \
- } \
- else if (index == 3) { \
- /* show_bits10(index); */ \
- index = next32bits >> 22; \
- value = dct_coeff_tbl_3[index & 3]; \
- } \
- else if (index) { /* index == 1 */ \
- /* show_bits12(index); */ \
- index = next32bits >> 20; \
- value = dct_coeff_tbl_1[index & 15]; \
- } \
- else { /* index == 0 */ \
- /* show_bits16(index); */ \
- index = next32bits >> 16; \
- value = dct_coeff_tbl_0[index & 255]; \
- } \
- run = value >> RUN_SHIFT; \
- level = (value & LEVEL_MASK) >> LEVEL_SHIFT; \
- \
- /* \
- * Fold these operations together to make it fast... \
- */ \
- /* num_bits = (value & NUM_MASK) + 1; */ \
- /* flush_bits(num_bits); */ \
- /* get_bits1(value); */ \
- /* if (value) level = -level; */ \
- \
- flushed = (value & NUM_MASK) + 2; \
- value = next32bits >> (32-flushed); \
- value &= 0x1; \
- if (value) level = -level; \
- \
- /* Update bitstream ... */ \
- flush_bits(flushed); \
- assert (flushed <= 32); \
- } \
+#define DecodeDCTCoeff(dct_coeff_tbl, run, level) \
+{ \
+ unsigned int temp, index; \
+ unsigned int value, next32bits, flushed; \
+ \
+ /* \
+ * Grab the next 32 bits and use it to improve performance of \
+ * getting the bits to parse. Thus, calls are translated as: \
+ * \
+ * show_bitsX <--> next32bits >> (32-X) \
+ * get_bitsX <--> val = next32bits >> (32-flushed-X); \
+ * flushed += X; \
+ * next32bits &= bitMask[flushed]; \
+ * flush_bitsX <--> flushed += X; \
+ * next32bits &= bitMask[flushed]; \
+ * \
+ * I've streamlined the code a lot, so that we don't have to mask \
+ * out the low order bits and a few of the extra adds are removed. \
+ */ \
+ show_bits32(next32bits); \
+ \
+ /* show_bits8(index); */ \
+ index = next32bits >> 24; \
+ \
+ if (index > 3) { \
+ value = dct_coeff_tbl[index]; \
+ run = value >> RUN_SHIFT; \
+ if (run != END_OF_BLOCK) { \
+ /* num_bits = (value & NUM_MASK) + 1; */ \
+ /* flush_bits(num_bits); */ \
+ if (run != ESCAPE) { \
+ /* get_bits1(value); */ \
+ /* if (value) level = -level; */ \
+ flushed = (value & NUM_MASK) + 2; \
+ level = (value & LEVEL_MASK) >> LEVEL_SHIFT; \
+ value = next32bits >> (32-flushed); \
+ value &= 0x1; \
+ if (value) level = -level; \
+ /* next32bits &= ((~0) >> flushed); last op before update */ \
+ } \
+ else { /* run == ESCAPE */ \
+ /* Get the next six into run, and next 8 into temp */ \
+ /* get_bits14(temp); */ \
+ flushed = (value & NUM_MASK) + 1; \
+ temp = next32bits >> (18-flushed); \
+ /* Normally, we'd ad 14 to flushed, but I've saved a few \
+ * instr by moving the add below */ \
+ temp &= 0x3fff; \
+ run = temp >> 8; \
+ temp &= 0xff; \
+ if (temp == 0) { \
+ /* get_bits8(level); */ \
+ level = next32bits >> (10-flushed); \
+ level &= 0xff; \
+ flushed += 22; \
+ assert(level >= 128); \
+ } else if (temp != 128) { \
+ /* Grab sign bit */ \
+ flushed += 14; \
+ level = ((int) (temp << 24)) >> 24; \
+ } else { \
+ /* get_bits8(level); */ \
+ level = next32bits >> (10-flushed); \
+ level &= 0xff; \
+ flushed += 22; \
+ level = level - 256; \
+ assert(level <= -128 && level >= -255); \
+ } \
+ } \
+ /* Update bitstream... */ \
+ flush_bits(flushed); \
+ assert (flushed <= 32); \
+ } \
+ } \
+ else { \
+ if (index == 2) { \
+ /* show_bits10(index); */ \
+ index = next32bits >> 22; \
+ value = dct_coeff_tbl_2[index & 3]; \
+ } \
+ else if (index == 3) { \
+ /* show_bits10(index); */ \
+ index = next32bits >> 22; \
+ value = dct_coeff_tbl_3[index & 3]; \
+ } \
+ else if (index) { /* index == 1 */ \
+ /* show_bits12(index); */ \
+ index = next32bits >> 20; \
+ value = dct_coeff_tbl_1[index & 15]; \
+ } \
+ else { /* index == 0 */ \
+ /* show_bits16(index); */ \
+ index = next32bits >> 16; \
+ value = dct_coeff_tbl_0[index & 255]; \
+ } \
+ run = value >> RUN_SHIFT; \
+ level = (value & LEVEL_MASK) >> LEVEL_SHIFT; \
+ \
+ /* \
+ * Fold these operations together to make it fast... \
+ */ \
+ /* num_bits = (value & NUM_MASK) + 1; */ \
+ /* flush_bits(num_bits); */ \
+ /* get_bits1(value); */ \
+ /* if (value) level = -level; */ \
+ \
+ flushed = (value & NUM_MASK) + 2; \
+ value = next32bits >> (32-flushed); \
+ value &= 0x1; \
+ if (value) level = -level; \
+ \
+ /* Update bitstream ... */ \
+ flush_bits(flushed); \
+ assert (flushed <= 32); \
+ } \
}
#define DecodeDCTCoeffFirst(runval, levelval) \
{ \
DecodeDCTCoeff(dct_coeff_first, runval, levelval); \
-}
+}
#define DecodeDCTCoeffNext(runval, levelval) \
{ \
@@ -302,12 +306,12 @@ extern unsigned short int dct_coeff_first[256];
*
*--------------------------------------------------------------
*/
-#define DecodeMBAddrInc(val) \
-{ \
- unsigned int index; \
- show_bits11(index); \
- val = mb_addr_inc[index].value; \
- flush_bits(mb_addr_inc[index].num_bits); \
+#define DecodeMBAddrInc(val) \
+{ \
+ unsigned int index; \
+ show_bits11(index); \
+ val = mb_addr_inc[index].value; \
+ flush_bits(mb_addr_inc[index].num_bits); \
}
/*
@@ -332,12 +336,12 @@ extern unsigned short int dct_coeff_first[256];
*--------------------------------------------------------------
*/
-#define DecodeMotionVectors(value) \
-{ \
- unsigned int index; \
- show_bits11(index); \
- value = motion_vectors[index].code; \
- flush_bits(motion_vectors[index].num_bits); \
+#define DecodeMotionVectors(value) \
+{ \
+ unsigned int index; \
+ show_bits11(index); \
+ value = motion_vectors[index].code; \
+ flush_bits(motion_vectors[index].num_bits); \
}
/*
*--------------------------------------------------------------
@@ -361,18 +365,18 @@ extern unsigned short int dct_coeff_first[256];
*
*--------------------------------------------------------------
*/
-#define DecodeMBTypeB(quant, motion_fwd, motion_bwd, pat, intra) \
-{ \
- unsigned int index; \
- \
- show_bits6(index); \
- \
- quant = mb_type_B[index].mb_quant; \
- motion_fwd = mb_type_B[index].mb_motion_forward; \
- motion_bwd = mb_type_B[index].mb_motion_backward; \
- pat = mb_type_B[index].mb_pattern; \
- intra = mb_type_B[index].mb_intra; \
- flush_bits(mb_type_B[index].num_bits); \
+#define DecodeMBTypeB(quant, motion_fwd, motion_bwd, pat, intra) \
+{ \
+ unsigned int index; \
+ \
+ show_bits6(index); \
+ \
+ quant = mb_type_B[index].mb_quant; \
+ motion_fwd = mb_type_B[index].mb_motion_forward; \
+ motion_bwd = mb_type_B[index].mb_motion_backward; \
+ pat = mb_type_B[index].mb_pattern; \
+ intra = mb_type_B[index].mb_intra; \
+ flush_bits(mb_type_B[index].num_bits); \
}
/*
*--------------------------------------------------------------
@@ -395,21 +399,21 @@ extern unsigned short int dct_coeff_first[256];
*
*--------------------------------------------------------------
*/
-#define DecodeMBTypeI(quant, motion_fwd, motion_bwd, pat, intra) \
-{ \
- unsigned int index; \
- static int quantTbl[4] = {ERROR, 1, 0, 0}; \
- \
- show_bits2(index); \
- \
- motion_fwd = 0; \
- motion_bwd = 0; \
- pat = 0; \
- intra = 1; \
- quant = quantTbl[index]; \
- if (index) { \
- flush_bits (1 + quant); \
- } \
+#define DecodeMBTypeI(quant, motion_fwd, motion_bwd, pat, intra) \
+{ \
+ unsigned int index; \
+ static int quantTbl[4] = {ERROR, 1, 0, 0}; \
+ \
+ show_bits2(index); \
+ \
+ motion_fwd = 0; \
+ motion_bwd = 0; \
+ pat = 0; \
+ intra = 1; \
+ quant = quantTbl[index]; \
+ if (index) { \
+ flush_bits (1 + quant); \
+ } \
}
/*
*--------------------------------------------------------------
@@ -433,19 +437,19 @@ extern unsigned short int dct_coeff_first[256];
*
*--------------------------------------------------------------
*/
-#define DecodeMBTypeP(quant, motion_fwd, motion_bwd, pat, intra) \
-{ \
- unsigned int index; \
- \
- show_bits6(index); \
- \
- quant = mb_type_P[index].mb_quant; \
- motion_fwd = mb_type_P[index].mb_motion_forward; \
- motion_bwd = mb_type_P[index].mb_motion_backward; \
- pat = mb_type_P[index].mb_pattern; \
- intra = mb_type_P[index].mb_intra; \
- \
- flush_bits(mb_type_P[index].num_bits); \
+#define DecodeMBTypeP(quant, motion_fwd, motion_bwd, pat, intra) \
+{ \
+ unsigned int index; \
+ \
+ show_bits6(index); \
+ \
+ quant = mb_type_P[index].mb_quant; \
+ motion_fwd = mb_type_P[index].mb_motion_forward; \
+ motion_bwd = mb_type_P[index].mb_motion_backward; \
+ pat = mb_type_P[index].mb_pattern; \
+ intra = mb_type_P[index].mb_intra; \
+ \
+ flush_bits(mb_type_P[index].num_bits); \
}
/*
*--------------------------------------------------------------
@@ -466,11 +470,11 @@ extern unsigned short int dct_coeff_first[256];
*
*--------------------------------------------------------------
*/
-#define DecodeCBP(coded_bp) \
-{ \
- unsigned int index; \
- \
- show_bits9(index); \
- coded_bp = coded_block_pattern[index].cbp; \
- flush_bits(coded_block_pattern[index].num_bits); \
+#define DecodeCBP(coded_bp) \
+{ \
+ unsigned int index; \
+ \
+ show_bits9(index); \
+ coded_bp = coded_block_pattern[index].cbp; \
+ flush_bits(coded_block_pattern[index].num_bits); \
}
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/dither.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/dither.h
index f11623f84a5..51320095ed5 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/dither.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/dither.h
@@ -2,17 +2,17 @@
/*
* Copyright (c) 1992 The Regents of the University of California.
* All rights reserved.
- *
+ *
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice and the following
* two paragraphs appear in all copies of this software.
- *
+ *
* IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
* DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
* OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF
* CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+ *
* THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
index 6cf228bf60b..21991215259 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs2.h
@@ -2,17 +2,17 @@
/*
* Copyright (c) 1992 The Regents of the University of California.
* All rights reserved.
- *
+ *
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice and the following
* two paragraphs appear in all copies of this software.
- *
+ *
* IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
* DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
* OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF
* CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+ *
* THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
@@ -21,6 +21,10 @@
*/
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
typedef struct {
unsigned char value;
int e1;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
index 2109c6f6691..96a93ee1878 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/fs4.h
@@ -2,17 +2,17 @@
/*
* Copyright (c) 1992 The Regents of the University of California.
* All rights reserved.
- *
+ *
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice and the following
* two paragraphs appear in all copies of this software.
- *
+ *
* IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
* DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
* OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF
* CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+ *
* THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
@@ -21,11 +21,15 @@
*/
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
typedef struct {
unsigned char value;
int e1;
- int e2;
+ int e2;
int e3;
- int e4;
+ int e4;
} FS4Dither;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/global.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/global.h
index b7faf0b2827..40bb64b0985 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/global.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/global.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mibload.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mibload.h
index c421a53f167..085d1802ce0 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mibload.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/mibload.h
@@ -41,42 +41,42 @@ ftp from geom.umn.edu; email: software@geom.umn.edu. */
/*****************************************************************************/
typedef struct _mib_Widget {
- char *mib_class; /* name of mib class (Button, TextBox, etc..)*/
- int mib_class_num; /* class number for ez reference :) */
- int mib_mynum; /* numbering for storage format */
- Widget me; /* Xt widget */
- int mib_selected; /* is selected */
- int mib_resizing; /* is resizing 1, or being moved 0 */
- int mib_resizetype;/* 1 = upper left, 2 = upper, 3 = ... */
- int mib_allowresize; /* can this widget be resized ? */
+ char *mib_class; /* name of mib class (Button, TextBox, etc..)*/
+ int mib_class_num; /* class number for ez reference :) */
+ int mib_mynum; /* numbering for storage format */
+ Widget me; /* Xt widget */
+ int mib_selected; /* is selected */
+ int mib_resizing; /* is resizing 1, or being moved 0 */
+ int mib_resizetype;/* 1 = upper left, 2 = upper, 3 = ... */
+ int mib_allowresize; /* can this widget be resized ? */
- int clkx, clky; /* where user clicked */
+ int clkx, clky; /* where user clicked */
- void *myres; /* my resources (different for each widget) */
+ void *myres; /* my resources (different for each widget) */
- char *name; /* reference name of this widget */
- int width, height; /* width and height */
+ char *name; /* reference name of this widget */
+ int width, height; /* width and height */
int topAttachment, bottomAttachment, leftAttachment, rightAttachment;
- /* attachments 1=attached 0=not-attached */
+ /* attachments 1=attached 0=not-attached */
int topOffset, bottomOffset, leftOffset, rightOffset;
- /* offsets if attached */
+ /* offsets if attached */
struct _mib_Widget *parent; /* pointer to parent */
struct _mib_Widget *sibling; /* remaining linked list of sibling widgets */
- struct _mib_Widget *prev; /* previous sibling or parent */
- struct _mib_Widget *child; /* linked list of children widgets */
+ struct _mib_Widget *prev; /* previous sibling or parent */
+ struct _mib_Widget *child; /* linked list of children widgets */
} mib_Widget;
/* mib_Buffer structure */
/*****************************************************************************/
typedef struct _mib_Buffer {
- void *buffer; /* pointer to either a file or a char string */
- int buf_type; /* type of buffer (defined above) */
- int point; /* pointer for string */
- int buflen; /* length of string buffer */
+ void *buffer; /* pointer to either a file or a char string */
+ int buf_type; /* type of buffer (defined above) */
+ int point; /* pointer for string */
+ int buflen; /* length of string buffer */
} mib_Buffer;
/* mib_Widget functions */
@@ -93,7 +93,7 @@ int mib_count_all(mib_Widget *, int);
int mib_load_Root(Widget, mib_Widget **, mib_Buffer *);
mib_Widget *mib_load_public(mib_Widget *, mib_Widget *, mib_Buffer *);
int mib_load_mib_class(mib_Widget **, mib_Widget *, char *, char *,
- mib_Buffer *);
+ mib_Buffer *);
int mib_load_private(mib_Widget *, mib_Buffer *);
void mib_reset_size(mib_Widget *);
int mib_read_line(mib_Buffer *, char *, char *);
@@ -118,38 +118,38 @@ Widget BuildMenu(Widget, int, char *, char, MenuItem *);
/* mib class numbers */
-#define MIB_NULL 0
-#define MIB_TEXTBOX 1
-#define MIB_BUTTON 2
-#define MIB_TOGGLE 3
-#define MIB_RADIOBOX 4
-#define MIB_DRAWINGAREA 5
-#define MIB_LABEL 6
-#define MIB_FRAME 7
-#define MIB_SCROLLBAR 8
-#define MIB_TEXTBIG 9
-#define MIB_LIST 10
-#define MIB_SCALE 11
-#define MIB_MENU 12
+#define MIB_NULL 0
+#define MIB_TEXTBOX 1
+#define MIB_BUTTON 2
+#define MIB_TOGGLE 3
+#define MIB_RADIOBOX 4
+#define MIB_DRAWINGAREA 5
+#define MIB_LABEL 6
+#define MIB_FRAME 7
+#define MIB_SCROLLBAR 8
+#define MIB_TEXTBIG 9
+#define MIB_LIST 10
+#define MIB_SCALE 11
+#define MIB_MENU 12
/* number of classes */
-#define MI_NUMCLASSES 12
+#define MI_NUMCLASSES 12
/* for specifying creation of a widget with
default private values, no values at all (empty),
or no values and editable */
-#define WDEFAULT 1
-#define WEMPTY 2
-#define WEDIT 3
+#define WDEFAULT 1
+#define WEMPTY 2
+#define WEDIT 3
/* for specifing whether we are loading an
interface from a file or from a string and whether it
is editable :) */
-#define MI_FROMFILE 1
-#define MI_EDITFROMFILE 2
-#define MI_FROMSTRING 3
-#define MI_EDITFROMSTRING 4
+#define MI_FROMFILE 1
+#define MI_EDITFROMFILE 2
+#define MI_FROMSTRING 3
+#define MI_EDITFROMSTRING 4
-#define MI_MAXSTRLEN 200 /* maximum string length */
+#define MI_MAXSTRLEN 200 /* maximum string length */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/newproto.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/newproto.h
index 7dab93d341d..9df0e313bbb 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/newproto.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/newproto.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/proto.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/proto.h
index 762a66d184d..023cd981944 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/proto.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/proto.h
@@ -2,7 +2,7 @@
#ifdef __STDC__
-# define P(s) s
+# define P(s) s
#else
# define P(s) ()
#endif
@@ -91,11 +91,11 @@ void GrayDitherImage P((unsigned char *lum , unsigned char *cr , unsigned char *
/* mono.c */
void MonoDitherImage(register unsigned char *lum, unsigned char *cr,
- unsigned char *cb, unsigned char *out,
- int h, int w);
+ unsigned char *cb, unsigned char *out,
+ int h, int w);
void MonoThresholdImage(unsigned char *lum, unsigned char *cr,
- unsigned char *cb, unsigned char *out,
- int h, int w);
+ unsigned char *cb, unsigned char *out,
+ int h, int w);
/* jrevdct.c */
void init_pre_idct P((void ));
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ui.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ui.h
index b1ce065cc10..a77b5fdbb4e 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ui.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/ui.h
@@ -9,9 +9,9 @@ ftp from geom.umn.edu; email: software@geom.umn.edu. */
/* Author: Daeron Meyer */
-void UICreate();
-void UIEnd();
-Window MonitorWindow();
+void UICreate();
+void UIEnd();
+Window MonitorWindow();
void UISetwin(Window);
void UIMinsize(int, int);
void UISetFrame();
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.h
index 272e0add31d..3c68ea365cd 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/util.h
@@ -2,17 +2,17 @@
/*
* Copyright (c) 1992 The Regents of the University of California.
* All rights reserved.
- *
+ *
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice and the following
* two paragraphs appear in all copies of this software.
- *
+ *
* IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
* DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
* OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF
* CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+ *
* THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
@@ -22,7 +22,7 @@
/* Status codes for bit stream i/o operations. */
-#if !defined (AV_UTIL_H)
+#ifndef AV_UTIL_H
#define AV_UTIL_H
#define NO_VID_STREAM -1
@@ -199,13 +199,13 @@ extern unsigned int *bitBuffer;
#define get_bitsn(num, result) get_bitsX((num), nBitMask[num], (32-(num)), result)
#ifdef NO_SANITY_CHECKS
-#define show_bits32(result) \
+#define show_bits32(result) \
{ \
- if (bitOffset) { \
- result = curBits | (*(bitBuffer+1) >> (32 - bitOffset)); \
+ if (bitOffset) { \
+ result = curBits | (*(bitBuffer+1) >> (32 - bitOffset)); \
} \
else { \
- result = curBits; \
+ result = curBits; \
} \
}
@@ -224,17 +224,17 @@ extern unsigned int *bitBuffer;
}
#else
-#define show_bits32(result) \
+#define show_bits32(result) \
{ \
/* Check for underflow. */ \
/* if (bufLength < 2) { \
correct_underflow(); \
} */ \
- if (bitOffset) { \
- result = curBits | (*(bitBuffer+1) >> (32 - bitOffset)); \
+ if (bitOffset) { \
+ result = curBits | (*(bitBuffer+1) >> (32 - bitOffset)); \
} \
else { \
- result = curBits; \
+ result = curBits; \
} \
}
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/video.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/video.h
index 13096759702..c8940e2a517 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/video.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_client/video.h
@@ -2,17 +2,17 @@
/*
* Copyright (c) 1992 The Regents of the University of California.
* All rights reserved.
- *
+ *
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice and the following
* two paragraphs appear in all copies of this software.
- *
+ *
* IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
* DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
* OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF
* CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
+ *
* THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES,
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
@@ -40,7 +40,7 @@ typedef char INT8;
typedef unsigned int UINT32;
typedef unsigned short UINT16;
typedef unsigned char UINT8;
-
+
/* Define Parsing error codes. */
#define SKIP_PICTURE -10
@@ -132,7 +132,7 @@ typedef struct GoP {
unsigned int tc_seconds; /* Second component of time code. */
unsigned int tc_pictures; /* Picture counter of time code. */
BOOLEAN closed_gop; /* Indicates no pred. vectors to
- previous group of pictures. */
+ previous group of pictures. */
BOOLEAN broken_link; /* B frame unable to be decoded. */
char *ext_data; /* Extension data. */
char *user_data; /* User data. */
@@ -145,11 +145,11 @@ typedef struct pict {
unsigned int code_type; /* Frame type: P, B, I */
unsigned int vbv_delay; /* Buffer delay. */
BOOLEAN full_pel_forw_vector; /* Forw. vectors specified in full
- pixel values flag. */
+ pixel values flag. */
unsigned int forw_r_size; /* Used for vector decoding. */
unsigned int forw_f; /* Used for vector decoding. */
- BOOLEAN full_pel_back_vector; /* Back vectors specified in full
- pixel values flag. */
+ BOOLEAN full_pel_back_vector; /* Back vectors specified in full
+ pixel values flag. */
unsigned int back_r_size; /* Used in decoding. */
unsigned int back_f; /* Used in decoding. */
char *extra_info; /* Extra bit picture info. */
@@ -212,12 +212,12 @@ typedef struct vid_stream {
unsigned int vbv_buffer_size; /* Minimum buffer size. */
BOOLEAN const_param_flag; /* Contrained parameter flag. */
unsigned char intra_quant_matrix[8][8]; /* Quantization matrix for
- intracoded frames. */
- unsigned char non_intra_quant_matrix[8][8]; /* Quanitization matrix for
- non intracoded frames. */
+ intracoded frames. */
+ unsigned char non_intra_quant_matrix[8][8]; /* Quanitization matrix for
+ non intracoded frames. */
char *ext_data; /* Extension data. */
char *user_data; /* User data. */
- int gopid; /* id of latest group id */
+ int gopid; /* id of latest group id */
GoP group; /* Current group of pict. */
Pict picture; /* Current picture. */
Slice slice; /* Current slice. */
@@ -226,7 +226,7 @@ typedef struct vid_stream {
int state; /* State of decoding. */
int bit_offset; /* Bit offset in stream. */
unsigned int *buffer; /* Pointer to next byte in
- buffer. */
+ buffer. */
int buf_length; /* Length of remaining buffer.*/
unsigned int *buf_start; /* Pointer to buffer start. */
int max_buf_length; /* Max lenght of buffer. */
@@ -234,7 +234,7 @@ typedef struct vid_stream {
PictImage *future; /* Future predictive frame. */
PictImage *current; /* Current frame. */
PictImage *ring[RING_BUF_SIZE]; /* Ring buffer of frames. */
-} VidStream;
+} VidStream;
/* Declaration of global pointer to current video stream. */
@@ -257,14 +257,14 @@ extern char *ditherFlags;
#define CONST_BITS 13
/* Misc DCT definitions */
-#define DCTSIZE 8 /* The basic DCT block is 8x8 samples */
-#define DCTSIZE2 64 /* DCTSIZE squared; # of elements in a block */
+#define DCTSIZE 8 /* The basic DCT block is 8x8 samples */
+#define DCTSIZE2 64 /* DCTSIZE squared; # of elements in a block */
+
+#define GLOBAL /* a function referenced thru EXTERNs */
-#define GLOBAL /* a function referenced thru EXTERNs */
-
typedef short DCTELEM;
typedef DCTELEM DCTBLOCK[DCTSIZE2];
-
+
#ifdef SH_MEM
extern int gXErrorFlag;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibload.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibload.h
index 3b20908a333..050dd00c110 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibload.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibload.h
@@ -37,47 +37,51 @@ ftp from geom.umn.edu; email: software@geom.umn.edu. */
#include <Xm/MwmUtil.h>
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
/* Structure of mib_Widget */
/*****************************************************************************/
typedef struct _mib_Widget {
- char *mib_class; /* name of mib class (Button, TextBox, etc..)*/
- int mib_class_num; /* class number for ez reference :) */
- int mib_mynum; /* numbering for storage format */
- Widget me; /* Xt widget */
- int mib_selected; /* is selected */
- int mib_resizing; /* is resizing 1, or being moved 0 */
- int mib_resizetype;/* 1 = upper left, 2 = upper, 3 = ... */
- int mib_allowresize; /* can this widget be resized ? */
+ char *mib_class; /* name of mib class (Button, TextBox, etc..)*/
+ int mib_class_num; /* class number for ez reference :) */
+ int mib_mynum; /* numbering for storage format */
+ Widget me; /* Xt widget */
+ int mib_selected; /* is selected */
+ int mib_resizing; /* is resizing 1, or being moved 0 */
+ int mib_resizetype;/* 1 = upper left, 2 = upper, 3 = ... */
+ int mib_allowresize; /* can this widget be resized ? */
- int clkx, clky; /* where user clicked */
+ int clkx, clky; /* where user clicked */
- void *myres; /* my resources (different for each widget) */
+ void *myres; /* my resources (different for each widget) */
- char *name; /* reference name of this widget */
- int width, height; /* width and height */
+ char *name; /* reference name of this widget */
+ int width, height; /* width and height */
int topAttachment, bottomAttachment, leftAttachment, rightAttachment;
- /* attachments 1=attached 0=not-attached */
+ /* attachments 1=attached 0=not-attached */
int topOffset, bottomOffset, leftOffset, rightOffset;
- /* offsets if attached */
+ /* offsets if attached */
struct _mib_Widget *parent; /* pointer to parent */
struct _mib_Widget *sibling; /* remaining linked list of sibling widgets */
- struct _mib_Widget *prev; /* previous sibling or parent */
- struct _mib_Widget *child; /* linked list of children widgets */
+ struct _mib_Widget *prev; /* previous sibling or parent */
+ struct _mib_Widget *child; /* linked list of children widgets */
} mib_Widget;
/* mib_Buffer structure */
/*****************************************************************************/
typedef struct _mib_Buffer {
- void *buffer; /* pointer to either a file or a char string */
- int buf_type; /* type of buffer (defined above) */
- int point; /* pointer for string */
- int buflen; /* length of string buffer */
+ void *buffer; /* pointer to either a file or a char string */
+ int buf_type; /* type of buffer (defined above) */
+ int point; /* pointer for string */
+ int buflen; /* length of string buffer */
} mib_Buffer;
/* mib_Widget functions */
@@ -98,7 +102,7 @@ int mib_count_all(mib_Widget *, int);
int mib_load_Root(Widget, mib_Widget **, mib_Buffer *);
mib_Widget *mib_load_public(mib_Widget *, mib_Widget *, mib_Buffer *);
int mib_load_mib_class(mib_Widget **, mib_Widget *, char *, char *,
- mib_Buffer *);
+ mib_Buffer *);
int mib_load_private(mib_Widget *, mib_Buffer *);
void mib_reset_size(mib_Widget *);
int mib_read_line(mib_Buffer *, char *, char *);
@@ -131,38 +135,38 @@ Widget BuildMenu(Widget, int, char *, char, MenuItem *);
/* mib class numbers */
-#define MIB_NULL 0
-#define MIB_TEXTBOX 1
-#define MIB_BUTTON 2
-#define MIB_TOGGLE 3
-#define MIB_RADIOBOX 4
-#define MIB_DRAWINGAREA 5
-#define MIB_LABEL 6
-#define MIB_FRAME 7
-#define MIB_SCROLLBAR 8
-#define MIB_TEXTBIG 9
-#define MIB_LIST 10
-#define MIB_SCALE 11
-#define MIB_MENU 12
+#define MIB_NULL 0
+#define MIB_TEXTBOX 1
+#define MIB_BUTTON 2
+#define MIB_TOGGLE 3
+#define MIB_RADIOBOX 4
+#define MIB_DRAWINGAREA 5
+#define MIB_LABEL 6
+#define MIB_FRAME 7
+#define MIB_SCROLLBAR 8
+#define MIB_TEXTBIG 9
+#define MIB_LIST 10
+#define MIB_SCALE 11
+#define MIB_MENU 12
/* number of classes */
-#define MI_NUMCLASSES 12
+#define MI_NUMCLASSES 12
/* for specifying creation of a widget with
default private values, no values at all (empty),
or no values and editable */
-#define WDEFAULT 1
-#define WEMPTY 2
-#define WEDIT 3
+#define WDEFAULT 1
+#define WEMPTY 2
+#define WEDIT 3
/* for specifing whether we are loading an
interface from a file or from a string and whether it
is editable :) */
-#define MI_FROMFILE 1
-#define MI_EDITFROMFILE 2
-#define MI_FROMSTRING 3
-#define MI_EDITFROMSTRING 4
+#define MI_FROMFILE 1
+#define MI_EDITFROMFILE 2
+#define MI_FROMSTRING 3
+#define MI_EDITFROMSTRING 4
-#define MI_MAXSTRLEN 200 /* maximum string length */
+#define MI_MAXSTRLEN 200 /* maximum string length */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibwidgets.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibwidgets.h
index 778e2338682..5d38ec199b8 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibwidgets.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_mib/mibwidgets.h
@@ -13,14 +13,14 @@ ftp from geom.umn.edu; email: software@geom.umn.edu. */
/*****************************************************************************/
typedef struct _mib_TextBox {
- char *init_contents; /* initial text contents */
+ char *init_contents; /* initial text contents */
} mib_TextBox;
/* mib_TextBox functions */
/*****************************************************************************/
mib_Widget *mib_create_TextBox(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_TextBox(mib_Widget *);
void mib_save_TextBox(mib_Widget *, FILE *);
int mib_load_TextBox(mib_Widget *, mib_Buffer *);
@@ -30,14 +30,14 @@ int mib_load_TextBox(mib_Widget *, mib_Buffer *);
/*****************************************************************************/
typedef struct _mib_Button {
- char *label; /* label on button */
+ char *label; /* label on button */
} mib_Button;
/* mib_Button functions */
/*****************************************************************************/
mib_Widget *mib_create_Button(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_Button(mib_Widget *);
void mib_save_Button(mib_Widget *, FILE *);
int mib_load_Button(mib_Widget *, mib_Buffer *);
@@ -47,7 +47,7 @@ int mib_load_Button(mib_Widget *, mib_Buffer *);
/*****************************************************************************/
typedef struct _mib_Toggle {
- char *label; /* label on toggle */
+ char *label; /* label on toggle */
int isize;
} mib_Toggle;
@@ -55,7 +55,7 @@ typedef struct _mib_Toggle {
/* mib_Toggle functions */
/*****************************************************************************/
mib_Widget *mib_create_Toggle(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_Toggle(mib_Widget *);
void mib_save_Toggle(mib_Widget *, FILE *);
int mib_load_Toggle(mib_Widget *, mib_Buffer *);
@@ -64,9 +64,9 @@ int mib_load_Toggle(mib_Widget *, mib_Buffer *);
/* Structure of mib_RadioBox */
/*****************************************************************************/
typedef struct _mib_RadioBox {
- char **labels; /* array of labels */
- int numlabel; /* number of labels */
- Widget *buttons; /* pointers to each button */
+ char **labels; /* array of labels */
+ int numlabel; /* number of labels */
+ Widget *buttons; /* pointers to each button */
} mib_RadioBox;
@@ -74,7 +74,7 @@ typedef struct _mib_RadioBox {
/*****************************************************************************/
mib_Widget *mib_create_RadioBox(mib_Widget *, char *, char*, int, int, int,
- int, int);
+ int, int);
void mib_delete_RadioBox(mib_Widget *);
void mib_save_RadioBox(mib_Widget *, FILE *);
int mib_load_RadioBox(mib_Widget *, mib_Buffer *);
@@ -83,14 +83,14 @@ int mib_load_RadioBox(mib_Widget *, mib_Buffer *);
/* Structure of mib_DrawingArea */
/*****************************************************************************/
typedef struct _mib_DrawingArea {
- int nothing; /* couldn't think of anything yet */
+ int nothing; /* couldn't think of anything yet */
} mib_DrawingArea;
/* mib_DrawingArea functions */
/*****************************************************************************/
mib_Widget *mib_create_DrawingArea(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_DrawingArea(mib_Widget *);
void mib_save_DrawingArea(mib_Widget *, FILE *);
int mib_load_DrawingArea(mib_Widget *, mib_Buffer *);
@@ -99,14 +99,14 @@ int mib_load_DrawingArea(mib_Widget *, mib_Buffer *);
/* Structure of mib_Label */
/*****************************************************************************/
typedef struct _mib_Label {
- char *label; /* text in label */
+ char *label; /* text in label */
} mib_Label;
/* mib_Label functions */
/*****************************************************************************/
mib_Widget *mib_create_Label(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_Label(mib_Widget *);
void mib_save_Label(mib_Widget *, FILE *);
int mib_load_Label(mib_Widget *, mib_Buffer *);
@@ -115,14 +115,14 @@ int mib_load_Label(mib_Widget *, mib_Buffer *);
/* Structure of mib_Frame */
/*****************************************************************************/
typedef struct _mib_Frame {
- int shadowtype; /* 0 = in, 1 = out, 2 = etched_in, 3 = etched_out */
+ int shadowtype; /* 0 = in, 1 = out, 2 = etched_in, 3 = etched_out */
} mib_Frame;
/* mib_Frame functions */
/*****************************************************************************/
mib_Widget *mib_create_Frame(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_Frame(mib_Widget *);
void mib_save_Frame(mib_Widget *, FILE *);
int mib_load_Frame(mib_Widget *, mib_Buffer *);
@@ -131,14 +131,14 @@ int mib_load_Frame(mib_Widget *, mib_Buffer *);
/* Structure of mib_ScrollBar */
/*****************************************************************************/
typedef struct _mib_ScrollBar {
- int orientation;
+ int orientation;
} mib_ScrollBar;
/* mib_ScrollBar functions */
/*****************************************************************************/
mib_Widget *mib_create_ScrollBar(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_ScrollBar(mib_Widget *);
void mib_save_ScrollBar(mib_Widget *, FILE *);
int mib_load_ScrollBar(mib_Widget *, mib_Buffer *);
@@ -147,7 +147,7 @@ int mib_load_ScrollBar(mib_Widget *, mib_Buffer *);
/* Structure of mib_TextBig */
/*****************************************************************************/
typedef struct _mib_TextBig {
- int nothing; /* couldn't think of anything yet */
+ int nothing; /* couldn't think of anything yet */
} mib_TextBig;
@@ -169,7 +169,7 @@ typedef struct _mib_List {
/* mib_List functions */
/*****************************************************************************/
mib_Widget *mib_create_List(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_List(mib_Widget *);
void mib_save_List(mib_Widget *, FILE *);
int mib_load_List(mib_Widget *, mib_Buffer *);
@@ -192,16 +192,16 @@ int mib_load_Scale(mib_Widget *, mib_Buffer *);
/* Structure of mib_Menu */
/*****************************************************************************/
typedef struct _mib_Menu {
- int numitems; /* number of items in menu*/
- MenuItem *my_menu; /* array of menu items */
- Widget *items; /* pointers to each item */
+ int numitems; /* number of items in menu*/
+ MenuItem *my_menu; /* array of menu items */
+ Widget *items; /* pointers to each item */
} mib_Menu;
/* mib_Menu functions */
/*****************************************************************************/
mib_Widget *mib_create_Menu(mib_Widget *, char *, char *, int, int, int,
- int, int);
+ int, int);
void mib_delete_Menu(mib_Widget *);
void mib_save_Menu(mib_Widget *, FILE *);
int mib_load_Menu(mib_Widget *, mib_Buffer *);
@@ -209,17 +209,17 @@ int mib_load_Menu(mib_Widget *, mib_Buffer *);
/*****************************************************************************/
typedef struct _mib_widget_funcs {
- char *name;
+ char *name;
#ifdef __cplusplus
- mib_Widget *(*mib_create)(mib_Widget *parent, char *name, char *label,
- int posx, int posy, int width, int height, int mib_fill);
- void (*mib_delete)(mib_Widget *thisw);
- void (*mib_save)(mib_Widget *thisw, FILE *fout);
- int (*mib_load)(mib_Widget *thisw, mib_Buffer *fin);
+ mib_Widget *(*mib_create)(mib_Widget *parent, char *name, char *label,
+ int posx, int posy, int width, int height, int mib_fill);
+ void (*mib_delete)(mib_Widget *thisw);
+ void (*mib_save)(mib_Widget *thisw, FILE *fout);
+ int (*mib_load)(mib_Widget *thisw, mib_Buffer *fin);
#else
- mib_Widget *(*mib_create)();
- void (*mib_delete)();
- void (*mib_save)();
- int (*mib_load)();
+ mib_Widget *(*mib_create)();
+ void (*mib_delete)();
+ void (*mib_save)();
+ int (*mib_load)();
#endif
} mib_widget_funcs;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_State.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_State.h
index e088d097403..e585f00f01b 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_State.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_State.h
@@ -1,10 +1,15 @@
/* _*_ C++ _*_ */
// $Id$
-#if !defined (_MPEG_AUDIO_CONTROL_STATE_H)
+#ifndef _MPEG_AUDIO_CONTROL_STATE_H
#define _MPEG_AUDIO_CONTROL_STATE_H
#include "ace/Singleton.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "mpeg_shared/Audio_ControlS.h"
#include "Globals.h"
@@ -30,7 +35,7 @@ public:
virtual CORBA::Boolean play (const Audio_Control::PLAYPara & para,
CORBA::Long_out ats) ;
-
+
virtual CORBA::Boolean speed (const Audio_Control::SPEEDPara & para) ;
virtual CORBA::Boolean stop (CORBA::Long cmdsn) ;
@@ -38,13 +43,13 @@ public:
virtual void close (void) ;
protected:
Audio_States state_;
- // The state
+ // The state
Audio_Global *audio_global_;
// Pointer to the global.
Audio_Control_i *audio_control_i_;
};
-
+
class Audio_Control_Waiting_State : public virtual Audio_Control_State
{
@@ -72,8 +77,8 @@ public:
};
typedef ACE_Singleton <Audio_Control_Waiting_State, ACE_SYNCH_MUTEX>
- AUDIO_CONTROL_WAITING_STATE;
+ AUDIO_CONTROL_WAITING_STATE;
typedef ACE_Singleton <Audio_Control_Play_State, ACE_SYNCH_MUTEX>
- AUDIO_CONTROL_PLAY_STATE;
+ AUDIO_CONTROL_PLAY_STATE;
#endif /*_MPEG_AUDIO_CONTROL_STATE_H */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_i.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_i.h
index d6c7c74c2d0..001bfccb423 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_i.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Control_i.h
@@ -1,7 +1,7 @@
/* _*_ C++ _*_ */
//$Id$
-#if !defined (_AV_AUDIO_CONTROL_H)
+#ifndef _AV_AUDIO_CONTROL_H
#define _AV_AUDIO_CONTROL_H
#include "mpeg_shared/Audio_ControlS.h"
@@ -19,7 +19,7 @@ public:
~Audio_Control_i (void);
// Default destructor
-
+
int create_handlers (void);
// creates the data and sig handlers.
@@ -53,23 +53,23 @@ public:
virtual void close (
CORBA::Environment &_tao_environment
) ;
-
+
void change_state (Audio_Control_State *state);
// Changes the state of the Audio Control object.
-
+
Audio_Control_State *get_state (void);
// gets the state.
private:
int register_handlers (void);
-
+
ACE_Reactor *reactor_;
-
+
Audio_Control_State *state_;
-
+
Audio_Data_Handler *data_handler_;
-
+
Audio_Sig_Handler *sig_handler_;
-
+
ACE_SOCK_CODgram dgram_;
Audio_Global *audio_global_;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Server.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Server.h
index 8f80cf0834a..473827a2adb 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Server.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Audio_Server.h
@@ -1,7 +1,7 @@
/* -*- C++ -*- */
//$Id$
-#if !defined (_AUDIO_SERVER_H)
+#ifndef _AUDIO_SERVER_H
#define _AUDIO_SERVER_H
#include <sys/types.h>
@@ -28,13 +28,18 @@
#include "server_proto.h"
#include "ace/SOCK_CODgram.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "ace/SOCK_Stream.h"
#include "tao/TAO.h"
#include "mpeg_shared/Audio_ControlS.h"
#include "orbsvcs/CosNamingC.h"
#include "Globals.h"
-class Audio_Sig_Handler
+class Audio_Sig_Handler
: public virtual ACE_Event_Handler
{
// = TITLE
@@ -49,7 +54,7 @@ public:
// this will register this sig_handler
// with the reactor for SIGALRM
- virtual int shutdown (ACE_HANDLE,
+ virtual int shutdown (ACE_HANDLE,
ACE_Reactor_Mask);
virtual int handle_input (ACE_HANDLE);
@@ -68,7 +73,7 @@ class Audio_Data_Handler : public virtual ACE_Event_Handler
public:
Audio_Data_Handler (ACE_HANDLE data_fd,
Audio_Global *audio_global);
-
+
// Constructor
virtual int handle_input (ACE_HANDLE fd = ACE_INVALID_HANDLE);
@@ -96,17 +101,17 @@ public:
virtual int handle_stop (const AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
// Application needs to define this
-
- virtual int handle_start (const AVStreams::flowSpec &the_spec,
+
+ virtual int handle_start (const AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
// Application needs to define this
-
- virtual int handle_destroy (const AVStreams::flowSpec &the_spec,
+
+ virtual int handle_destroy (const AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
// Application needs to define this
- virtual CORBA::Boolean handle_connection_requested (AVStreams::flowSpec &the_spec,
+ virtual CORBA::Boolean handle_connection_requested (AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
private:
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Globals.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Globals.h
index 74f74cfb5d5..c7740c4ccda 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Globals.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Globals.h
@@ -2,22 +2,22 @@
// $Id$
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -25,24 +25,29 @@
* email: scen@cse.ogi.edu
*/
-#if !defined (MPEG_GLOBAL_H)
+#ifndef MPEG_GLOBAL_H
#define MPEG_GLOBAL_H
#include "ace/SOCK_CODgram.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
// Global symbols, these need to become enums eventually.
#define SESSION_NUM 4
-#define CONN_INET 1
-#define CONN_UNIX 2
-#define CONN_ATM 3
+#define CONN_INET 1
+#define CONN_UNIX 2
+#define CONN_ATM 3
-#define SERVER_FDTABLE_SIZE 50
-#define CLIENT_FDTABLE_SIZE 10
+#define SERVER_FDTABLE_SIZE 50
+#define CLIENT_FDTABLE_SIZE 10
-#define STATE_PENDING 1
-#define STATE_CONTROL 2
-#define STATE_DATA 3
-#define STATE_SINGLE 4
+#define STATE_PENDING 1
+#define STATE_CONTROL 2
+#define STATE_DATA 3
+#define STATE_SINGLE 4
#define min(a, b) ((a) > (b) ? (b) : (a))
#define max(a, b) ((a) > (b) ? (a) : (b))
@@ -63,49 +68,49 @@
// Global definitions
#define nextByte {int val; fileptr ++; \
- if ((val = getc(VIDEO_SINGLETON::instance ()->fp)) == EOF) \
- {\
- perror("Crossed EOF or error while scanning"); \
- return 1; \
- } nb = val;}
+ if ((val = getc(VIDEO_SINGLETON::instance ()->fp)) == EOF) \
+ {\
+ perror("Crossed EOF or error while scanning"); \
+ return 1; \
+ } nb = val;}
#define computePicSize \
- if (inpic) \
- { \
- if (pictype == 'I') \
- { \
- VIDEO_SINGLETON::instance ()->maxI = max(VIDEO_SINGLETON::instance ()->maxI, (int)(fileptr - picptr - 4)); \
- VIDEO_SINGLETON::instance ()->minI = min(VIDEO_SINGLETON::instance ()->minI, (int)(fileptr - picptr - 4)); \
- } \
- else if (pictype == 'P') \
- { \
- VIDEO_SINGLETON::instance ()->maxP = max(VIDEO_SINGLETON::instance ()->maxP, (int)(fileptr - picptr - 4)); \
- VIDEO_SINGLETON::instance ()->minP = min(VIDEO_SINGLETON::instance ()->minP, (int)(fileptr - picptr - 4)); \
- } \
- else \
- { \
- VIDEO_SINGLETON::instance ()->maxB = max(VIDEO_SINGLETON::instance ()->maxB, (int)(fileptr - picptr - 4)); \
- VIDEO_SINGLETON::instance ()->minB = min(VIDEO_SINGLETON::instance ()->minB, (int)(fileptr - picptr - 4)); \
- } \
- VIDEO_SINGLETON::instance ()->frameTable[ftptr].type = pictype; \
- VIDEO_SINGLETON::instance ()->frameTable[ftptr++].size = (int)(fileptr - picptr - 4); \
- inpic = 0; \
- }
+ if (inpic) \
+ { \
+ if (pictype == 'I') \
+ { \
+ VIDEO_SINGLETON::instance ()->maxI = max(VIDEO_SINGLETON::instance ()->maxI, (int)(fileptr - picptr - 4)); \
+ VIDEO_SINGLETON::instance ()->minI = min(VIDEO_SINGLETON::instance ()->minI, (int)(fileptr - picptr - 4)); \
+ } \
+ else if (pictype == 'P') \
+ { \
+ VIDEO_SINGLETON::instance ()->maxP = max(VIDEO_SINGLETON::instance ()->maxP, (int)(fileptr - picptr - 4)); \
+ VIDEO_SINGLETON::instance ()->minP = min(VIDEO_SINGLETON::instance ()->minP, (int)(fileptr - picptr - 4)); \
+ } \
+ else \
+ { \
+ VIDEO_SINGLETON::instance ()->maxB = max(VIDEO_SINGLETON::instance ()->maxB, (int)(fileptr - picptr - 4)); \
+ VIDEO_SINGLETON::instance ()->minB = min(VIDEO_SINGLETON::instance ()->minB, (int)(fileptr - picptr - 4)); \
+ } \
+ VIDEO_SINGLETON::instance ()->frameTable[ftptr].type = pictype; \
+ VIDEO_SINGLETON::instance ()->frameTable[ftptr++].size = (int)(fileptr - picptr - 4); \
+ inpic = 0; \
+ }
#define FileRead(position, buf, size) \
- { \
- if (fseek(VIDEO_SINGLETON::instance ()->fp, (position), 0) == -1) \
- { \
- perror("VS error on fseek VideoFile"); \
- return (-1); \
- } \
- while (fread((buf), (size), 1, VIDEO_SINGLETON::instance ()->fp) == 0) \
- { if (errno == EINTR) { errno = 0; continue;}\
+ { \
+ if (fseek(VIDEO_SINGLETON::instance ()->fp, (position), 0) == -1) \
+ { \
+ perror("VS error on fseek VideoFile"); \
+ return (-1); \
+ } \
+ while (fread((buf), (size), 1, VIDEO_SINGLETON::instance ()->fp) == 0) \
+ { if (errno == EINTR) { errno = 0; continue;}\
perror("VS error on fread VideoFile"); \
return (-1); \
- } \
- }
+ } \
+ }
#define CheckFrameRange(pnextFrame) \
{ if ((pnextFrame) < 0 || (pnextFrame) >= VIDEO_SINGLETON::instance ()->numF) \
@@ -121,7 +126,7 @@
#include "include/common.h"
#include "mpeg_shared/routine.h"
#include "mpeg_shared/fileio.h"
-#include "mpeg_shared/com.h"
+#include "mpeg_shared/com.h"
#include "mpeg_shared/sendpt.h"
#include "mpeg_server/server_proto.h"
#include "mpeg_server/Video_Server.h"
@@ -205,7 +210,7 @@ public:
int fileSize;
int maxS;
- int maxG;
+ int maxG;
int maxI;
int maxP;
int maxB;
@@ -252,7 +257,7 @@ public:
char type;
unsigned short size;
} * frameTable;
-
+
int preGroup;
int preHeader;
int preFrame;
@@ -266,10 +271,10 @@ public:
// globals functions
int CmdRead (char *buf, int psize);
int CmdWrite (char *buf, int size);
- int SendPacket (int shtag,
- int gop,
- int frame,
- int timeToUse,
+ int SendPacket (int shtag,
+ int gop,
+ int frame,
+ int timeToUse,
int first_time = 0);
int FBread (char *buf, int size);
int PLAYliveVideo (PLAYpara * para);
@@ -358,7 +363,7 @@ public:
int addSamples;
unsigned nextTime;
int upp; /* micro-seconds per packet */
- int delta_sps ;
+ int delta_sps ;
// The members previously in PLAY audio.
int bytes_sent ;
@@ -389,6 +394,6 @@ public:
typedef ACE_Singleton <Audio_Global,ACE_SYNCH_MUTEX> AUDIO_GLOBAL;
-
+
#endif /* define MPEG_GLOBAL_H */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_State.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_State.h
index d9af5a73250..9363a48ea0d 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_State.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_State.h
@@ -4,22 +4,22 @@
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -27,10 +27,15 @@
* email: scen@cse.ogi.edu
*/
-#if !defined (MPEG_VIDEO_CONTROL_STATE_H)
+#ifndef MPEG_VIDEO_CONTROL_STATE_H
#define MPEG_VIDEO_CONTROL_STATE_H
#include "ace/Singleton.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "mpeg_shared/Video_ControlS.h"
#include "mpeg_server/Video_Control_i.h"
@@ -50,7 +55,7 @@ public:
Video_Control_State (void);
// constructor
- enum Video_States
+ enum Video_States
{
VIDEO_WAITING,
VIDEO_PLAY = 1,
@@ -66,12 +71,12 @@ public:
virtual CORBA::Boolean init_video (const Video_Control::INITvideoPara &para,
Video_Control::INITvideoReply_out reply) ;
-
+
virtual CORBA::Boolean stat_stream (CORBA::Char_out ch,
CORBA::Long_out size);
virtual void close (void);
-
+
virtual CORBA::Boolean stat_sent (void);
virtual CORBA::Boolean fast_forward (const Video_Control::FFpara &para) ;
@@ -79,7 +84,7 @@ public:
virtual CORBA::Boolean fast_backward (const Video_Control::FFpara &para) ;
virtual CORBA::Boolean step (const Video_Control::STEPpara &para) ;
-
+
virtual CORBA::Boolean play (const Video_Control::PLAYpara &para,
CORBA::Long_out vts) ;
@@ -88,13 +93,13 @@ public:
virtual CORBA::Boolean speed (const Video_Control::SPEEDpara &para) ;
virtual CORBA::Boolean stop (CORBA::Long cmdsn) ;
-
+
protected:
Video_States state_;
// State of this object
Video_Control_i *vci_;
-
+
};
class Video_Control_Waiting_State : public virtual Video_Control_State
@@ -105,20 +110,20 @@ class Video_Control_Waiting_State : public virtual Video_Control_State
public:
Video_Control_Waiting_State (void);
// Default constructor, sets the state to WAITING
-
+
virtual CORBA::Boolean stat_stream (CORBA::Char_out ch,
CORBA::Long_out size);
-
+
virtual void close (void);
-
+
virtual CORBA::Boolean stat_sent (void);
-
+
virtual CORBA::Boolean fast_forward (const Video_Control::FFpara &para);
-
+
virtual CORBA::Boolean fast_backward (const Video_Control::FFpara &para);
virtual CORBA::Boolean step (const Video_Control::STEPpara &para);
-
+
virtual CORBA::Boolean play (const Video_Control::PLAYpara &para,
CORBA::Long_out vts);
@@ -173,9 +178,9 @@ public:
};
typedef ACE_Singleton <Video_Control_Waiting_State, ACE_SYNCH_MUTEX>
- VIDEO_CONTROL_WAITING_STATE;
+ VIDEO_CONTROL_WAITING_STATE;
typedef ACE_Singleton <Video_Control_Play_State, ACE_SYNCH_MUTEX>
- VIDEO_CONTROL_PLAY_STATE;
+ VIDEO_CONTROL_PLAY_STATE;
typedef ACE_Singleton <Video_Control_Fast_Forward_State, ACE_SYNCH_MUTEX>
VIDEO_CONTROL_FAST_FORWARD_STATE;
typedef ACE_Singleton <Video_Control_Fast_Backward_State, ACE_SYNCH_MUTEX>
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_i.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_i.h
index 52e5d0f96b1..55b782a0e97 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_i.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Control_i.h
@@ -1,7 +1,7 @@
/* -*- C++ -*- */
// $Id$
-#if !defined (AV_VIDEO_CONTROL_H)
+#ifndef AV_VIDEO_CONTROL_H
#define AV_VIDEO_CONTROL_H
#include "mpeg_shared/Video_ControlS.h"
@@ -24,13 +24,13 @@ public:
virtual CORBA::Boolean init_video (const Video_Control::INITvideoPara &para,
Video_Control::INITvideoReply_out reply,
CORBA::Environment &_tao_environment);
-
+
virtual CORBA::Boolean stat_stream (CORBA::Char_out ch,
CORBA::Long_out size,
CORBA::Environment &_tao_environment);
virtual void close (CORBA::Environment &_tao_environment);
-
+
virtual CORBA::Boolean stat_sent (CORBA::Environment &_tao_environment);
virtual CORBA::Boolean fast_forward (const Video_Control::FFpara &para,
@@ -42,7 +42,7 @@ public:
virtual CORBA::Boolean step (const Video_Control::STEPpara &para,
CORBA::Environment &_tao_environment);
-
+
virtual CORBA::Boolean play (const Video_Control::PLAYpara &para,
CORBA::Long_out vts,
CORBA::Environment &_tao_environment);
@@ -58,14 +58,14 @@ public:
virtual CORBA::Boolean set_peer (char * &peer,
CORBA::Environment &_tao_environment);
- // called by the client to inform us about it's ip and
+ // called by the client to inform us about it's ip and
// udp address.
void change_state (Video_Control_State *state);
// Used to change the state
Video_Control_State *get_state (void);
- // Accessor for the state_
+ // Accessor for the state_
virtual ~Video_Control_i (void);
// Destructor
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Server.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Server.h
index e50b1ec373e..29ba6ea2d7a 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Server.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/Video_Server.h
@@ -3,22 +3,22 @@
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -26,16 +26,21 @@
* email: scen@cse.ogi.edu
*/
-#if !defined (MPEG_VIDEO_SERVER_H)
+#ifndef MPEG_VIDEO_SERVER_H
#define MPEG_VIDEO_SERVER_H
#include "ace/Reactor.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "ace/Event_Handler.h"
#include "tao/TAO.h"
#include "include/common.h"
#include "mpeg_shared/fileio.h"
-#include "mpeg_shared/com.h"
+#include "mpeg_shared/com.h"
#include "mpeg_shared/routine.h"
#include "mpeg_shared/sendpt.h"
#include "mpeg_shared/Video_ControlS.h"
@@ -47,7 +52,7 @@
class Video_Control_i;
-class Video_Sig_Handler
+class Video_Sig_Handler
: public virtual ACE_Event_Handler
{
// = TITLE
@@ -69,7 +74,7 @@ public:
// this will register this sig_handler
// with the reactor for SIGALRM
- virtual int shutdown (ACE_HANDLE,
+ virtual int shutdown (ACE_HANDLE,
ACE_Reactor_Mask);
virtual int handle_input (ACE_HANDLE);
@@ -109,7 +114,7 @@ public:
private:
Video_Control_i *vci_;
-
+
};
// The stream endpoint
@@ -126,22 +131,22 @@ public:
virtual int handle_stop (const AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
// Application needs to define this
-
- virtual int handle_start (const AVStreams::flowSpec &the_spec,
+
+ virtual int handle_start (const AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
// Application needs to define this
-
- virtual int handle_destroy (const AVStreams::flowSpec &the_spec,
+
+ virtual int handle_destroy (const AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
// Application needs to define this
- virtual CORBA::Boolean handle_connection_requested (AVStreams::flowSpec &the_spec,
+ virtual CORBA::Boolean handle_connection_requested (AVStreams::flowSpec &the_spec,
CORBA::Environment &env) ;
private:
ACE_SOCK_CODgram dgram_;
-
+
};
#endif /* MPEG_VIDEO_SERVER_H */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/server_proto.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/server_proto.h
index 12aab8421c5..2076b2921c5 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/server_proto.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_server/server_proto.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -43,11 +43,11 @@ void LeaveLiveVideo(void);
/* each child forked not doing live video should call this */
void ExitLiveVideo(void);
int OpenLiveVideo(int * format,
- int * width, int * height,
- int * averageFrameSize,
- double * fps,
- int * pelAspactRatio /* MPEG1 encoding used here */
- ); /* -1 -- failed, 0 - succ */
+ int * width, int * height,
+ int * averageFrameSize,
+ double * fps,
+ int * pelAspactRatio /* MPEG1 encoding used here */
+ ); /* -1 -- failed, 0 - succ */
void StartPlayLiveVideo(void);
void StopPlayLiveVideo(void);
int ReadLiveVideoPicture(int * frame, char * buf, int size); /* ret # bytes */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/com.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/com.h
index 98e82aeb26c..cf97b4b1796 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/com.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/com.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -26,32 +26,32 @@
/*
Some assumptions about the streams created in this file:
- PACKET STREAM:
-
- * send(), recv() may not work, we can only use
- read()/write().
-
- * write(): either send the whole packet, or send nothing
+ PACKET STREAM:
+
+ * send(), recv() may not work, we can only use
+ read()/write().
+
+ * write(): either send the whole packet, or send nothing
- * read(): read() will read the minimun of the
- requested number of bytes and current packet size.
- read() can read part of a packet, but it
- will not read cross packet boundaris
+ * read(): read() will read the minimun of the
+ requested number of bytes and current packet size.
+ read() can read part of a packet, but it
+ will not read cross packet boundaris
- There are two modes: non-discard and dicard. If a packets is
- not read all its bytes, the remaining bytes will be
- or not be discarded.
+ There are two modes: non-discard and dicard. If a packets is
+ not read all its bytes, the remaining bytes will be
+ or not be discarded.
- This is indicated by if (*max_pkt_size) is positive
- (non-discard) or negative (discard)
+ This is indicated by if (*max_pkt_size) is positive
+ (non-discard) or negative (discard)
- BYTE_STREAM: reliable
+ BYTE_STREAM: reliable
- * write(): might write only part of requested bytes
- each time. (this is the case in SunOS4)
+ * write(): might write only part of requested bytes
+ each time. (this is the case in SunOS4)
- * read(): might read less than requested bytes.
- (this is the case in SunOS4).
+ * read(): might read less than requested bytes.
+ (this is the case in SunOS4).
*/
/* returns: -1 -- failed, 0 -- successful */
@@ -64,7 +64,7 @@ void ComCloseClient(void);
"" -- UNIX socket, reliable byte stream
[INET:]real_address -- INET sockets, reliable control byte stream, and
*max_pkt_size == 0 : reliable data byte stream, or
- != 0 : unreliable packet stream;
+ != 0 : unreliable packet stream;
ATM:real_address -- ATM sockets, both data and control are
unreliable packet streams;
DATM:real_address -- INET/UNIX control reliable byte stream
@@ -73,14 +73,14 @@ void ComCloseClient(void);
returns: -1 -- failed, 0 -- successful
*ctr_fd -- control connection file descriptor
*data_fd -- data connection file descriptor
- *max_pkt_size -- == 0 : reliable BYTE_STREAM
- > 0 : unreliable non-discard PACKET STREAM
- with given maximum packet size (bytes);
- < 0 : unreliable discard PACKET STREAM
- with given maximum packet size (bytes);
+ *max_pkt_size -- == 0 : reliable BYTE_STREAM
+ > 0 : unreliable non-discard PACKET STREAM
+ with given maximum packet size (bytes);
+ < 0 : unreliable discard PACKET STREAM
+ with given maximum packet size (bytes);
It is suggested that if a BYTE_STREAM is not known to be discarded,
- than it is safer to indicate it as discard.
+ than it is safer to indicate it as discard.
*/
int ComOpenConnPair(char * address, int *ctr_fd, int *data_fd, int *max_pkt_size);
int VideoComOpenConnPair(char * address, int *ctr_fd, int *data_fd, int *max_pkt_size);
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/fileio.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/fileio.h
index 46432a71797..640037cbd5c 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/fileio.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/fileio.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -25,7 +25,7 @@
*/
/* data structure used by StatFile() */
-#if !defined (_MPEG_FILE_IO_H)
+#ifndef _MPEG_FILE_IO_H
#define _MPEG_FILE_IO_H
struct StatBuf
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/filters.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/filters.h
index 7befdfaa20d..673cf5a6804 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/filters.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/filters.h
@@ -1,31 +1,31 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
* Department of Computer Science and Engineering
* email: scen@cse.ogi.edu
*/
-#define FILTER_LOWPASS 0
-#define FILTER_MEDIAN 1
-#define FILTER_AVERAGE 2
+#define FILTER_LOWPASS 0
+#define FILTER_MEDIAN 1
+#define FILTER_AVERAGE 2
typedef struct MedianFilter {
int type;
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/routine.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/routine.h
index 61a011217d9..fa55050458b 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/routine.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/routine.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -24,7 +24,7 @@
* email: scen@cse.ogi.edu
*/
/* routine.c */
-#if !defined (_MPEG_ROUTINE_H)
+#ifndef _MPEG_ROUTINE_H
#define _MPEG_ROUTINE_H
#include "include/common.h"
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
index f7d2adae6e0..60935fae8ed 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/mpeg_shared/sendpt.h
@@ -1,22 +1,22 @@
/* $Id$ */
/* Copyright (c) 1995 Oregon Graduate Institute of Science and Technology
* P.O.Box 91000-1000, Portland, OR 97291, USA;
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of O.G.I. not be used in advertising or
- * publicity pertaining to distribution of the software without specific,
- * written prior permission. O.G.I. makes no representations about the
- * suitability of this software for any purpose. It is provided "as is"
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of O.G.I. not be used in advertising or
+ * publicity pertaining to distribution of the software without specific,
+ * written prior permission. O.G.I. makes no representations about the
+ * suitability of this software for any purpose. It is provided "as is"
* without express or implied warranty.
- *
- * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
- * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
- * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
- * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
- * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ *
+ * O.G.I. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+ * O.G.I. BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY
+ * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
+ * AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
* Author: Shanwei Cen
@@ -31,5 +31,9 @@
*/
#include "ace/OS.h"
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
void ComputeSendPattern(char * pat, char * buf, int len, int f);
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Machine_Properties.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Machine_Properties.h
index 79072ae4877..99c6079a419 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Machine_Properties.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Machine_Properties.h
@@ -9,7 +9,7 @@
// = DESCRIPTION
// As a trading service dynamic property, retrieves machine
// statistics from the rstatd using Sun RPC.
-//
+//
// = AUTHORS
// Seth Widoff <sbw1@cs.wustl.edu>
//
@@ -31,7 +31,7 @@ class TAO_Machine_Properties :
{
public:
- enum PROP_TYPES
+ enum PROP_TYPES
{
CPU,
DISK,
@@ -47,11 +47,11 @@ public:
static const int NUM_PROPERTIES;
static const char* PROP_NAMES[];
-
+
TAO_Machine_Properties (void);
-
- TAO_Machine_Properties (const ACE_Time_Value& timeout);
-
+
+ TAO_Machine_Properties (const ACE_Time_Value& timeout);
+
virtual CORBA::Any* evalDP (const char* name,
CORBA::TypeCode_ptr returned_type,
const CORBA::Any& extra_info,
@@ -66,11 +66,11 @@ public:
virtual int define_properties
(CosTradingRepos::ServiceTypeRepository::PropStructSeq& prop_seq,
CORBA::ULong offset = 0) const;
-
+
private:
void init (void);
-
+
int retrieve_stats (void);
void compute_cpu (CORBA::Any& value, int elapsed_time);
@@ -83,15 +83,15 @@ private:
void compute_collisions (CORBA::Any& value, int elapsed_time);
void compute_interrupts (CORBA::Any& value, int elapsed_time);
void compute_load (CORBA::Any& value, int elapsed_time);
-
- const ACE_Time_Value timeout_;
+
+ const ACE_Time_Value timeout_;
ACE_Time_Value timestamp_;
ACE_Time_Value sample_time_;
-
+
statstime stats_;
statstime old_stats_;
CLIENT* rstat_client_;
-
+
};
#endif /* TAO_MACHINE_PROPERTIES */
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Property_Exporter.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Property_Exporter.h
index 3db368a5bb5..4c236f3e8bb 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Property_Exporter.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Property_Exporter.h
@@ -2,7 +2,7 @@
// ========================================================================
// $Id$
-//
+//
// = LIBRARY
// TAO/orbsvcs/orbsvcs
//
@@ -12,13 +12,13 @@
// = DESCRIPTION
// Allows a service to export properties to both a Property Set and
// a Trading Service simulatenously.
-//
+//
// = AUTHORS
// Seth Widoff <sbw1@cs.wustl.edu>
//
// ========================================================================
-#if ! defined (TAO_PROPERTY_EXPORTER_H)
+#ifndef TAO_PROPERTY_EXPORTER_H
#define TAO_PROPERTY_EXPORTER_H
#include "orbsvcs/CosTradingC.h"
@@ -42,13 +42,13 @@ public:
(CosTradingRepos::ServiceTypeRepository::PropStructSeq& prop_seq,
CORBA::ULong offset = 0) const = 0;
// Append property definitions to the service type defintition
- // sequence. The <offset> is the point at which the method can begin
+ // sequence. The <offset> is the point at which the method can begin
// placing the PropStructures. define_properties returns the number
// of properties inserted from the offset.
};
-class TAO_Property_Exporter
+class TAO_Property_Exporter
// = TITLE
// Publish public properties of a servant to a
// CosPropertyService::PropSet instance and a Trading Service
@@ -62,82 +62,82 @@ class TAO_Property_Exporter
public:
TAO_Property_Exporter (CosTrading::Lookup_var lookup_if,
- CosPropertyService::PropertySet_ptr prop_set,
- CORBA::ULong initial_size = 10);
-
-
+ CosPropertyService::PropertySet_ptr prop_set,
+ CORBA::ULong initial_size = 10);
+
+
~TAO_Property_Exporter (void);
// Delete all Dynamic Property adapters
-
+
void add_static_property (const char* name,
- const CORBA::Any& value);
+ const CORBA::Any& value);
// Add a property to the Offer and the PropSet.
-
+
void add_dynamic_property (const char* name,
- const CORBA::Any& intial_value,
- TAO_Dynamic_Property& dp);
+ const CORBA::Any& intial_value,
+ TAO_Dynamic_Property& dp);
// Add a property to the PropSet and a dynamic property to the
// Offer. Have the dynamic property connect to the PropSet accessor
- // for that name.
+ // for that name.
void add_dynamic_property (const char* name,
- CosTradingDynamic::DynamicProp& dp_struct);
+ CosTradingDynamic::DynamicProp& dp_struct);
void add_dynamic_property (const char* name,
- CosTradingDynamic::DynamicProp* dp_struct);
-
+ CosTradingDynamic::DynamicProp* dp_struct);
+
CosTrading::OfferId export (const CORBA::Object_ptr object_ref,
- const CosTrading::ServiceTypeName type,
- CORBA::Environment& _env)
+ const CosTrading::ServiceTypeName type,
+ CORBA::Environment& _env)
TAO_THROW_SPEC ((CORBA::SystemException,
- CosPropertyService::MultipleExceptions,
- CosTrading::Register::InvalidObjectRef,
- CosTrading::IllegalServiceType,
- CosTrading::UnknownServiceType,
- CosTrading::Register::InterfaceTypeMismatch,
- CosTrading::IllegalPropertyName,
- CosTrading::PropertyTypeMismatch,
- CosTrading::ReadonlyDynamicProperty,
- CosTrading::MissingMandatoryProperty,
- CosTrading::DuplicatePropertyName));
+ CosPropertyService::MultipleExceptions,
+ CosTrading::Register::InvalidObjectRef,
+ CosTrading::IllegalServiceType,
+ CosTrading::UnknownServiceType,
+ CosTrading::Register::InterfaceTypeMismatch,
+ CosTrading::IllegalPropertyName,
+ CosTrading::PropertyTypeMismatch,
+ CosTrading::ReadonlyDynamicProperty,
+ CosTrading::MissingMandatoryProperty,
+ CosTrading::DuplicatePropertyName));
// Export the offer to the trader under the given type.
-
+
typedef CosTradingRepos::ServiceTypeRepository TRADING_REPOS;
CosTrading::OfferId export (const CORBA::Object_ptr object_ref,
- const CosTrading::ServiceTypeName type,
- const TRADING_REPOS::PropStructSeq& props,
- const TRADING_REPOS::ServiceTypeNameSeq& stypes,
- CORBA::Environment& _env)
+ const CosTrading::ServiceTypeName type,
+ const TRADING_REPOS::PropStructSeq& props,
+ const TRADING_REPOS::ServiceTypeNameSeq& stypes,
+ CORBA::Environment& _env)
TAO_THROW_SPEC ((CORBA::SystemException,
- CosPropertyService::MultipleExceptions,
- CosTrading::IllegalServiceType,
- TRADING_REPOS::ServiceTypeExists,
- TRADING_REPOS::InterfaceTypeMismatch,
- CosTrading::IllegalPropertyName,
- CosTrading::DuplicatePropertyName,
- TRADING_REPOS::ValueTypeRedefinition,
- TRADING_REPOS::DuplicateServiceTypeName,
- CosTrading::Register::InvalidObjectRef,
- CosTrading::Register::InterfaceTypeMismatch,
- CosTrading::ReadonlyDynamicProperty,
- CosTrading::MissingMandatoryProperty,
- CosTrading::DuplicatePropertyName));
+ CosPropertyService::MultipleExceptions,
+ CosTrading::IllegalServiceType,
+ TRADING_REPOS::ServiceTypeExists,
+ TRADING_REPOS::InterfaceTypeMismatch,
+ CosTrading::IllegalPropertyName,
+ CosTrading::DuplicatePropertyName,
+ TRADING_REPOS::ValueTypeRedefinition,
+ TRADING_REPOS::DuplicateServiceTypeName,
+ CosTrading::Register::InvalidObjectRef,
+ CosTrading::Register::InterfaceTypeMismatch,
+ CosTrading::ReadonlyDynamicProperty,
+ CosTrading::MissingMandatoryProperty,
+ CosTrading::DuplicatePropertyName));
// Export the offer to the trader under the given type. Register the
// type with the current definition if the type can't be found in
// the service type repository.
-
+
private:
-
+
TAO_Property_Exporter (const TAO_Property_Exporter&);
void operator= (const TAO_Property_Exporter&);
// These don't make sense on this class.
const int increment_;
-
+
CosTrading::Lookup_var lookup_;
CosPropertyService::PropertySet_var prop_set_;
- CORBA::ULong pcount_, tcount_;
+ CORBA::ULong pcount_, tcount_;
CosTrading::PropertySeq tprops_;
CosPropertyService::Properties pprops_;
};
@@ -156,38 +156,38 @@ class TAO_Property_Modifier
public:
TAO_Property_Modifier (CosTrading::Lookup_var lookup_if,
- CosPropertyService::PropertySet_ptr prop_set,
- CORBA::ULong initial_size = 10);
+ CosPropertyService::PropertySet_ptr prop_set,
+ CORBA::ULong initial_size = 10);
// If no Lookup Interface is provided to the constructor, then
// resolve_initial_references ("TradingService") will be used.
void delete_property (const char* name);
// Remove a property from the current prop_set/offer.
-
+
void modify_property (const char* name, const CORBA::Any& value);
// Modify a property from the current prop_set/offer.
-
+
void commit (CosTrading::OfferId id, CORBA::Environment& _env)
TAO_THROW_SPEC ((CORBA::SystemException,
- CosPropertyService::MultipleExceptions,
- CosTrading::NotImplemented,
- CosTrading::IllegalOfferId,
- CosTrading::UnknownOfferId,
- CosTrading::Register::ProxyOfferId,
- CosTrading::IllegalPropertyName,
- CosTrading::Register::UnknownPropertyName,
- CosTrading::PropertyTypeMismatch,
- CosTrading::ReadonlyDynamicProperty,
- CosTrading::Register::MandatoryProperty,
- CosTrading::Register::ReadonlyProperty,
- CosTrading::DuplicatePropertyName));
+ CosPropertyService::MultipleExceptions,
+ CosTrading::NotImplemented,
+ CosTrading::IllegalOfferId,
+ CosTrading::UnknownOfferId,
+ CosTrading::Register::ProxyOfferId,
+ CosTrading::IllegalPropertyName,
+ CosTrading::Register::UnknownPropertyName,
+ CosTrading::PropertyTypeMismatch,
+ CosTrading::ReadonlyDynamicProperty,
+ CosTrading::Register::MandatoryProperty,
+ CosTrading::Register::ReadonlyProperty,
+ CosTrading::DuplicatePropertyName));
// Commit your changes to the trading service.
private:
const int increment_;
-
+
int pdcount_;
int pmcount_;
@@ -196,13 +196,13 @@ public:
CosTrading::Lookup_var lookup_;
CosPropertyService::PropertySet_var prop_set_;
-
+
CosPropertyService::PropertyNames pdelete_;
CosPropertyService::Properties pmodify_;
-
+
CosTrading::PropertyNameSeq tdelete_;
CosTrading::PropertySeq tmodify_;
-
+
TAO_Property_Modifier (const TAO_Property_Modifier&);
void operator= (const TAO_Property_Modifier&);
// These don't make sense on this class.
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Video_Repository.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Video_Repository.h
index 624635e7244..88dda6f6a5e 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Video_Repository.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/Video_Repository.h
@@ -2,16 +2,16 @@
// ============================================================================
// $Id$
-//
//
-// = FILENAME
+//
+// = FILENAME
// Video_Repository.h
-//
-// = DESCRIPTION
+//
+// = DESCRIPTION
// As a trading service dynamic property, creates a sequence of
// structures, each structure describing a movie in the video
-// repository.
-//
+// repository.
+//
// = AUTHORS
// Seth Widoff <sbw1@cs.wustl.edu>
//
@@ -20,9 +20,14 @@
#if (! defined TAO_VIDEO_REPOSITORY_H)
#define TAO_VIDEO_REPOSITORY_H
-#include "orbsvcs/Trader/Trader_Utils.h"
+#include "orbsvcs/Trader/Trader_Utils.h"
#include "ace/OS.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "Video_RepositoryC.h"
#include "Property_Exporter.h"
@@ -31,7 +36,7 @@ class TAO_Video_Repository :
public TAO_Exportable
// = DESCRIPTION
// When evalDP is invoked by the Dynamic Property Dispatcher, the
-// TAO_Video_Repository parses the database file and creates a Movie
+// TAO_Video_Repository parses the database file and creates a Movie
// Sequence, each structure of which describes a movie in the
// database. The evalDP then crams the sequence into a dynamically
// allocated Any, which it returns to the dispatcher.
@@ -43,21 +48,21 @@ class TAO_Video_Repository :
public:
static const char* MOVIE_INFO;
-
+
TAO_Video_Repository (const char* filename);
// TAO_Video_Repository requires the pathname of the video
// repository database.
~TAO_Video_Repository (void);
-
+
virtual CORBA::Any* evalDP (const char* name,
CORBA::TypeCode_ptr returned_type,
const CORBA::Any& extra_info,
- CORBA::Environment& _env)
+ CORBA::Environment& _env)
TAO_THROW_SPEC ((CosTradingDynamic::DPEvalFailure));
virtual void export_properties (TAO_Property_Exporter& prop_exporter);
-
+
virtual int define_properties
(CosTradingRepos::ServiceTypeRepository::PropStructSeq& prop_seq,
CORBA::ULong offet = 0) const;
@@ -67,9 +72,9 @@ private:
void parse_file (const char* database, int num_lines);
static void obtain_movie_info (const char* file_name,
- TAO_VR::Movie& movie) {}
+ TAO_VR::Movie& movie) {}
// Extract the techincal information from the actual MPEG file.
-
+
TAO_Video_Repository (void) {}
TAO_Video_Repository& operator= (const TAO_Video_Repository& rep)
{ return *this; }
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/as.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/as.h
index bcaf6e8f20e..754917b3a75 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/as.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/as.h
@@ -4,7 +4,7 @@
//
// = LIBRARY
// as
-//
+//
// = FILENAME
// as.h
//
@@ -14,13 +14,18 @@
// = AUTHORS
// Sumedh Mungee (sumedh@cs.wustl.edu)
// Nagarajan Surendran (naga@cs.wustl.edu)
-//
+//
// ============================================================================
-#if !defined (TAO_AV_AS_H)
+#ifndef TAO_AV_AS_H
#define TAO_AV_AS_H
#include "ace/Get_Opt.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "ace/Acceptor.h"
#include "ace/Svc_Handler.h"
#include "ace/SOCK_Acceptor.h"
@@ -28,25 +33,25 @@
#include "ace/SOCK_CODgram.h"
#include "ace/Select_Reactor.h"
-#include "include/common.h"
-#include "mpeg_server/server_proto.h"
-#include "mpeg_shared/fileio.h"
-#include "mpeg_shared/routine.h"
-#include "mpeg_shared/com.h"
+#include "include/common.h"
+#include "mpeg_server/server_proto.h"
+#include "mpeg_shared/fileio.h"
+#include "mpeg_shared/routine.h"
+#include "mpeg_shared/com.h"
#include "mpeg_server/Audio_Control_i.h"
#include "orbsvcs/orbsvcs/Naming/Naming_Utils.h"
#include "mpeg_server/Audio_Server.h"
#include "orbsvcs/AV/AVStreams_i.h"
-class Audio_Child_Process
+class Audio_Child_Process
:public TAO_AV_Child_Process_B <Audio_Server_StreamEndPoint,TAO_VDev,Audio_Control_i>
{
public:
int init (int argc,
char **argv);
// init the Video Singleton.
-
+
int make_mediactrl (Audio_Control_i *&media_ctrl);
};
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/augmented_server.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/augmented_server.h
index c7823f966ed..7083b7cdedd 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/augmented_server.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/augmented_server.h
@@ -5,7 +5,7 @@
//
// = LIBRARY
// server
-//
+//
// = FILENAME
// server.h
//
@@ -15,13 +15,18 @@
// = AUTHORS
// Sumedh Mungee (sumedh@cs.wustl.edu)
// Nagarajan Surendran (naga@cs.wustl.edu)
-//
+//
// ============================================================================
-#if !defined (TAO_AV_SERVER_H)
+#ifndef TAO_AV_SERVER_H
#define TAO_AV_SERVER_H
#include "ace/Get_Opt.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "ace/Acceptor.h"
#include "ace/Svc_Handler.h"
#include "ace/SOCK_Acceptor.h"
@@ -29,11 +34,11 @@
#include "ace/SOCK_CODgram.h"
#include "ace/Select_Reactor.h"
-#include "include/common.h"
-#include "mpeg_server/server_proto.h"
-#include "mpeg_shared/fileio.h"
-#include "mpeg_shared/routine.h"
-#include "mpeg_shared/com.h"
+#include "include/common.h"
+#include "mpeg_server/server_proto.h"
+#include "mpeg_shared/fileio.h"
+#include "mpeg_shared/routine.h"
+#include "mpeg_shared/com.h"
#include "mpeg_server/Video_Control_i.h"
#include "orbsvcs/orbsvcs/Naming/Naming_Utils.h"
@@ -53,25 +58,25 @@
class AV_Audio_MMDevice
: public TAO_MMDevice,
- public TAO_Exportable
+ public TAO_Exportable
{
public:
static const char* NUMBER_OF_CONNECTIONS;
static const char* MAX_CONNECTIONS;
static const char* SERVER_NAME;
-
+
AV_Audio_MMDevice (TAO_AV_Endpoint_Process_Strategy *endpoint_strategy);
// Default constructor
virtual AVStreams::StreamEndPoint_B_ptr
- create_B (AVStreams::StreamCtrl_ptr the_requester,
- AVStreams::VDev_out the_vdev,
- AVStreams::streamQoS &the_qos,
- CORBA::Boolean_out met_qos,
- char *&named_vdev,
- const AVStreams::flowSpec &the_spec,
- CORBA::Environment &env);
+ create_B (AVStreams::StreamCtrl_ptr the_requester,
+ AVStreams::VDev_out the_vdev,
+ AVStreams::streamQoS &the_qos,
+ CORBA::Boolean_out met_qos,
+ char *&named_vdev,
+ const AVStreams::flowSpec &the_spec,
+ CORBA::Environment &env);
// Called by StreamCtrl to create a "B" type streamandpoint and vdev
CORBA::ULong connections (void) const;
@@ -84,7 +89,7 @@ public:
CORBA::ULong offset = 0) const;
private:
-
+
CORBA::ULong connections_;
// Number of active connections
@@ -93,7 +98,7 @@ private:
class AV_Server;
-class AV_Server_Sig_Handler
+class AV_Server_Sig_Handler
: public virtual ACE_Event_Handler
{
public:
@@ -105,7 +110,7 @@ public:
// this will register this sig_handler
// with the reactor for SIGCHLD,SIGTERM,SIGINT
- virtual int shutdown (ACE_HANDLE,
+ virtual int shutdown (ACE_HANDLE,
ACE_Reactor_Mask);
virtual int handle_input (ACE_HANDLE);
@@ -131,7 +136,7 @@ public:
private:
const AV_Server& av_server_;
-
+
ACE_HANDLE handle_;
// dummy handle for the sig handler.
ACE_Sig_Set sig_set;
@@ -140,7 +145,7 @@ private:
class AV_Server
{
// = TITLE
- // Defines a class that abstracts the functionality of a
+ // Defines a class that abstracts the functionality of a
// video and audio server.
//
// = DESCRIPTION
@@ -149,7 +154,7 @@ class AV_Server
public:
static const char* SERVICE_TYPE;
-
+
AV_Server (void);
// constructor
@@ -162,10 +167,10 @@ public:
// Run the AV_Server
void shutdown (void) const;
-
+
static void on_exit_routine (void);
- // Routine called when this process exits.
-
+ // Routine called when this process exits.
+
static pid_t current_pid_;
// %% the pid the server is currently waiting on
@@ -183,7 +188,7 @@ private:
void export_properties (CORBA::Environment& _env);
int resolve_trader (CORBA::Environment& _env);
-
+
TAO_ORB_Manager orb_manager_;
// the TAO ORB manager.
@@ -193,16 +198,16 @@ private:
TAO_Video_Repository video_rep_;
// Dynamic property that assesses the contents of the sever's video
// repository.
-
+
CosTrading::Lookup_var trader_;
// Reference to the Lookup interface of the trading service.
-
+
CosTrading::OfferId_var offer_id_;
// Server offer id.
CosTradingRepos::ServiceTypeRepository::PropStructSeq prop_seq_;
// Service type definition.
-
+
CosNaming::NamingContext_var naming_context_;
// The root naming context of the naming service
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h
index 4d34e1fdfda..e263670efaa 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/server.h
@@ -5,7 +5,7 @@
//
// = LIBRARY
// server
-//
+//
// = FILENAME
// server.h
//
@@ -15,13 +15,18 @@
// = AUTHORS
// Sumedh Mungee (sumedh@cs.wustl.edu)
// Nagarajan Surendran (naga@cs.wustl.edu)
-//
+//
// ============================================================================
-#if !defined (TAO_AV_SERVER_H)
+#ifndef TAO_AV_SERVER_H
#define TAO_AV_SERVER_H
#include "ace/Get_Opt.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "ace/Acceptor.h"
#include "ace/Svc_Handler.h"
#include "ace/SOCK_Acceptor.h"
@@ -29,11 +34,11 @@
#include "ace/SOCK_CODgram.h"
#include "ace/Select_Reactor.h"
-#include "include/common.h"
-#include "mpeg_server/server_proto.h"
-#include "mpeg_shared/fileio.h"
-#include "mpeg_shared/routine.h"
-#include "mpeg_shared/com.h"
+#include "include/common.h"
+#include "mpeg_server/server_proto.h"
+#include "mpeg_shared/fileio.h"
+#include "mpeg_shared/routine.h"
+#include "mpeg_shared/com.h"
#include "mpeg_server/Video_Control_i.h"
#include "orbsvcs/Naming/Naming_Utils.h"
@@ -54,12 +59,12 @@ public:
Audio_MMDevice (TAO_AV_Endpoint_Process_Strategy *endpoint_strategy_);
// Default constructor
- virtual AVStreams::StreamEndPoint_B_ptr create_B (AVStreams::StreamCtrl_ptr the_requester,
- AVStreams::VDev_out the_vdev,
- AVStreams::streamQoS &the_qos,
- CORBA::Boolean_out met_qos,
- char *&named_vdev,
- const AVStreams::flowSpec &the_spec,
+ virtual AVStreams::StreamEndPoint_B_ptr create_B (AVStreams::StreamCtrl_ptr the_requester,
+ AVStreams::VDev_out the_vdev,
+ AVStreams::streamQoS &the_qos,
+ CORBA::Boolean_out met_qos,
+ char *&named_vdev,
+ const AVStreams::flowSpec &the_spec,
CORBA::Environment &env);
// Called by StreamCtrl to create a "B" type streamandpoint and vdev
@@ -69,7 +74,7 @@ private:
// Number of active connections
};
-class AV_Server_Sig_Handler
+class AV_Server_Sig_Handler
: public virtual ACE_Event_Handler
{
public:
@@ -81,7 +86,7 @@ public:
// this will register this sig_handler
// with the reactor for SIGCHLD,SIGTERM,SIGINT
- virtual int shutdown (ACE_HANDLE,
+ virtual int shutdown (ACE_HANDLE,
ACE_Reactor_Mask);
virtual int handle_input (ACE_HANDLE);
@@ -111,14 +116,14 @@ private:
ACE_Sig_Set sig_set;
TAO_Naming_Client my_name_client_;
- // Name_Client used for unregistering the audio and video
-
+ // Name_Client used for unregistering the audio and video
+
};
class AV_Server
{
// = TITLE
- // Defines a class that abstracts the functionality of a
+ // Defines a class that abstracts the functionality of a
// video and audio server.
//
// = DESCRIPTION
diff --git a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/vs.h b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/vs.h
index 21060b26626..a8dc2a63f55 100644
--- a/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/vs.h
+++ b/TAO/orbsvcs/tests/AVStreams/mpeg/source/server/vs.h
@@ -5,7 +5,7 @@
//
// = LIBRARY
// vs
-//
+//
// = FILENAME
// vs.h
//
@@ -15,13 +15,18 @@
// = AUTHORS
// Sumedh Mungee (sumedh@cs.wustl.edu)
// Nagarajan Surendran (naga@cs.wustl.edu)
-//
+//
// ============================================================================
-#if !defined (TAO_AV_VS_H)
+#ifndef TAO_AV_VS_H
#define TAO_AV_VS_H
#include "ace/Get_Opt.h"
+
+#if !defined (ACE_LACKS_PRAGMA_ONCE)
+# pragma once
+#endif /* ACE_LACKS_PRAGMA_ONCE */
+
#include "ace/Acceptor.h"
#include "ace/Svc_Handler.h"
#include "ace/SOCK_Acceptor.h"
@@ -29,25 +34,25 @@
#include "ace/SOCK_CODgram.h"
#include "ace/Select_Reactor.h"
-#include "include/common.h"
-#include "mpeg_server/server_proto.h"
-#include "mpeg_shared/fileio.h"
-#include "mpeg_shared/routine.h"
-#include "mpeg_shared/com.h"
+#include "include/common.h"
+#include "mpeg_server/server_proto.h"
+#include "mpeg_shared/fileio.h"
+#include "mpeg_shared/routine.h"
+#include "mpeg_shared/com.h"
#include "mpeg_server/Video_Control_i.h"
#include "orbsvcs/orbsvcs/Naming/Naming_Utils.h"
#include "mpeg_server/Video_Server.h"
#include "orbsvcs/AV/AVStreams_i.h"
-class Video_Child_Process
+class Video_Child_Process
:public TAO_AV_Child_Process_B <Video_Server_StreamEndPoint,TAO_VDev,Video_Control_i>
{
public:
int init (int argc,
char **argv);
// init the Video Singleton.
-
+
int make_mediactrl (Video_Control_i *&media_ctrl);
};