logo-gnupg

E-Mail Privacy Should Concern YOU! Read why.

But I’ve got nothing to hide!

If you send something like the location of your extra house key to a family member or telling your colleague or friend what bank account to transfer money to using an unencrypted email, it is the equivalent of writing it on a postcard (no envelope), letting it take its routes through hundreds of prying eyes and unfaithful servants. The information is out in the open and it can be read and even changed before it reaches you without you even knowing.

Even if you have nothing to hide, using email encryption helps protect the privacy of people you communicate with, and makes life difficult for bulk surveillance systems in use today. Remember the Snowden case?

It is a known fact that government authorities and other more scrupulous groups like the NSA, is watching all internet activities closely. The reason for this has been covered as an attempt to “fight terror” and is in a double-crossing way partially true. The thing is that it doesn’t just focus on “suspected” persons activities online, but yours and mine as well.

They use advanced computational linguistic algorithms to snap up words, combinations of words and other “susceptible” ways of expressing something, trying to find hidden contexts using the intrinsic meanings of words and phrases in different combinations crossed with under-developed theoretical linguistic syntax algorithms, leading to a “profile” that who knows what they get out of.
One thing is sure: They get the contents.

I don’t mind if the NSA reads my mail…

With something as easy to interpret as e-mail, you no longer have to be a security specialist or advanced cracker to read and change other peoples e-mail. Anyone can download pre-made “hacker” tool-kit from the internet and watch everything you do on the internet, unless you correctly configure WiFi routers and use secured pairing between your wireless keyboard and PC or other wireless devices.
Tools are readily available for a so called “script-kiddie” to park his car nearby and intercept EVERY LETTER you write on your keyboard. The signals from your wireless keyboard is easily eavesdropped.

Do you trust your ISP to read your personal information?

Even if we take away the factors mentioned up until now, anyone that works for your ISP (Internet Service Provider) with access to the servers can scroll through a long listing of un-encrypted text in email communication whenever they please. So the reasons NOT to encrypt your email communication is starting to disappear.

But I don’t know anything about this!?

Luckily for everybody, the Open Source community has been developing and using such tools for years.

Not only have they developed technologies for doing this, but they’ve also taken time to create graphical user interfaces for setting up the tools you need, no matter what operating system you are using.

These products won’t cost you anything other than a little time and dedication to make a change to your rights for privacy. Descriptions and documentation is also available and easy to understand, often delivered in a multitude of languages as well.

Here is something to get you going in no time:

Mac OS X Users: https://gpgtools.org/gpgsuite.html

Windows Users: http://www.gpg4win.org/index.html

Linux / BSD Users: You know what to do… ;-)

If you choose to use products mentioned in this post or in any of its links, please consider donating a little money to the Free  Software Foundation, or even better, become a donating member!

Best of luck with claiming your right to privacy!

fsfButton

Using Cygwin and making it behave more like a Package Manager

Using the possibilities of the next to nothing alternative

Sometimes you’re stuck at a Windows box, and you long for all those trusty, handy Unix/Linux tools.
Then it is good to know that you can install Cygwin, as I’m sure most developers have heard of.

Simply put, it is a “near POSIX” standard “Unix like” environment for MS Windows® that let’s you install your Korn shell or ZSH for that matter, and pretend you’re using a decent computer operating system.

And, quoting the site:

  • a DLL (cygwin1.dll) which provides substantial POSIX API functionality.

Anyway. I haven’t been using it much, so this “tip” might turn up to be old news for many, but there will always be new beginners, right?

The point of this tip is to inform you that the file you download from Cygwin’s web site actually takes command-line arguments worth knowing about.

According to their site they claim that each time you want to add or remove program packages to the Cygwin installation, you need to download the install file anew and make the desired changes to your installation.

This is something that has annoyed me, after being used to installing pre-built software with a decent Package Manager like dpkg and it’s front-ends or RPM tools.

A Google Search away (“Duck Duck Go search”, Actually), I found a list of handy cmd-line options to use with the downloaded .exe setup file.

One thing should be mentioned though: The installer, as any other piece of software tends to change over time.
I suspect this is why Cygwin thinks it is best to always use the latest version of their installer, and being a software developer myself I do agree.

So, the first time you install Cygwin using the installer (this is the 64-bit version) make sure to install the “curl” and the “wget” tools. Then you can easily make a .bat file to download the latest version to the directory of choice before running it with the command line parameters described.

Here is a descriptive list over command line arguments to the .exe installer.
If you’re on a machine with no administration rights, you could use the –no-admin switch as an example.

