⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pgbvideooutput.java

📁 一个用java写成的gb模拟器的源代码。
💻 JAVA
字号:
import java.awt.Canvas;

/**
 * PgbVideoOutput takes a PgbVideo implementation and renders
 * it to the screen, probably through its java.awt.Canvas
 * superclass.
 */
public abstract class PgbVideoOutput extends Canvas {
	PgbVideo	video;
	
	public PgbVideoOutput(PgbVideo video) {
		this.video = video;
		// notify the video system that we're attached.
		video.setVideoOutput(this);
	}
	
	public abstract void setGraphics();

	/**
	 * reset() is called by Pgb when the emulated machine 
	 * resets.  If any screen clearing is needed, this is a
	 * good time.  Also the canvas is visible, so if any info
	 * needs to be acquired on the display, this is a good 
	 * time.
	 */
	public abstract void reset();
	
	/**
	 * hblank(line) is called by the attached PgbVideo every 
	 * time an hblank occurs and is not skipped by frame 
	 * skipping.
	 */
	public abstract void hblank(int line);

	/**
	 * vblank() is called by the attached PgbVideo every 
	 * time a vblank occurs and is not skipped by frame 
	 * skipping.
	 */
	public abstract void vblank();
	
	/**
	 * create a screenshot
	 */
	public abstract void makeScreenshot();
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -