silverlight-3.0

How wrap image around cylinder in Silverlight

我的未来我决定 提交于 2019-12-07 06:36:39
问题 I am trying wrap image around cylinder in silverlight. I looked a lot in Google but don't found anything. As I know it can be done with pixel shader, but don't know how. Is it possible? Thanks. 回答1: It's not a complete wrap onto cylinder, but you will get a starting idea/example: (code is in GLSL, not in HLSL, but i think it will be not hard to convert it) uniform sampler2D tex; void main() { vec2 cen = vec2(0.5,gl_TexCoord[0].y)-gl_TexCoord[0].xy; cen = vec2(pow(cen.x,1.7),pow(cen.y,2.2));

Silverlight user authentication

感情迁移 提交于 2019-12-07 01:21:21
问题 I am currently developing a Silverlight 3 app that needs some sort of user authentication, because the data pulled from a WCF service is user specific. Target audience is the regular Internet - so there is no AD to authenticate against. Here are some of the questions I have concerning that situation: Is there a framework or other mechanism that would support me? Would you recommend authentication within the Silverlight app or via outside mechanisms like forms auth? Which is more secure? What

Silverlight Event Log in Isolated Storage

允我心安 提交于 2019-12-06 16:32:39
Has anyone written an event log that uses Isolated Storage in Silverlight 3? Any suggestions on implementing one? Specific questions: Should I keep a stream writer open, or should I open,write, and close for each entry? How should I remove items from the log atomically? I heard clog from codeplex is pretty good although it targets wcf, i read on codeproject about about a log4net approach that works for silverlight, although both of these log 2 wcf services, im sure with a bit of tweaking you can modify this to write to isolated storage Crypto Logger supports Silverlight apps and libraries and

Using IEditableObject In Silverlight

余生颓废 提交于 2019-12-06 15:21:08
I have a object that implements the IEditableObject interface exposed on a viewmodel bound to a Silverlight page. How/Where do I call the BeginEdit, CancelEdit and EndEdit methods? How can I constrain only objects implementing this interface to my page? I am NOT using DataGrid or DataForm controls. I am using Label, TextBox and DescriptionViewer controls to display the data for editing. I know this is an old thread (but for the sake of future use...) I do it this way: whenever the current item (for instance of a CollectionViewSource) changes this is done: void View_CurrentChanged(object sender

Showing lines with different colors on a Silverlight Toolkit’s LineChart?

余生长醉 提交于 2019-12-06 14:01:28
问题 Hy, I have a chart,wich is created in runtime,this could be Line, Bar or Pie type. Basically what i want is to have more contrast on the lines on the chart,this means i should use different colors on the lines. For Bar chart i use the StylePalette property to set wich colors will used in the chart,and it's working fine,but for Line it has no effect. As a Line chart i tried this: For the line i want to use lets say 2 colors. Style style = new Style(typeof(Control)); Setter st = new Setter

Silverlight, RIA Services, MVC2P2 = No Data

余生颓废 提交于 2019-12-06 12:43:59
I am having trouble upgrading my current project to use RIA Services. I added all the necessary web.config changes but still no luck. I everything compiles fine but when I hit the page using the datacontext I get an error. I debugged with fiddler and I'm getting a 404 on one of the request. I am getting back headers in my grid so some communication is happening but no data is actually coming through. Another thing to note is that my MVC is running windows authentication. I do have a clientaccesspolicy.xml as well. Error in Silverlight with Headers but no data, Response from Fiddler:

Siliverlight 3 Navigation between user controls?

匆匆过客 提交于 2019-12-06 12:34:39
问题 Im just starting to get to grips with silverlight 3, coming from ASP.NET and Flex. I have followed the new navigation tutorial here and read through the authentication and role management tutorials also. So, i have a main page, which has a frame, inside of the grid, and several views. These are all navigatable and working fine. I see this main page as kind of a master page to my little application i have i mind. So know I want to have a login.xaml UserControl. This will handle all login and

Maintaining session in Silverlight

蓝咒 提交于 2019-12-06 10:21:48
问题 I am creating a Silverlight with WCF connectivity. I would like to create and maintain a session after user login in Silverlight and do the following. On successful login, create a session object and store session id, user id, user name, session status On further calls with WCF, the session information needs to be passed from Silverlight to WCF One solution would be to create a session object and pass it as parameter to all methods. Is there any other way of passing the info in all web

Silverlight Listbox Item Style

蹲街弑〆低调 提交于 2019-12-06 09:42:27
How would one go about styling a listbox such that the selection has a different text color than the default view? I've looked at this in several ways and because the ContentPresenter lacks a Foreground property. The default control template of the listbox provides several rectangles which one can use to adjust the highlight color. For example, with the default style a rectangle called BGColor3 has its opacity adjusted to get a highlight effect. Here is the bulk of my control template: <Grid> <Rectangle x:Name="BGColor2" Fill="{StaticResource HoverBrush}" Stroke="Black" StrokeThickness="1"

How to use something similar to DynamicObject in Silverlight 3 / WP7?

醉酒当歌 提交于 2019-12-06 07:39:48
How can you use Dynamic Language Runtime (DLR) or something else to mimic System.Dynamic.DynamicObject in SILVERLIGHT 3 (!) and WP7 (no C# 4.0!).. What I want to do is implement automatic dynamically created properties for databinding. The DLR can be used with WP7. Iron Ruby supports Windows Phone 7 from version 1.1 . DynamicObject was available as an extension prior to .Net 4.0 If you're happy using a language other than C# then this could be an option. There's a good article on using IronRuby on Windows Phone 7 at http://msdn.microsoft.com/en-us/magazine/ff960707.aspx . As an alternative,