Command Line Options:
 -D --download                     Download from internet
 -L --local-install                Install from local directory
 -s --site                         Download site
 -O --only-site                    Ignore all sites except for -s
 -R --root                         Root installation directory
 -x --remove-packages              Specify packages to uninstall
 -c --remove-categories            Specify categories to uninstall
 -P --packages                     Specify packages to install
 -C --categories                   Specify entire categories to install
 -p --proxy                        HTTP/FTP proxy (host:port)
 -a --arch                         architecture to install (x86_64 or x86)
 -q --quiet-mode                   Unattended setup mode
 -M --package-manager              Semi-attended chooser-only mode
 -B --no-admin                     Do not check for and enforce running as
                                   Administrator
 -h --help                         print help
 -l --local-package-dir            Local package directory
 -r --no-replaceonreboot           Disable replacing in-use files on next
                                   reboot.
 -X --no-verify                    Don't verify setup.ini signatures
 -n --no-shortcuts                 Disable creation of desktop and start menu
                                   shortcuts
 -N --no-startmenu                 Disable creation of start menu shortcut
 -d --no-desktop                   Disable creation of desktop shortcut
 -K --pubkey                       URL of extra public key file (gpg format)
 -S --sexpr-pubkey                 Extra public key in s-expr format
 -u --untrusted-keys               Use untrusted keys from last-extrakeys
 -U --keep-untrusted-keys          Use untrusted keys and retain all
 -g --upgrade-also                 also upgrade installed packages
 -o --delete-orphans               remove orphaned packages
 -A --disable-buggy-antivirus      Disable known or suspected buggy anti virus
                                   software packages during execution.

Use Cygwins abilities as a Package Manager with Cygcheck

In fact, the cygcheck.exe program accompanying every installation makes Cygwin behave more like systems such as dpkg (apt-get) or RPM (Yum / Zypper)

Some common tasks using cygcheck:

The -c option checks the version and status of installed Cygwin packages. If you specify one or more package names, cygcheck will limit its output to those packages, or with no 
arguments it lists all packages.

$ cygcheck -c
Cygwin Package Information
Package             Version         Status

alternatives        1.3.30c-10      OK
autoconf            13-1            OK
autoconf2.1         2.13-12         OK
autoconf2.5         2.69-2          OK
...

If you list one or more programs on the command line with -s, cygcheck will diagnose the 
runtime environment of that program or programs, providing the names of DLL files of which 
the program depends.

$ cygcheck -s vim
Found: D:\cygwin64\bin\vim.exe
Found: D:\cygwin64\bin\vim.exe
D:\cygwin64\bin\vim.exe
D:\cygwin64\bin\cygwin1.dll
C:\Windows\system32\KERNEL32.dll
C:\Windows\system32\api-ms-win-core-rtlsupport-l1-2-0.dll
C:\Windows\system32\ntdll.dll
C:\Windows\system32\KERNELBASE.dll
C:\Windows\system32\api-ms-win-core-apiquery-l1-1-0.dll
C:\Windows\system32\api-ms-win-core-processthreads-l1-1-2.dll
...

Searching all packages for a specific file:

$ cygcheck -p 'cygintl-2\.dll'

Found 1 matches for 'cygintl-2\.dll'.
libintl2-0.12.1-3 GNU Internationalization runtime library

$ cygcheck -p 'libexpat.*\.a'
Found 2 matches for 'libexpat.*\.a'.
expat-1.95.7-1 XML parser library written in C
expat-1.95.8-1 XML parser library written in C.

Here is a more complete list of alternatives:

At least one command option or a PROGRAM is required, as shown above.
-c, --check-setup show installed version of PACKAGE and verify integrity 
(or for all installed packages if none specified)
-d, --dump-only just list packages, do not verify (with -c)
-s, --sysinfo produce diagnostic system information (implies -c -d)
-r, --registry also scan registry for Cygwin settings (with -s)
-k, --keycheck perform a keyboard check session (must be run from a
 plain console only, not from a pty/rxvt/xterm)
-f, --find-package find the package to which FILE belongs
-l, --list-package list contents of PACKAGE (or all packages if none given)
-p, --package-query search for REGEXP in the entire cygwin.com package

Repository (requires internet connectivity)

Search for software:
Note: -c, -f, and -l only report on packages that are currently installed. To search all 
official Cygwin packages use -p instead. The -p REGEXP matches package names, descriptions, and names of files/paths within all packages.
--delete-orphaned-installation-keys

