summaryrefslogtreecommitdiff
path: root/dviware/beebe/src/getbmap.h
diff options
context:
space:
mode:
Diffstat (limited to 'dviware/beebe/src/getbmap.h')
-rw-r--r--dviware/beebe/src/getbmap.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/dviware/beebe/src/getbmap.h b/dviware/beebe/src/getbmap.h
new file mode 100644
index 0000000000..ac1b85c3e0
--- /dev/null
+++ b/dviware/beebe/src/getbmap.h
@@ -0,0 +1,35 @@
+/* -*-C-*- getbmap.h */
+/*-->getbmap*/
+/**********************************************************************/
+/****************************** getbmap *******************************/
+/**********************************************************************/
+
+void
+getbmap() /* allocate bitmap array */
+{
+#if SEGMEM
+ register UNSIGN16 y;
+
+ if (bitmap[0] == (UNSIGN32*)NULL)
+ {
+ for (y = 0; y < (UNSIGN16)YBIT; ++y)
+ {
+ bitmap[y] = (UNSIGN32*)MALLOC( (unsigned)((XBIT) * \
+ sizeof(UNSIGN32)) );
+ if (bitmap[y] == (UNSIGN32*)NULL)
+ (void)fatal(
+ "getbmap(): Cannot allocate space for page image bitmap");
+ }
+ }
+#else /* NOT SEGMEM */
+ if (bitmap == (UNSIGN32*)NULL)
+ {
+ bitmap =
+ (UNSIGN32*)MALLOC(((UNSIGN32)(XBIT))*((UNSIGN32)(YBIT))*sizeof(UNSIGN32));
+ if (bitmap == (UNSIGN32*)NULL)
+ (void)fatal(
+ "getbmap(): Cannot allocate space for page image bitmap");
+ }
+#endif /* SEGMEM */
+}
+