Subversion Repositories Kolibri OS

Rev

Rev 6613 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6613 Rev 7597
Line 1... Line 1...
1
(*
1
(*
2
    Copyright 2016 KolibriOS team
2
    Copyright 2016, 2018 KolibriOS team
Line 3... Line 3...
3
 
3
 
4
    This program is free software: you can redistribute it and/or modify
4
    This program is free software: you can redistribute it and/or modify
5
    it under the terms of the GNU Lesser General Public License as published by
5
    it under the terms of the GNU Lesser General Public License as published by
6
    the Free Software Foundation, either version 3 of the License, or
6
    the Free Software Foundation, either version 3 of the License, or
Line 396... Line 396...
396
 
396
 
397
 
397
 
Line 398... Line 398...
398
PROCEDURE main;
398
PROCEDURE main;
399
VAR Lib, formats_table_ptr: INTEGER;
399
VAR Lib, formats_table_ptr: INTEGER;
400
 
400
 
401
  PROCEDURE GetProc(v: INTEGER; name: ARRAY OF CHAR);
401
  PROCEDURE GetProc(Lib, v: INTEGER; name: ARRAY OF CHAR);
402
  VAR a: INTEGER;
402
  VAR a: INTEGER;
403
  BEGIN
403
  BEGIN
404
    a := KOSAPI.GetProcAdr(name, Lib);
404
    a := KOSAPI.GetProcAdr(name, Lib);
Line 405... Line 405...
405
    ASSERT(a # 0);
405
    ASSERT(a # 0);
406
    sys.PUT(v, a)
406
    sys.PUT(v, a)
407
  END GetProc;
407
  END GetProc;
408
 
408
 
409
BEGIN
409
BEGIN
410
  Lib := KOSAPI.LoadLib("/rd/1/lib/libimg.obj");
410
  Lib := KOSAPI.LoadLib("/rd/1/lib/libimg.obj");
411
  ASSERT(Lib # 0);
411
  ASSERT(Lib # 0);
412
  GetProc(sys.ADR(img_is_img)	     , "img_is_img");
412
  GetProc(Lib, sys.ADR(img_is_img)        , "img_is_img");
413
  GetProc(sys.ADR(img_to_rgb)	     , "img_to_rgb");
413
  GetProc(Lib, sys.ADR(img_to_rgb)        , "img_to_rgb");
414
  GetProc(sys.ADR(img_to_rgb2)	     , "img_to_rgb2");
414
  GetProc(Lib, sys.ADR(img_to_rgb2)       , "img_to_rgb2");
415
  GetProc(sys.ADR(img_decode)	     , "img_decode");
415
  GetProc(Lib, sys.ADR(img_decode)        , "img_decode");
416
  GetProc(sys.ADR(img_encode)	     , "img_encode");
416
  GetProc(Lib, sys.ADR(img_encode)        , "img_encode");
417
  GetProc(sys.ADR(img_create)	     , "img_create");
417
  GetProc(Lib, sys.ADR(img_create)        , "img_create");
418
  GetProc(sys.ADR(img_destroy)	     , "img_destroy");
418
  GetProc(Lib, sys.ADR(img_destroy)       , "img_destroy");
419
  GetProc(sys.ADR(img_destroy_layer) , "img_destroy_layer");
419
  GetProc(Lib, sys.ADR(img_destroy_layer) , "img_destroy_layer");
420
  GetProc(sys.ADR(img_count)	     , "img_count");
420
  GetProc(Lib, sys.ADR(img_count)         , "img_count");
421
  GetProc(sys.ADR(img_flip)	     , "img_flip");
421
  GetProc(Lib, sys.ADR(img_flip)          , "img_flip");
422
  GetProc(sys.ADR(img_flip_layer)    , "img_flip_layer");
422
  GetProc(Lib, sys.ADR(img_flip_layer)    , "img_flip_layer");
423
  GetProc(sys.ADR(img_rotate)	     , "img_rotate");
423
  GetProc(Lib, sys.ADR(img_rotate)        , "img_rotate");
424
  GetProc(sys.ADR(img_rotate_layer)  , "img_rotate_layer");
424
  GetProc(Lib, sys.ADR(img_rotate_layer)  , "img_rotate_layer");
425
  GetProc(sys.ADR(img_draw)	     , "img_draw");
425
  GetProc(Lib, sys.ADR(img_draw)          , "img_draw");
426
  GetProc(sys.ADR(img_scale)	     , "img_scale");
426
  GetProc(Lib, sys.ADR(img_scale)         , "img_scale");
Line 427... Line 427...
427
  GetProc(sys.ADR(img_convert)	     , "img_convert");
427
  GetProc(Lib, sys.ADR(img_convert)       , "img_convert");