Delete installation keys of old, now unused
installations from the registry. Requires the right to change the registry.
--enable-unique-object-names Cygwin-DLL
--disable-unique-object-names Cygwin-DLL
--show-unique-object-names Cygwin-DLL

Enable, disable, or show the setting of the
\"unique object names\" setting in the Cygwin DLL
given as argument to this option. The DLL path must
be given as valid Windows(!) path.
See the users guide for more information.
If you don't know what this means, don't change it.

-v, --verbose produce more verbose output
-h, --help annotate output with explanatory comments when given
with another command, otherwise print this help
-V, --version print the version of cygcheck and exit
-c, --check-setup show installed version of PACKAGE and verify integrity 
(or for all installed packages if none specified)
-d, --dump-only just list packages, do not verify (with -c)
-s, --sysinfo produce diagnostic system information (implies -c -d)
-r, --registry also scan registry for Cygwin settings (with -s)
-k, --keycheck perform a keyboard check session (must be run from a
 plain console only, not from a pty/rxvt/xterm)
-f, --find-package find the package to which FILE belongs
-l, --list-package list contents of PACKAGE (or all packages if none given)
-p, --package-query search for REGEXP in the entire cygwin.com package

Repository (requires internet connectivity)

Search for software:
Note: -c, -f, and -l only report on packages that are currently installed. To search all 
official Cygwin packages use -p instead. The -p REGEXP matches package names, descriptions, and names of files/paths within all packages.

--delete-orphaned-installation-keys

Delete installation keys of old, now unused
installations from the registry. Requires the right to change the registry.
--enable-unique-object-names Cygwin-DLL
--disable-unique-object-names Cygwin-DLL
--show-unique-object-names Cygwin-DLL

Enable, disable, or show the setting of the
\"unique object names\" setting in the Cygwin DLL
given as argument to this option. The DLL path must
be given as valid Windows(!) path.
See the users guide for more information.
If you don't know what this means, don't change it.

-v, --verbose produce more verbose output
-h, --help annotate output with explanatory comments when given
with another command, otherwise print this help
-V, --version print the version of cygcheck and exit
-c, --check-setup show installed version of PACKAGE and verify integrity 
(or for all installed packages if none specified)
-d, --dump-only just list packages, do not verify (with -c)
-s, --sysinfo produce diagnostic system information (implies -c -d)
-r, --registry also scan registry for Cygwin settings (with -s)
-k, --keycheck perform a keyboard check session (must be run from a
 plain console only, not from a pty/rxvt/xterm)
-f, --find-package find the package to which FILE belongs
-l, --list-package list contents of PACKAGE (or all packages if none given)
-p, --package-query search for REGEXP in the entire cygwin.com package

Repository (requires internet connectivity)

Search for software:
Note: -c, -f, and -l only report on packages that are currently installed. To search all 
official Cygwin packages use -p instead. The -p REGEXP matches package names, descriptions, 
and names of files/paths within all packages.

--delete-orphaned-installation-keys

Delete installation keys of old, now unused
installations from the registry. 
Requires the right to change the registry.

--enable-unique-object-names Cygwin-DLL
--disable-unique-object-names Cygwin-DLL
--show-unique-object-names Cygwin-DLL

Enable, disable, or show the setting of the
\"unique object names\" setting in the Cygwin DLL
given as argument to this option. The DLL path must
be given as valid Windows(!) path.
See the users guide for more information.
If you don't know what this means, don't change it.

-v, --verbose produce more verbose output
-h, --help annotate output with explanatory comments when given
with another command, otherwise print this help
-V, --version print the version of cygcheck and exit

For those of you that want more in-depth information on using Cygwin for programming or just as a way to use Windows more like a decent OS, here is a direct link to the Cygwin PDF User Guide.

Until next time, happy Cygwin hacking…

Chris

Are You a True Supporter or just skimming the cream?

Hi there!

There are a lot of cool Open Source projects out there these days that usually produce some sort of free (as in beer) software, being it a small tool, a plugin for another application or a complete application by it self. Some of it is of poor quality, but this is definitely not the rule.

Most people don’t really think longer than that they get this piece of software for free, and how great it is to not have to pay for things.

What I’m trying to convey with this post is that there are usually an immense amount of work behind all of these projects and usually the developers and designers don’t earn much, if anything for doing this work.

Would you do that?
Would you spend maybe 50 – 90 % of your spare time working for free? Even if you believed in what you where doing it’s quite a commitment.

