# File: mk_fltgram.src
#
program "%Z% MODULE: %M% RELEASE: %R%.%L% CREATED: %G% %U%"
source "mk_fltgram.ips"
descr "mk_fltgram - takes an image & builds a hdr"
#
# DSBQUE                ; Disable Queue
tcblock mbipldin 0x0154 
#
#=======================================================
#
#
#; FILE:    mk_fltgram.ips
#; PURPOSE: To take an image and to extract it to 1024x1024 and gi
#;	   a header
#; METHOD:
#;	Input:
#;		$IPRL_FLTGRAM_PARAM	- 
#; HISTORY: Written 25-Aug-95 by M.Morrison
#;	30-Aug-95 (MDM) - Cleaned up and changed subroutine calls
#;	18-Sep-95 (MDM) - Fixed param copy for EXTRACT_PARAM (copy 6, n
#;	17-Oct-95 (MDM) - Corrected error which was clobbering HDECODE_
#;	19-Oct-94 (MDM) - Modified to do the extract directly rather th
#;			  the extract subroutine (conflicts exist otherwise in
#;			  the use of the offset value -- need two different 
#;			  offset values)
#
#QSR_MK_FLTGRAM::
#
#    ;-------- decode the source and dest page info
#    COPYREG  $IPRL_FLTGRAM_PARAM+1 $IPRL_HDECODE_PARAM		;copy the
tcblock mbipcmd 0x0091 0x1456   0x0142 0x118D 0x10C8 
#    COPYREG  $IPRL_FLTGRAM_PARAM+3 $IPRL_HDECODE_PARAM+1	;copy th
tcblock mbipcmd 0x0091 0x1459   0x0142 0x118F 0x10C9 
#    CALLQUE  $QSR_DO_HDECODE                            	;decode 
tcblock mbipcmd 0x0091 0x145C   0x01F8 0x1068 
#
#    GETQADR  $IPRL_DEBUG_ADDR
tcblock mbipcmd 0x0091 0x145E   0x015C 0x1FFD 
#    CALLQUE  $QSR_DUMP_IPREG
tcblock mbipcmd 0x0091 0x1460   0x01F8 0x1028 
#
#    ;------- setup the header stuff for the dest page
#    COPYRI2D $IPRP_HDECODE_ADDR+1  $IPRL_HEAD_WORK 10		;copy the 
tcblock mbipcmd 0x0091 0x1462   0x01AC 0x10CD 0x10CF 0x000A 
#    COPYRD2D $IPRL_FLTGRAM_PARAM+8 $IPRL_HEAD_WORK+3 3		;copy the
tcblock mbipcmd 0x0091 0x1466   0x0144 0x1194 0x10D2 0x0003 
#    COPYREG  $IPRL_FLTGRAM_PARAM+2 $IPRL_HEAD_WORK+6		;copy the f
tcblock mbipcmd 0x0091 0x146A   0x0142 0x118E 0x10D5 
#    COPYREG  $IPRL_FLTGRAM_PARAM+3 $IPRL_HEAD_WORK+7		;copy the f
tcblock mbipcmd 0x0091 0x146D   0x0142 0x118F 0x10D6 
#    SETREGS  $IPRL_HEAD_WORK+8 2 0x100000L			;set the output numb
tcblock mbipcmd 0x0091 0x1470   0x01B2 0x10D7 0x0002 0x0000 \
                                0x0010 
#    COPYRD2I $IPRL_HEAD_WORK $IPRP_HDECODE_ADDR+1 10		;copy the r
tcblock mbipcmd 0x0091 0x1475   0x01AA 0x10CF 0x10CD 0x000A 
#
#    GETQADR  $IPRL_DEBUG_ADDR
tcblock mbipcmd 0x0091 0x1479   0x015C 0x1FFD 
#    CALLQUE  $QSR_DUMP_IPREG
tcblock mbipcmd 0x0091 0x147B   0x01F8 0x1028 
#
#    _EXTRACT $IPRL_FLTGRAM_PARAM				;Do a fixed extract of 1024x1
tcblock mbipcmd 0x0091 0x147D   0x817A 0x118C 
#
#    CALLQUE  $QSR_DO_HEADER
tcblock mbipcmd 0x0091 0x147F   0x01F8 0x1125 
#
#    ;------- Setup the header and page info and then perform the 
#    ;;COPYRD2D $IPRL_FLTGRAM_PARAM $IPRL_EXTRACT_INST 4		;set the
#    ;;COPYRD2D $IPRL_EXTRACT_1024 $IPRL_EXTRACT_PARAM 6		;setup t
#    ;;CALLQUE  $QSR_FMT_EXTRACT
#
#    GETQADR  $IPRL_DEBUG_ADDR
tcblock mbipcmd 0x0091 0x1481   0x015C 0x1FFD 
#    CALLQUE  $QSR_DUMP_IPREG
tcblock mbipcmd 0x0091 0x1483   0x01F8 0x1028 
#
#RTNQUE
tcblock mbipcmd 0x0091 0x1485   0x01FA 
#=======================================================
#
# ENBQUE                ; Enable Queue
tcblock mbipldin 0x0136
#
#
return
#
#=======================================================
