As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I've added a Canvas to my xaml page and drawn some squares on it. Now I want a event that allowes me to to zoom the canvas in and out, making the squares on it bigger and smaller.
I'm guessing I have to loop thru the children of the canvas and do the math magic on them, but how can I detect the user doing a zoom with two fingers? Does not seem to be anything built in?
Does anyone know about a tutorial?
You should check manipulations. They are the representation of multitouch input in .Net, such as zoom, rotation and so on. You will have to work with 3 events :
ManipulationStarted
ManipulationDelta
ManipulationCompleted (used for inertia)
With the ManipulationDelta, you will get a delta that you can use to transform your controls according to user's actions. Here is the MSDN Documentation
You will be interested by the DeltaManipulation.Scale property for your zoom.
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I'm trying to create a scatter plot in MATLAB where the samples are gray-scale images, like this one: http://isomap.stanford.edu/web2.jpg.
I'm able do it by first calling scatter function to create the plot, and then calling image(x,y,I) for each image, where x (y) is the range in x-axis (y-axis) where the image is to be plotted in the original plot.
The problem is that "image" does not produce a good visualization of the images, but "imshow" does. However, I didn't find any argument on this function that allows me to specify where to plot the image inside another plot. Any ideas?
Many thanks!
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I'm about to create an Augmented Reality application which requires to render 3d models with animation. What is the best way/plug-in or software to export a model to old quake (.md2) format?
I want to use popular modelling software like 3Ds MAX, Maya or Blender. I have search all over the internet but I only found some plug-ins which I had difficulty to work with.
Any commercial tool? I need a good support.
Hmmm... my favorite question.
It highly depends on what kind of animation you are willing to export.
3Ds Max
In 3Ds Max there is an awesome plugin called QTip. It only costs a few bucks but it's worth every single penny.
Maya
There is also another export plugin (MD2Export) for Maya. I didn't have much success with it but it's worth trying.
Blender
There are also some scripts written for Blender but none worked for me. But I think Blender 2.46 has a native export for MD2.
Stand-alone Software
Few lightweight applications have a support for export MD2:
fragMOTION: Can import/export variety of formats and has support for MD2 and MD3
MilkShape 3D: Same as fragMOTION but it also has an MD2 viewer which comes handy sometimes.
Quake2 Modeller: It's very old and I didn't try it personally.
NOTE 1: As I said, it highly depends on your animation. If you have Vertex animation then QTip is your golden choice. fragMOTION and MilkShape do not support vertex animation. But if you make Bone animation, you may use the modeling software of your choice and import it to fragMOTION or MilkShape and then export it to MD2.
NOTE 2: I think you can find more information about MD2 here
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I would like to programmatically produce a simple animation video. Don't think "Toy Story" level of animation, think simple stick figures moving around the screen and other very simple lines and dots in black and white only. The point of the video is to explain a complicated scientific concept with a 5 minute video vs. pages and pages of text trying to describe images with words.
What is the best open source framework to make a .mov or .flv file that I can then upload to youtube or vimeo. I could use ImageMagick to write out jpeg after jpeg, and then ffmpeg to turn those jpegs into a .mov file. But is there a better framework out there for simple animation like this? I feel like the ImageMagick to ffmpeg route is going to involve a lot of me writing code from scratch to make a stick figure walk across the screen.
Traditionally people have used Adobe/Macromedia Flash for such problems. These days javascript and HTML5 canvas seem promising and popular.
There are plenty of Open Source Flash like IDEs if you want to go with that.
http://osflash.org/projects
If you want to have some fun I'd actually recommend Processing and going into the javascript direction.
http://processingjs.org/
https://github.com/fjenett/processing-video-js
or many other JS alternatives...
http://www.createjs.com/#!/EaselJS/demos
https://github.com/dkln/canvas_library/
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm developing a new site that graphs some operational metrics. As such about a dozen charts/graphs will be displayed on the site. I want to be able to have them dynamically scale down (within reason) based upon the size of the browser.
I'm debating the pros/cons of generating these as one of these options:
SVG. Great for scaling but may have limited support,
HTML5. Clearly a great choice for the future and for FF customers, IE?
PNG. This would
require that I regenerate the PNG
based upon the size of the DIV &c.
Which is the preferable option? I'm leaning towards PNG just for ubiquitous support, but would like to have client-side scaling. What is the best solution given the state of affairs of SVG and HTML5 canvas support in browsers?
I prefer SVG over HTML5 canvas or PNG for charts. Canvas and PNG zoom as bitmaps in Firefox. (Canvas provides a vector API, but it's a drawable bitmaps surface--not a vector store.) SVG zooms as vector graphics in Firefox.
I ofter run with the view zoomed, so I appreciate real vector zooming.
(Canvas makes sense for games that can't handle the perf hit of retained mode graphics.)
You could do worse than explore a new charting library:
http://g.raphaeljs.com/
You won't believe it at first.
Now you can use SVG anywhere
SVG is supported by all modern browsers.
Canvas is supported by all modern browser.
Internet Explorer supports neither.
A partial API for SVG, with fallback mechanism for IE exists in Raphaƫl (raphaeljs.com)
A partial Canvas-implementation for IE exists in ExCanvas
I'd say say its not a question of "Canvas or SVG", but what high-level library exists that best covers your needs.
The best option would be SVG or HTML5 that will fall back on PNG if the others aren't available.
ExplorerCanvas brings <canvas> support to IE. So, it would be an amalgamation of 1 & 2. The benefit would be that (a) as more browsers add support for <canvas>, you would automatically get the benefits of already supporting it and (b) you would get scaling with browser size.
You can use SVG with a png fallback just using CSS as it is described in this answer: https://stackoverflow.com/a/13575068/418711
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
My coworker and I constantly argue about button sizes. I like to have buttons that have a fixed size (ie if minimized/maximized the button sizes dont change,other controls may but not buttons), width= text in it and height=27 -30 pixels.
My co-worker prefers buttons that are only 20 pixels in height and the width is docked to vary as screen is resized. that is to say,when a screen is maximized the button elongates itself.
Personally,I don't like buttons that resize. I was wondering if anyone else want to chime in on this UI argument?
For what it's worth, according to the Vista UX Guidelines the default button size should be 14 x 50 "dialog units" (about 28px by 100px on a 96dpi monitor), with about an 11px border from the side.
Regardless of how you feel about Microsoft as a company, I think they do a good job with an uniform UI. If you are working on Windows apps then I think this guideline is a must follow.
I vote for buttons that do not get wider as the form gets wider. Personally, I think it is just ugly and makes the buttons harder to use because your eye is no longer drawn to the text in them.
Also, with 16:9 and 16:10 ratio monitors becoming popular, those buttons will be abnormally wide ;)
Please don't resize the buttons...
I think it would depend on exactly what else is going on in your app. If everything else resizes horizontally, maybe it would make sense?
The only way to know for sure is usability tests. Get real users, sit them down, have them try it out and see what they think, and whether they are confused (or annoyed). Asking a bunch of developers and designers can only get you so far.
It's not the size of the button that counts, but what you do with the button.
Resizing buttons based on the screen is fine if they stay in proportion and they still need to have a cap - this is normally done when the form is launched and not during any resizes. However, resizing the buttons when the window resizes - that's a no-no.
When thinking about button sizing that need text captions (i.e. not icon type buttons) it's always good to allow at least an extra 60% for non-english text, if you ever expect to localise the app.
I agree that some scenarios where localization of an app is needed requires you to take into consideration the button size.However that still does not call for buttons that stretch to 75% of your screen in width(height remaining the same).
Usability wise I think it is import to keep buttons in a consistent size and position.
The button should be anchored, the user should not have to hunt for it. The user should not have a "woah, why are the buttons so big now" moment. Remember "Don't make me think"
To me it sounds like one of those times when a developer wants to resize buttons because they can, and the code ts cool, not because it would make a better user experience.
Buttons that resize would annoy me.
I'm no designer, but that just doesn't sound right.
Actually, that would drive me nuts and make me very angry at you.
Resizing is bad, IMO, but do be sure to anchor buttons to the appropriate corner(s).
Buttons should not resize, for a variety of reasons. Firstly, it would be a hell of a task to style and implement resizable buttons. QAing them would be a nightmare, probably.
Secondly, much of usability is based on pattern recognition; people look for familiar concepts when they seek information. When you show a user a bunch of different button sizes, you risk confusing them; they might think some buttons are more important than others.
I am not opposed to buttons that are liquid with the amount of text inside them, though. Sometimes a button just needs to be a bit wider to accomodate text.
That being said, the text inside a button should be clear, concise, and to the point. If you are having to create buttons that are super wide to accomodate the sentence you put inside them, you need to cut-down the label to a word or two that the user can understand quickly.
If you create buttons, please make sure the text has enough space left. Because if you want to translate the text into an other language (than english) you will probably need more space.
We use a fixed size for buttons but there are some exceptions (just because our software has to be translated into several languages.),