My point is that it is actually possible to donate a tiny sum of money once in a while or each month automated via PayPal if you can afford, at least for those software projects you’re using day in, day out without paying a cent in licence or maintenance for doing.

A an example:

I use and enjoy Blender. It has become a rather huge project with a lot of good developers working on the project, and it has even got a couple of full-time, paid developers to work on it. And if you haven’t discovered the cool Gooseberry Project, take a visit to their homepage and look around a little.

The Blender Foundation and the Gooseberry Project is cooperating on many levels these days, there is even a special Gooseberry edition of Blender that you can download from the Blender Build-bots.  There is a lot happening to the former Blender Shop where you could buy tutorials and books from individual companies as well as from more or less community acclaimed Guru figures from the “Blender world”, in addition to accessories like T-Shirts and other apparel.

Now there is a really interesting project going on called the “Blender Cloud”, that merges many of the sources of information and especially components from the Open Movie projects like Sintel, Tears of Steel and much more. They have a subscription based service that is in its infancy yet, but fully worth the price of around $9 / month already, as you can view and download many of the earlier products sold on the Blender Shop and maybe the most valuable, you get direct access to all assets used when making movies like Sintel. Complete with finished models, scenes, scripts, concept art and absolutely everything that was stored while producing these projects.

Now this is a SUPERB way to learn how a real world project like this gets done.

So, show some real commitment to the Blender Foundation, by subscribing to the Blender Cloud ever expanding service of useful resources.
(The only drawback is that you have to pay for the first three months in one go the first time you open an account. After 3 months without paying anything it’s the usual 9 something dollars per month.)

blender_cloud

The MadMan is back.

 

More Madness

 

When I read my last post I must say I really must have had a boost of optimism and god-like energy over me back then, eh?

Books to be written, 3D art to be made, Allegorithmic products to review, Python programming, Blenders Game Engine, Modo stuff.. Phew!

Well. I have actually done something. I won’t present anything here today, but some things stayed and some things did not.

I’m still into writing the book series, that’s one. (But it will be a bit postponed)

What I’m still into is off course Blender! It has gotten a LOT of updates the last seven months.
I’m still willing to create a tutorial series on the BGE (Blender Game Engine) which we all know is programmed with Python. Actually A LOT of Blender is programmed with Python now. It’s just the low level bits and pieces left in hard core C / C++ (?asm?).

I was planning on starting on this in a couple of weeks and off course post it on this blog, if it is any interest for it.

As some of you know, I’m a software developer, mainly using C# and C++, but I’ve also been using some Python through the years.

Lately I’ve been keen on learning to program GAMES. What kind of games? No idea. Just games. Fun programs that can include gaming elements, like “gamification” or something.

So I’ve downloaded the latest Unreal 4 Engine, but that was totally overkill for me. I need to know the basics first.

Even Unity seems a bit cryptic to me sometimes. But that’s mostly because of the horrific implementation of C# / .Net they’ve chosen. Goes against all good usage patterns.

So now I’m going to test out Blenders Game Engine, to see if I can make any sense of that.

Along the way will be some tutorials and some Python code for those interested.

 

Also I’ll look into some rendering with Cycles, Thea Render and LuxRender…

 

Until next time…

Blender Logo

 

 

 

 

 

fsfButton

I’m going away for 4-6 months, but please stay subscribed because…

New stuff is coming up!

Keywords: Game Development, Python, C, C++ and (hold your breath) Lisp!

New ways of thinking about the good old OOP, including functional development in Haskell and Test Driven Development and re-factoring legacy code in C++.

More 3D stuff, like Allegorithmic Substances and Modo 701.

The Blender Game Engine (programmed via Python) gets a thorough examination.

A taste of my upcoming book, called “Becoming a Real Life Developer” vol. 1 “The Stuff you Need-to-Know”.
This is a planned three-volume book series covering multiple programming languages, paradigms and languages plus how life unfolds in the real world of software development with version control systems, code reviews, the art of problem-solving and thinking “outside the box”.
It will also be geared towards team building and how to fit in to an established team of developers.
The art of becoming a software developer is very much a psychological challenge with a constant need to stay on top of the latest technologies.
My goal is to make one realize that this business is not always a bed of roses, but an extremely satisfying way of making a living if you know the right way to walk forward and get promoted without pushing yourself off the edge…

Until next time:

The Mad Man (going on a spiritual ride)

Follow-Up: Reasons to NOT only learn .Net / C#

A modern developer should master at least 3 languages!

