UnderwareDesign
July 29, 2010, 06:46:36 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Uplift - finished project by Laskiapina (8,July,2010)
 
   Home   Help Login Register  
Pages: [1]
  Print  
Author Topic: Fx Fonts  (Read 4206 times)
kevin
Development Team
Administrator
Hero Member
*****
Offline Offline

Posts: 9341



WWW
« on: December 05, 2006, 10:00:15 AM »

 Fonts now have a FX buffer support. 


* PB_FXFonts_V002.JPG (56.27 KB, 400x300 - viewed 725 times.)
Logged

kevin
Development Team
Administrator
Hero Member
*****
Offline Offline

Posts: 9341



WWW
« Reply #1 on: January 03, 2007, 05:15:54 AM »

The Code from this example

Code:
; Display a message while the loads and are converted
 Print "Loading Fonts:"
 sync
 screenvsync on

; Load the Windows True Type Font Arial (50 point)
 LoadFont "Arial",2,60,1
 PrepareFXfont 2
 Setfont 2


; Create an Image in FX format (800*600)
 CreateFXImage 1,800,600




Do
; Clear the screen
Cls rgb(0,100,40)

; Tell PB to render to this surface
rendertoimage 1

; Draw Box with Alpha Sub to the FX image
inkmode 1+128
boxc 0,0,800,600,true,rgb($2,$4,6)
inkmode 1

; Render some text to this image in a random position
text rnd(800),rnd(600),"FX Font On FX IMage"

; tell PB to direct all drawing to the screem
Rendertoscreen

; Rotate our FX image and draw it to the screen
DrawRotatedImage  1,400,300,angle#,1.0+Cos(angle2#),1.2,Getimagewidth(1)/-2,GetImageHeight(1)/-2,true

; draw the
Print "Drawing FX fonts to FX images"
Print Fps()

; Bump the Rotation angles
Angle2#=wrapangle(angle2#,2.1)
Angle#=wrapangle(angle#,cos(angle2#)*1 )
Sync
loop



Logged

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.10 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!