Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
14 years ago

Connect Pixelbuffer and Charbuffer with Alpha Blender-char buffer no output

Hi,

I try to connect the pixelbuffer and the charbuffer by using the alpha blender, to display something on my tft.

If I am programming in Nios and give Pixelbuffer some Data, everything is fine, but it seems to be that char-buffer is not working. (I see no Characters on the screen)

Has anybody an idea?

(I used the media pc and got the same result...)

Greets

example code:# include <stdio.h># include <altera_up_sd_card_avalon_interface.h># include "system.h"# include <altera_up_avalon_video_pixel_buffer_dma.h>

//#include "altera_avalon_pio_regs.h"# include "math.h"# include "system.h"# include "altera_avalon_pio_regs.h"# include "altera_up_avalon_video_character_buffer_with_dma.h"# include "altera_up_avalon_video_character_buffer_with_dma_regs.h"

int main (){

alt_up_pixel_buffer_dma_dev *pixel_buffer=NULL;

alt_up_char_buffer_dev *char_buffer=NULL;

int er=0;

int count=0;

int color=240;

double delay=0;

int a=0;

int x=0;

int y=0;

pixel_buffer=alt_up_pixel_buffer_dma_open_dev("/dev/video_pixel_buffer_dma_0");

char_buffer=alt_up_char_buffer_open_dev("/dev/video_character_buffer_with_dma_0") ;

if(char_buffer==NULL) printf("Wrong Device!");

if(char_buffer!=NULL) printf("Right Device!");

a=alt_up_char_buffer_draw(char_buffer,25,x,y);

alt_up_pixel_buffer_dma_draw_box (pixel_buffer, 0, 0, 319, 239, 200,

return 0;

}
No RepliesBe the first to reply