A while ago I was all exited about finally “getting it” in sense of the more advanced parts of C#, like Generics, Events, Delegates, and Lambdas. So I wrote a post about 18 reasons you should use C# / .Net / Mono.  it kinda sounded like I’d found a salvation in it or something.

Well, I did not. I was just “on a roll”!

I’m often on these rolls. This is what gets me ahead of the competition and it’s what get’s developers with master degrees in Computer Science and programming  asking ME for help while at work from time to time. That’s wicked cool, but it has its downsides.   logoLispSpillerGlossy

I seldom sleep more than 4 hours per night, because I just HAVE to finish up a stupid project so I can understand a concept in a programming language I probably never going to use, like Cobol or something. But who knows right?

This brings me to the main theme of this blog post:

I’ve been interested in programming for a long time. Long before I started to work as a developer, I snuck in some developer tasks when working as a network and security administrator, and when working as a server and system administrator.
I managed to convince my boss that I really needed this and that book  or course so we could do this and that so much better. It worked all the time.

My job back then was basically sitting in my office with a self-made monitoring system that alerted me if some fiber link was down or a router to a branch office went bananas, something that didn’t happen very frequently. So, my responsibility was to make sure the systems ran 24/7, and that was that.
I make it sound a bit easier than it was from time to time, but the point is that I had a lot of time to study programming!

I started learning the C Language from the ubiquitous K&R book that I still keep in sight for the kicks emacs6-256of it. This was the first standardized version of C, so it had some quirks to put it mildly, but when you understood it, nothing could beat it! At least not in terms of efficiency and performance… Time to market is a nother story.
I was doing a good deal of scripting as part of my job, for automating mass installations, upgrades log-on scripts and those things, but that was in VBScript! Can you believe it? VBScript! I hated it.

So I started to replace many of the scripts with Perl and Python using the Win32 libraries, something that was way cooler.

Then I got interested in cross-platform programming in Java, because I missed a real GUI from the stripped out Tk I managed to get out of Perl and Python, and it had to run on both Windows, Linux and FreeBSD servers. While I probably would get a compile-time error writing “Hello World” in Java today I thought it was fun while it lasted.

Then the real shit hit the fan. I decided to change jobs and work as a full-time developer. My responsibilities where diverse and involved working with Legacy Borland C++ code and some C# 2.0 written in C++ style. So I had to get really serious about learning C++ and C#. The first months I went to work, did what I could, then I wrote down everything I didn’t know how to do.
When I got home I thought it to myself through books, tutorials and Googling so I could fix it the next day.

This went on for almost a year, and I was totally up to my neck in deadlines and trouble.
It wasn’t really my vision of having a job doing what I liked most.
But somehow I managed to get by and new projects came along that demanded the same level of commitment.
That’s the price to pay for adding a bit extra on the resume…the-ruby-mine-logo

Today I feel a lot safer about my skills in the “major languages” C, C++ and C#, but I’ve realized that I’ve only been doing one kind of paradigm type programming and that is the Object Oriented type of programming.

So I’ve now started to learn two new languages (or three actually), namely Common Lisp, Erlang and TCL/Tk.
What I discover each day is that the new things I learn about the more functional approach to programming could have saved my ass plenty of times if I’d known some of the same techniques when working with the projects I barely got through earlier,
I could have done many things so much simpler and more elegantly.

So my advice to all aspiring or maybe even more to all the mounted old dogs that refuses to learn new tricks is to actually do just that. Learn at least one purely functional language, one strictly OOP and one that blends it all together, like C++ or Objective-C if that’s your cup of tea. Plus I’d invest in learning one strictly interpreted language like Python or Ruby, as it makes prototyping and easier tasks, well, so much easier!.

erlang

Put a NoSQL database like MongoDB on top of this and you have an incredible toolbox for handling almost any programming task thrown at you. Word.

PS! Don’t forget those that  work hard for free to bring us some fantastic tools to develop cool things with! 

Get a  Member Sponsorship at the Free Software Foundation Today! 

fsfButton     <– LINK!

These guys are Funding the GNU Project.

Until next time, The MadMan.

Using LINQ and EntityFramework, Measuring and analyzing the LINQ effectiveness

Some Entity Framework Components

When you use something like the extensive “Entity Framework” or any other ORM (Object Relational Mapping) tool, the process of writing sophisticated database driven applications becomes a lot easier.
It eliminates most of the data access code used to be required to create object-based data applications, and contains tools that makes it possible to create object-oriented data applications from an existing database, by using .edmx files that describes the CLR (Common Language Run-time) objects and these can be “extracted” from any existing relational database that the Entity Framework has a driver for.

