1 / 6

= =

Example 1 : Tentukan matriks refleksi terhadap garis y = x Jawab: K = R(-45 0 ) * Refleksi thd sb-y * R(45 0 ). 2/2 2/2 0 -2/2 2/2 0 0 0 1. -1 0 0 0 1 0 0 0 1. 2/2 - 2/2 0 2/2 2/2 0 0 0 1. 0 1 0

monita
Download Presentation

= =

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Example 1 : Tentukan matriks refleksi terhadap garis y = xJawab:K = R(-450) * Refleksi thd sb-y * R(450) 2/22/2 0 -2/22/2 0 0 0 1 -1 0 0 0 1 0 0 0 1 2/2 -2/2 0 2/22/2 0 0 0 1 0 1 0 10 0 0 0 1 = =

  2. Example 2 Bila refleksi dilakukan terhadap garis y = 1/2 (x + 4). Menurut Sdr bagaimanakah matriks komposisinya ? Jawab: K = T(0,2) R( = tan-1 ½) Refleksi thd sb-X R( = -tan-1 ½) T(0,-2) 1 0 0 01 2 0 0 1 1 0 0 0 -1 0 0 0 1 1 0 0 01 -2 0 0 1 2/5 -1/5 0 1/5 2/5 0 0 0 1 2/5 1/5 0 -1/5 2/5 0 0 0 1 K = 3/5 4/5 -8/5 4/5-3/5 16/5 0 0 1 K = 3/5 4/5 -8/5 4/5-3/5 16/5 0 0 1 2 4 2 4 6 6 = 1 1 1 14/5 28/5 22/5 12/514/5 6/5 1 1 1 O* = K * O =

  3. Problem 1 : Buktikan bahwa matriks komposisi untuk rotasi terhadap titik sembarang (x,y) adalah cos  -sin  x(1 - cos ) + ysin  sin  cos  y(1 - cos ) - xsin  0 0 1 K = Problem 2 : Buktikan bahwa matriks komposisi untuk penyekalaan terhadap titik sembarang (x,y) adalah Sx 0 x(1 - Sx) 0 Sy y(1 - Sy) 0 0 1 K =

  4. Problem 3 : (lihat Foley & Van Dam, hal 210) Tentukan matriks komposisi KWV untuk pemetaan obyek segi 3 ABC dari window ke viewport dan hitung posisi A*, B* dan C* setelah pemetaan

  5. Object_array = 2 5 5 6 4 8 1 1 1 Translation_matrix_2_origin = 1 0 -4 0 1 -6 0 0 1 Rotation_matrix = 0 -1 0 1 0 0 0 0 1 Translation_matrix_2_previous_position = 1 0 4 0 1 6 0 0 1 New_obj_array = 4 6 2 4 7 7 1 1 1 • Translasikan obyek ke origin sebesar T(-4,-6), kemudian • rotasikan sebesar R(900). Kembalikan ke posisi semula • dengan T(4,6). Matriks komposisi yang pertama adalah • K1 = T(4,6) * R(900) * T(-4,-6)

  6. Object_array = 4 62 4 7 7 111 Translation_matrix_2_origin = 1 0 -1 0 1 -3 00 1 Scaling_matrix = 0.75 0 0 0 1.33 0 0 0 1.00 Translation_matrix_2_previous_position = 1 0 3 0 1 1 00 1 New_obj_array = 5.25 5.753.75 2.33 6.32 6.32 1 1 1 • Proses pemetaan ke viewport dilakukan dengan cara • mengalikan obyek hasil transformasi dari proses pertama • dengan matriks komposisi K2 = T(3,1) * S(0.75, 1.33) * T(-1,-3) • yaitu • New_obj_array = K2 * New_obj_array sehingga diperoleh :

More Related