This is MPEGView.h in view mode; [Download] [Up]
// MPEGView.h
#import <appkit/View.h>
#import <sys/param.h>
#define MAX_PRIORITY 30
#define RGB_COLOR 0
#define BW_COLOR 1
typedef struct _mpeg_info
{
// window settings
int colorSpace,
zoom,
backing;
BOOL sync,
drop;
float fps;
// stream attributes
unsigned int h_size;
unsigned int v_size;
unsigned char aspect_ratio; // Code for aspect ratio.
unsigned char picture_rate; // Code for picture rate.
unsigned long bit_rate; // Bit rate.
unsigned int vbv_buffer_size; // Minimum buffer size.
BOOL const_param_flag; // Contrained parameter flag.
// measured statistics
int totalFrames,
frameCount;
double elapsedTime;
} mpegInfo;
extern char *gpchProgName;
extern char *gpchOK;
@interface MPEGView:View
{
id theBitmap; // used in -drawSelf::
int theWidth, theHeight;
NXRect theRect;
char *data; //
id mpegThread;
NXSize theSize; // for -newZoom:
mpegInfo *info; // for -stats
char *address; // video cache
int len, maxlen;
DPSTimedEntry tag; // for timedEntry
int frameLength, frameCount, frameNumber, procIndex;
id controller;
char *adrs, *end;
double startTime, now;
}
/*** Initialization methods ***/
- initSize:(const NXSize *)aSize info:(mpegInfo *)pInfo;
- free;
/*** Standard C functions ***/
double ReadSysClock(void);
// DROP_FRAME
// CHECK_FOR_END
// SLOW_STUFF
// SHOW_FRAME
void te_none(DPSTimedEntry, double, void *);
void te_sync(DPSTimedEntry, double, void *);
void te_drop(DPSTimedEntry, double, void *);
void te_syncNdrop(DPSTimedEntry, double, void *);
/*** Instance methods ***/
- runAgain;
- runFromFile:(const char *)mpegFile;
- banner;
- setAddress:(char *)anAddress len:(int)aLen maxlen:(int)aMaxlen;
- (BOOL)ready;
- (mpegInfo *)info;
- (NXSize *)newZoom:(int)zoom;
- newSync:(BOOL)flag;
- newDrop:(BOOL)flag;
- newFrameRate:(float)fps;
/*** View Instance methods ***/
- drawSelf:(const NXRect *)rects :(int)rectCount;
@end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.