This enables developers to program directly against data types defined at the conceptual level, presented as regular object instances.

But.
The responsibility to create clean queries and dispose the resources that’s being used, are just as important as it was in more “old fashioned” database connected applications that does all the SQL manually.

Many people assume that, as long as the application compiles and runs without complaining loudly, everything is probably done correctly, right?
This is .Net we’re talking about, so if something was wrong I would probably get a warning or something, right?

Sadly life is not that simple in this case.

The risk of introducing data-access “anti-patterns” in your code that may decrease the performance of your application and greatly slow down your organization’s database server is highly possible, and  actually quite likely to happen if you’re new to ORM and the Entity Framework in particular.

How Can You Measure the LINQ query’s Efficiency?

To reduce the chances of creating inefficient ORM based applications, we need some way to easily (or it won’t be used) analyze exactly what goes on in the EF brain when it executes our code.

This post focuses on a product called LINQ Insight by DevArt, that addresses this problem (and a lot of other LINQ related problems) and may be downloaded for free from the DevArt site:

Download LINQ Insight Standard

NB! The FULL functionality is free for 30 days, before it changes to the more restricted, but highly useful Free Edition.

Data access anti-patterns decreases performance greatly and must be avoided.

When you write applications using for example LINQ to Entities with the Entity Framework, what goes on behind the scenes is something like:

1) The Entity Framework “Mapped” Objects are created with a ObjectQuery() method, run against an existing ObjectContext instance.

The ObjectContext instance is a container for in-memory objects and metadata extracted from the relational database.
It manages the object identities and states, keeps a pointer to original and current values of the objects properties, and tracks changes made to each object in its cache store.

The ObjectContext provides the connection and metadata information that is required to compose and execute queries, and should therefore be set up in advance.

2) Entity Framework components like the ObjectQuery class are compiled behind the scenes, and generate “regular” SQL statements that does the “actual” query against the database.

The queried data is returned as entity objects, most often as anonymous class instances, and the application works with these objects instead of directly querying the SQL database.
This is an important point to understand.
Using LINQ in this way, to offload the database server is a fundamental aspect of ORM frameworks.

Constructing an ObjectQuery Instance

The ObjectQuery returns a collection of zero or more typed entities.  The ObjectQuery generic class implements the IQueryable generic interface, whose methods enable LINQ queries to be incrementally built. You can also let the compiler infer the type of entities by using the C# var keyword, which is something that simplifies specific query situations considerably.

Instances of the ObjectQuery generic class, which implements the generic IQueryable interface, serve as the data source for LINQ to Entities queries. In a query, you specify exactly the information that you want to retrieve from the data source. A query can also specify how that information should be sorted, grouped, and shaped before it is returned. In LINQ, a query is stored in a variable. This query variable takes no action and returns no data; it only stores the query information. After you create a query you must execute that query to retrieve any data.

// Call ctor with query for "persons" and the named ObjectContext
var personsQuery = new ObjectQuery("Persons", context);

3) You can get access to the entities via the reference and collection properties, and this in turn produces additional SQL queries to get the necessary data.

4) When your application finishes working out what entities are needed, the “mapping” process of EF is more or less done.

BUT: if there are any changes to the queried entities, the application will have to save them to database somehow.
It does this by transforming your LINQ, like SubmitChanges() to “regular” SQL statements, like SELECT, UPDATE etc.

All of this happens without you being able to “see” exactly what’s going on at a “lower” level. That’s kinda the idea, to abstract away the unnecessary details from the user, and let you think about designing the flow of the application, not the technicalities used to make things work.

Though all these actions are performed by Entity Framework run-time, and are transparent for the application that works with entities, they may be complex and affect application performance greatly. That’s why you probably need a good Entity Framework profiler to create efficient applications using Entity Framework for data access. Entity Framework profiler in LINQ Insight really profiles ORM events and allows you to see how much time LINQ statement or SubmitChanges call takes to execute as a whole even if it generated multiple SQL statements.

Example Application

Let’s show how to profile Entity Framework applications on a simple example. We have used the widely used NorthwindEF sample database for our example, and generated the model for it with EDM wizard using default settings. The application is a simple console application with the following code:

Modo Logo

What do you know, now I’m back on the Modo Track…

To cite myself in my last post:

