graphics

Real time plots in matlab standalone application

爱⌒轻易说出口 提交于 2019-12-24 16:25:03
问题 The application is a GUI designed with GUIDE with lots of subplots that have an refresh interval approx ~1s adding new data to the time series, for example: I have read through making-graphs-responsive-with-data-linking, but the efficient linkdata on does not work in standalone applications when exporting with application compiler: Error using linkdata (line 24) Plots cannot be linked in deployed applications because linked plots require the MATLAB workspace. ,while refreshdata works but

How to make form rounded rectangle or round or triangle

五迷三道 提交于 2019-12-24 16:19:37
问题 I am developing an application in C# and there is a requirement of the form of the main window in rounded rectangle or some times triangle type or round shape. so, how can I achieve this kind of features in C# 2008 回答1: I think this is what you're looking for: http://www.codersource.net/csharp_custom_window_forms.aspx Also you can google for it, there are plenty examples. 回答2: Assuming this is on Windows Forms you can check these two articles on MSDN: http://msdn.microsoft.com/en-us/library

Java transformation matrix operations

别来无恙 提交于 2019-12-24 16:18:48
问题 I'm trying to maintain and then use a transformation matrix for a computer graphics program. It's a 3x3 matrix that stores scale, rotate, and translate information for (x,y) points. My program can handle any individual case... i.e. if I only scale or only rotate it works fine. However, it does not seem to work when combining scale and rotate, and I think that has to do with how I combine rotation and scale in the code. The matrix is called transformation and is of type float. The following

Spawning mutiple circles and make them move

穿精又带淫゛_ 提交于 2019-12-24 15:36:28
问题 I'm trying to teach myself java and I "try" to code a little game. I have a problem and I guess the solution is very simple but I'm struggling. The basic idea is that I am controlling a circle and I want to spawn circles every 5 seconds at random locations within the boundries of my window . The circles should move towords the location of the circle that I'm controlling. Here's what I have so far: Window-Class: package TestGame; import java.awt.Graphics; public class Window extends GameIntern

How to use/setup TexturePacker2 libgdx

谁说胖子不能爱 提交于 2019-12-24 15:26:43
问题 I have a difficulty with texturepacker2 from libgdx . I was trying to create textureAtlas using texturepakcer2 so that I can create animated images. However I could not use TexturePacker2.process(Input Directory Path", "Output Directory Path", "texture_file"); Because it could not recognize TexturePacker2. Even thought I import gdx-tool.jar file inside libs and also added libraries through Project -> Properties -> Java Build Path -> Libraries -> Add jars , it still cannot resolve nor

Moving Graphics in JPanel

*爱你&永不变心* 提交于 2019-12-24 15:23:24
问题 I'll like to make an Oval move from one place to the other in a JPanel when a button is clicked. This is the code I came up with. When I click the button however it all happens at once without visible movement the slow from the start to finish seen. The Oval just appears in a new location. import java.awt.Color; import java.awt.Graphics; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import javax.swing.*; import javax.swing.JPanel; public class testtest implements

R: Open new graphic device with dev.new() does not work

蹲街弑〆低调 提交于 2019-12-24 14:34:39
问题 I have a problem with opening a new graphics device to make a new plot. The code is like: par(mfrow = c(1, n.groups),pty="s") if (n.groups == 3){ par(mfrow = c(2, 2) ) } else if (n.groups == 5 | n.groups == 6) { par(mfrow = c(3, 3)) } QQ <- tapply(data$Measurement,data$Group,qqnorm,plot.it=T, main = "Q-Q Plot") ... some other lines ... grp.plot <- ggplot(group.join, aes(x=Group,y=mean)) + geom_bar(stat="identity") box.plot <- ggplot(data = brcp.df, aes(x = Group, y = Measurement)) + geom

moving buffered image to specific coordinates

允我心安 提交于 2019-12-24 14:34:12
问题 I am trying to move the blue square around the grid by pressing the arrow keys. I already set up the KeyListener but when I repaint the frame, I have to move the frame around in order for it to update. How do I make it a smooth animation (moving the square from one coordinate to another)? Example: if (keyCode == KeyEvent.VK_LEFT){ x5=x5-xChange; frame.repaint(); } My images are buffered images and are all set to specific coordinates. Here is my graphics class: public static class

Rotate an object on its own axes in OpenGL

 ̄綄美尐妖づ 提交于 2019-12-24 14:24:07
问题 So I have a cube that I wish to rotate around any of its three axes (the axes of the cube, not the window). As many other similar questions have stated, my rotations work as long as I am only rotating in one direction, but when I start mixing them, I get strange results. In particular, the rotation about the y-axis always rotates about the y-axis of the window, regardless of how the cube has been rotated. My drawing code is as follows: glMatrixMode(GL_MODELVIEW) ; glLoadIdentity(); gluLookAt

Drawing an arc in C++ Graphics.h

浪子不回头ぞ 提交于 2019-12-24 14:15:55
问题 I'm using graphics.h in order to start with a bit of graphic in C++, but when I run the code the program crash. I'm using CodeBlocks as a compiler and Windows 8.1 as an operating system. What should I do in order to make it works? Here is the code: #include <graphics.h> int main() { int gd = DETECT; int gm; initgraph(&gd, &gm, "C:\\TC\\BGI"); arc(200, 200, 0, 130, 50); getch(); closegraph(); } 回答1: "What should I do to make it works?" 1) Forget about graphics.h it is obsolete. 2) Get yourself