libera/#clim - IRC Chatlog
Search
9:48:03
metsomedog
For drawing images ("tiles") in a grid, is there some built-in mcclim class recommended to use?
10:04:27
Brucio-61
do you mean using CLIM drawing routines for things lines and circles do draw images that are arranged in a grid or do you mean drawing existing bitmap images at grid-based positions?
10:05:42
metsomedog
Hmm, I was thinking to load some images, and draw equally sized images in a grid for a simple 2d game.
10:22:09
Brucio-61
using bitmap images like this is called "patterns" in CLIM. see http://bauhh.dyndns.org:8000/clim-spec/E-2.html#_1968 for constructing patterns from bitmap files
10:23:04
Brucio-61
6DRAW-PATTERN draws such a pattern to a medium (http://bauhh.dyndns.org:8000/clim-spec/14-5.html#_749)
10:28:13
metsomedog
Thanks I will have a look at those references and try getting something to render
10:45:16
jackdaniel
metsomedog: as Brucio-61 said patterns represent images, and rectangular-tile is a class that represents a pattern that repeats itself
10:47:34
metsomedog
What is a suitable "medium" for drawing onto? I'm trying to use clim-stream-pane right now
10:49:31
metsomedog
(interactor :interactor :scroll-bar nil))" leads to error "The value of CLIM-INTERNALS::PANE-TYPE is 'CLIM:CLIM-STREAM-PANE, which is not of type SYMBOL."
10:52:45
metsomedog
I found some opticl extension in bitmaps.lisp while grepping, any reason to use this over e.g. make-pattern-from-bitmap-file?
11:03:31
jackdaniel
the system update broke my display server and I had to play a detective with broken nvidia kernel modules
11:04:36
metsomedog
this is why i will never buy nvidia (tho i have had my fair share of crashes in amdgpu as well)
11:13:20
metsomedog
how should I "downscale" the image in make-pattern-from-bitmap-file/draw-design (say image is 800x600 and I want 80x60), and how should I draw it at some coordinate?
11:14:15
jackdaniel
principially you should use transform-region, but I think that a method for patterns is not implemented (but try it!)
11:16:18
jackdaniel
even if transform-region works I'd still recommend scaling the image manually with a program that knows anything about downscaling - there are many algorithms and some of them are better and some of them are worse
11:17:57
metsomedog
I'm testing mcclim vs sdl2 bindings for a simple roguelike game, basically never did graphics programming before so both are equally confusing