“Then we have Modo. Once my favorite polygonal modeler, back in the version 3 days. Now the whole company has been snatched by The Foundry, and all clues given leads in the direction of massive feature and price increases. So, no more Modo for me I guess.”

Then, out of curiosity, I visited the new Modo Site to check out how things where looking and what do I see?

Modo upgrades at a 40% rebate…
So, after bragging about Modo 701’s ability to run smooth on Linux in an earlier post I decided to get my CC and order the upgrade from my commercial 401 license to the latest 701 SP3. Hey, it was like $220 or something… Can’t let that slip by when I’ve always wanted to learn the ins and outs of Modo. I’ve been using it since the second version, so I figured, what a heck, it’s Christmas!

Besides, I needed a stable modeler to run on Linux besides Blender.

I mean, Blender is an awesome project, but that’s the thing. It’s a “Project” in a constant state of flux more than it is a stable “Product”, one version does things different from the next, not just in terms of the details but in the core implementation. So I find myself using about double the time on modeling something in Blender compared to using Modo, and as we all know time is our most precious asset in life.

So this winter I’ll get up to speed on the new Bullet physics implementation, the sculpting tools, the Python and the C++ API’s and the rest of this polished package.

I’ve also purchased the “Substance Designer”  version 4, which has very smooth integration with the Modo shading system, and it’s a joy to use.
I urge you to try it out, either as a trial or as a non-commercial learning tool for $99.

My goal in the world of 3D is to gather set of tools that makes a “good enough” pipeline, suitable for artists on a semi to low budget, that does things clean and efficiently and produces output that’s “on par” with expensive packages like Autodesk’s suites and tools like NukeX. Modo will definitely be a large part of this pipeline, but so will Blender and the Substance Designer from Allegorithmic.

Blender has some good compositing tools, Modo is the king of UV’s and texturing and is starting to get quite good on things like rigging and animation as well.

I believe that it should be perfectly possible to get a complete 3D pipeline of good tools for around $1000. If 3D is what you wish to do for work or as an advanced hobby, that’s not a bad price to pay. But you’ll need to be constantly monitoring the extreme offers from the tool producers via newsletters, RSS and forums.

I’m so sick of reading about a semi-professional artist with an image posted in magazines like 3D World and when they list the products used you see things like: 3DS Max, V-Ray, Nuke, Mari, Photoshop and ZBrush.
Should I seriously believe that this artist has legal licenses for software with an estimated value of $15.000 – 20.000? Seriously doubt it.
And if so, it’s NOT WORTH IT! Go figure, man!

Learn how to draw, learn Blender, Gimp and a semi-expensive package like Modo or Lightwave and you’ll be able to create just as nice results.

It’s in the hands and the mind of the artist, not in the tools. Only a poor craftsman blames his tools.

Until next time, have a wonderful Christmas you all and remember: Never stop learning!

40% off on Modo 701!

40% off on Modo 701!

 

 

 

 

 

The MadMan.

 

 

 

The Future Of Decent 3D Software for Enthusiasts and Professionals alike

Blender Image
Create what you want for free!

Ok. We all know and love Blender. But let’s face it, it has its quirks that needs some ironing out before it can totally     replace a package like Autodesk XSI or Autodesk Maya for many professional artists, or at least they think it does.

Don’t get me wrong here, it is definitely the tool of choice if you want an open source solution that can do “almost      anything”.

This is not to say that Blender has missing features, on the contrary, it has features that Maya tries to include, but has shipped with pretty serious bugs since around version 2009.
Now they have snatched a perfectly good plugin called NEX and “integrated” a.k.a. “slammed” it on top of their existing buggy tools, creating somewhat of a monster. Again. Those guys really never seem to learn the basics of Software Lifecycle Management. I’ve tried using it, but it’s so buggy that it ruins my models from time to time.

The 2014 Edition is already in SP3 and still bugs aren’t sorted. This is a frustration for many small studios that depends on stable software and don’t have the resources to create their own in-house work-around using the SDK. But what do they do? Soon they’ll release a new 2015 version with even more features and new bugs on top of that.

Then we have Modo. Once my favorite polygonal modeler, back in the version 3 days. Now the whole company has been snatched by The Foundry, and all clues given leads in the direction of massive feature and price increases. So, no more Modo for me I guess. I have my stable commercial license for Modo 401 that never stops to be valid, but hey, things evolve right? Who knows if it will be compatible with the next operating system I’m forced to update to because of other applications demands?

