Commit c2e3b7f8 authored by Anton Ertl's avatar Anton Ertl

Merge branch 'master' of git.sv.gnu.org:/srv/git/gforth

parents 3fb34904 cd37b639
......@@ -21,7 +21,7 @@ dnl Process this file with autoconf to produce a configure script.
#We use some automake macros here,
#but don't use automake for creating Makefile.in
AC_INIT([gforth],[0.7.9_20200423],[https://savannah.gnu.org/bugs/?func=addbug&group=gforth])
AC_INIT([gforth],[0.7.9_20200430],[https://savannah.gnu.org/bugs/?func=addbug&group=gforth])
AC_PREREQ(2.54)
AC_CONFIG_MACRO_DIR([m4])
#snapshots have numbers major.minor.release_YYYYMMDD
......
......@@ -817,19 +817,23 @@ atlas-region buffer: (ar)
also soil also freetype-gl
: (mem>style) { atlas val -- ivec4-addr }
: img>mem ( addr u -- memimg w h )
0 0 0 { w^ w w^ h w^ ch# }
w h ch# SOIL_LOAD_RGBA SOIL_load_image_from_memory
w h ch# SOIL_LOAD_RGBA SOIL_load_image_from_memory ( memimg-addr )
w @ h @ ;
: rgba>style { memimg w h atlas val -- ivec4-addr }
BEGIN
atlas w @ 1+ h @ 1+ (ar) texture_atlas_get_region
atlas w 1+ h 1+ (ar) texture_atlas_get_region
(ar) i.x (ar) i.y -1 -1 d= WHILE
atlas val @ 2* dup >r val !
r> dup texture_atlas_enlarge_texture
REPEAT
>r atlas (ar) i.x (ar) i.y (ar) i.w 1- (ar) i.h 1- r@ (ar) i.w 1- 2* 2*
atlas (ar) i.x (ar) i.y (ar) i.w 1- (ar) i.h 1- memimg (ar) i.w 1- 2* 2*
texture_atlas_set_region
r> free throw (ar)
memimg free throw (ar)
GL_TEXTURE0 glActiveTexture ;
: (mem>style) ( addr u atlas val -- ivec4-addr )
2>r img>mem 2r> rgba>style ;
: mem>style ( addr u -- ivec4-addr )
over >r
GL_TEXTURE2 glActiveTexture
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment