home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 4513 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  2.9 KB

  1. Path: informatik.tu-muenchen.de!fischerj
  2. From: fischerj@informatik.tu-muenchen.de (Juergen "Rally" Fischer)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: doubling pixels horizontally
  5. Date: 29 Feb 1996 15:59:50 GMT
  6. Organization: Technische Universitaet Muenchen, Germany
  7. Distribution: world
  8. Message-ID: <4h4ihm$mul@sunsystem5.informatik.tu-muenchen.de>
  9. References: <4f4ibc$gl9@news.cs.tu-berlin.de> <591.6610T1165T2102@login.eunet.no><1045.6611T753T2256@vip.cybercity.dk><4faoe1$47@sunsystem5.informatik.tu-muenchen.de><2991.6612T1034T625@vip.cybercity.dk><576.6613T1070T1730@login.eunet.no><1257.6614T57T922@vip.cybercity.dk><1982.6617T1096T103@ifi.uio.no><4gbjg3$104@sunsystem5.informatik.tu-muenchen.de>  <4518.6625T1142T92@ifi.uio.no> <5073.6626T469T1290@login.eunet.no> <2824.6626T859T1819@ifi.uio.no>
  10. NNTP-Posting-Host: hphalle2i.informatik.tu-muenchen.de
  11. Originator: fischerj@hphalle2i.informatik.tu-muenchen.de
  12.  
  13.  
  14. In article <2824.6626T859T1819@ifi.uio.no>, ludvigp@ifi.uio.no (Ludvig Pedersen) writes:
  15.  
  16. |> >>there is easy to get an overview.
  17. |> >Like using structures. :)
  18. |> Yes, that's good! :)
  19. Then I go C anyway...
  20. |
  21. |> >>[...]
  22. |> >>   move.l #$00e1fffe,d4 : or.l d2,d4           ;WAS: 00df
  23. |> >>   movem.l (sp)+,d0-d7/a1-a6 ;a0=(ptr)copl
  24. |> >>   rts
  25. |> >Whow! What a mess. :)
  26. grrrrrrrrrrrrrrrrrrrrrrrrrrrrr :)
  27.  
  28. |> I don't think you are the only one which agree's about that! ;)
  29. |> 
  30. stop it people :) 
  31. oki its trash for the whole world, I got it, but it helps me a lot.
  32.  
  33. |> >>that we are taking about 2x2 without sprite-dithering!!
  34. |> >He forgot that it was 2xn
  35. |> He probably did.
  36. uh what ? 2xY ? my code can do :)
  37.  
  38. |> If you set a flag in CleanUp: and are polling this flag with CPU to see if the
  39. |> blitter is finish. It might never finish because you task uses all the CPU-
  40. |> time. and CleanUp is never run.
  41. |> 
  42. |> Don't do this:
  43. |> 
  44. |> .QCleanup:
  45. |>         move.l  #-1,_BlitterIsDone
  46. |>         moveq   #0,d0
  47. |>         rts
  48. |> 
  49. |> and this
  50. |> 
  51. |> while(!BlitterIsDone);      //infinite wait loop.
  52. |> 
  53. |> ------------------------------------------------------
  54. |> Send a signal instead!
  55. |> 
  56. |> Here is my code. (It works!)
  57.  
  58. yeppeee a _CODE_ :) THANX :)
  59.  
  60. |> 
  61. |> .QCleanUp:
  62. |>         move.l  #-1,_BlitterIsDone
  63. |>         movem.l d0-a6,-(sp)
  64. |>         move.l  _BltPort,a0
  65. |>         moveq.l #0,d0
  66. |>         move.b  MP_SIGBIT(a0),d1
  67. |>         bset    d1,d0
  68. |>         move.l  4.w,a6
  69. |>         move.l  _Task,a1
  70. |>         CALL    Signal(a6)
  71. |>         movem.l (sp)+,d0-a6
  72. |> 
  73. |>         moveq   #0,d0
  74. |>         rts
  75. |> 
  76. |> And this:
  77. |> 
  78. |> while(!BlitterIsDone)
  79. |>   Wait(1l<<(BltPort->mp_SigBit));
  80. |> 
  81. |> 
  82. |> Now your task will be in wait-state until the blitter is finished.
  83. |> 
  84. |> Problem solved! :)
  85. |> 
  86. |> 
  87. |> <sb>Ludde - Amiga Demo Coder
  88. |> <sb>Virtual Reality & Official Be developer
  89. |> <sb>ludvigp@ifi.uio.no
  90. |> 
  91. ------------------------------------------------------------------------
  92.    fischerj@Informatik.TU-Muenchen.DE (Juergen "Rally" Fischer)   =:)
  93.  
  94.