It still amazes me to see a company like Newtek still being alive and actually even kicking these days with the new Chronosculpt and Nevronmotion applications that lets you sculpt in time based layers and record motion data via a cheap $99 Kinect Sensor! Way to go!
How much this will be used remains to be seen, but they are on a creative roll and they NEVER give up. That is the true spirit of life. In addition they’ve released a free update to existing v. 11 (maybe also v. 10?) customers in form of Lightwave 11.6.
This edition is the most groundbreaking release since version 9.6 in my eyes. It actually is a NEW LIGHTWAVE.
A lot of new cool modeling tools and a great deal of new features on the rigging and animation side with the introduction of the Genoma system and off course an updated integration of the Bullet Physics engine, so sorely needed.
To bad I only have an educational license for version 9.6. But they do have a good offer these days, letting me upgrade to 11.6 for around $350 or something.
But, it’s Christmas and I have other posts on my budget screaming for coverage…

When it comes to a simple, fast and stable polygonal modeler we have the option of using Silo. It’s a $159 application and is an extremely competent modeler application.
But it hasn’t been actively developed for over two years.
So the reason for starting this article was really to investigate the possibility to crowd-fund a purchase of the Silo source code from Nevercenter and turn it into an actively maintained Open Source project. Personally, I have an hour or two now and then for coding some C++, Python or whatever they’ve used to create the product.

The question is: How many others are in on a project like this?

I’ve posted a poll over at CG SOCIETY (CGTalk) and for those that would be so kind, I urge you to give your vote to one of the options presented there.

I’ve been lousy at posting new stuff to my blog lately and probably have lost a lot of readers, but hopefully some remain truthful to the old madman.

Here is the link to the post on CGC:

Poll for Open Sourcing Silo 

For those that does not have a CGC account, get one! Kidding.

I’ll present the poll in this post as well, though it won’t be linked with the results on CGC, so the best is if you take the time to register over there. They even have a $19 / Year deal for a premium subscription right now (normally $79) with a lot of goodies.

All the best,

The MadMan

18 Reasons to Use C# / .Net

18 Reasons to Use C# / .Net

(some of this also explain why C# > Java)

This list is by no means complete, but may be a helper for those that wonder if they should jump on the old Java Wagon or the shiny C#/.Net Wagon with dual suspension and enhanced body construction…

  • No pointers required! C# programs typically have no need for direct pointer
    manipulation (BUT you are free to drop down to that level if absolutely
    necessary)
  • Automatic memory management through garbage collection. Given this, C# does
    not support a delete keyword.
  • Formal syntactic constructs for classes, interfaces, structures, enumerations, and
    delegates.
  • The C++-like ability to overload operators for a custom type, without the
    complexity (e.g., making sure to “return *this to allow chaining” is not your
    problem).
  • Support for attribute-based programming. This brand of development allows you
    to annotate types and their members to further qualify their behavior. For
    example, if you mark a method with the [Obsolete] attribute, programmers will
    see your custom warning message print out if they attempt to make use of the
    decorated member.
  • The ability to build generic types and generic members. Using generics, you are
    able to build very efficient and type-safe code that defines numerous placeholders
    specified at the time you interact with the generic item.
  • Support for anonymous methods, which allow you to supply an inline function
    anywhere a delegate type is required.
  • The ability to define a single type across multiple code files (or if necessary, as an
    in-memory representation) using the partial keyword.
  •  LINQ: Support for strongly typed queries used to interact with various forms
    of data.
  • Support for anonymous types that allow you to model the shape of a type rather
    than its behavior.
  • The ability to extend the functionality of an existing type (without subclassing)
    using extension methods.
  • Inclusion of a lambda operator (=>), which even further simplifies working with
    .NET delegate types.
  • An object initialization syntax, which allows you to set property values at the
    time of object creation.
  • Support for optional method parameters, as well as named method arguments.
  • Support for dynamic lookup of members at runtime via the dynamic keyword.
    This provides a unified approach to invoking members
    on the fly, regardless of which framework the member implemented (COM,
    IronRuby, IronPython, or via .NET reflection services)
  • Working with generic types is much more intuitive, given that you can easily map
    generic data to and from general System.Object collections via covariance and
    contravariance.
  • More and more companies and projects are going for the Open Source Mono Project’s implementation to create true cross-platform applications, both on desktop and mobile platforms.
  • The current version of C#
    provides a pair of new keywords (async and await), which massively simplify multithreaded and
    asynchronous programming.

You’ll be the judge! Both Languages has their charm, but personally (I learned Java many years ago) I strongly prefer C#, as you probably reasoned from this article…