Planetdance forum
Board index => Astrobasic => Topic started by: Les on February 12, 2021, 07:21:27 PM
-
Hi,
I would like to put a new 'planet' into horoscope.
Just wondering if there is a chance to put bmp file instead of using setbitmap(&BitmapInfo, int color); and then putbitmap?
-
There is picture(), used in Cartography. But you'd have to distribute that jpg along with the script.
-
Thank you Jean.
I used first setbitmap as per example in help:
char MyBitmap[16][17] =
"x xxxxxxxxxxxxxx",
"x xxxxxxxxxxxxxx",
"xx xxxxxxxxxxxxx",
"xxx xxxxxxxxxxxx",
"xxxx xxxxxxxxxxx",
"xxxxx xxxxxxxxxx",
"xxxxxx xxxxxxxxx",
"xxxxxxx xxxxxxxx",
"xxxxxxxx xxxxxxx",
"xxxxxxxx xxxxxxx",
"xxxxxxxxx xxxxxx",
"xxxxxxxxxx xxxxx",
"xxxxxxxxxxx xxxx",
"xxxxxxxxxxxx xxx",
"xxxxxxxxxxxxxx x",
"xxxxxxxxxxxxxxx ";
setbitmap(&MyBitmap, BLACK);
putbitmap(10, 10, 0);
but PD tells me that: "Variable not found: Parameter no: 1. Line 221"
Line 221 is: setbitmap(&MyBitmap, BLACK);
therefore I was looking for other way as that one does not work for me and don't know how to get it right.
char MyBitmap is in the section where all variables are being declared of course.
What do I wrong with this one?
-
... alright, solved.
&MyBitmap must be without "&". :)
-
Are you getting along?
I am thinking about a way to convert a jpg to asci text, so you could just distribute it in ab code, could be done i think.
-
Hi Jean,
this is very good idea, perhaps bmp would be even easier, as jpg is compressed.
-
I have also been analyzing default.sym where bitmaps are kept, perhaps here would be easy to add bitmaps of new planets, but the length of that file seems to be fixed... or some additional file. I am just sharing my thoughts.
-
the sym* files are the same principle as setbitmap. I will look into that jpg to text later today.
-
On second thought i'm not gonna do that text to jpg convert, it would require quite some effort and the setbitmap feature is mostly sufficient.